mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-04 21:03:15 +00:00
755b915a15
nix run nixpkgs#silver-searcher -- -G '\.nix$' -0l 'description.*"[Aa]n?' pkgs \ | xargs -0 nix run nixpkgs#gnused -- -i '' -Ee 's/(description.*")[Aa]n? (.)/\1\U\2/'
69 lines
2.0 KiB
Nix
69 lines
2.0 KiB
Nix
{ lib
|
|
, fetchFromGitHub
|
|
, buildDotnetModule
|
|
, dotnetCorePackages
|
|
, libX11
|
|
, libICE
|
|
, libSM
|
|
, fontconfig
|
|
, libsecret
|
|
, git
|
|
, git-credential-manager
|
|
, gnupg
|
|
, pass
|
|
, testers
|
|
, withGuiSupport ? true
|
|
, withLibsecretSupport ? true
|
|
, withGpgSupport ? true
|
|
}:
|
|
|
|
assert withLibsecretSupport -> withGuiSupport;
|
|
buildDotnetModule rec {
|
|
pname = "git-credential-manager";
|
|
version = "2.4.1";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "git-ecosystem";
|
|
repo = "git-credential-manager";
|
|
rev = "v${version}";
|
|
hash = "sha256-Uf0EXaGM4k9Aanz16B9xA2EcseXTI9lLCws/ZVNb3e8=";
|
|
};
|
|
|
|
projectFile = "src/shared/Git-Credential-Manager/Git-Credential-Manager.csproj";
|
|
nugetDeps = ./deps.nix;
|
|
dotnet-sdk = dotnetCorePackages.sdk_7_0;
|
|
dotnet-runtime = dotnetCorePackages.runtime_7_0;
|
|
dotnetInstallFlags = [ "--framework" "net7.0" ];
|
|
executables = [ "git-credential-manager" ];
|
|
|
|
runtimeDeps = [ fontconfig ]
|
|
++ lib.optionals withGuiSupport [ libX11 libICE libSM ]
|
|
++ lib.optional withLibsecretSupport libsecret;
|
|
makeWrapperArgs = [
|
|
"--prefix PATH : ${lib.makeBinPath ([ git ] ++ lib.optionals withGpgSupport [ gnupg pass ])}"
|
|
];
|
|
|
|
passthru = {
|
|
updateScript = ./update.sh;
|
|
tests.version = testers.testVersion {
|
|
package = git-credential-manager;
|
|
};
|
|
};
|
|
|
|
meta = with lib; {
|
|
description = "Secure, cross-platform Git credential storage with authentication to GitHub, Azure Repos, and other popular Git hosting services";
|
|
homepage = "https://github.com/git-ecosystem/git-credential-manager";
|
|
license = with licenses; [ mit ];
|
|
platforms = platforms.unix;
|
|
maintainers = with maintainers; [ _999eagle ];
|
|
longDescription = ''
|
|
git-credential-manager is a secure, cross-platform Git credential storage with authentication to GitHub, Azure Repos, and other popular Git hosting services.
|
|
|
|
> requires sandbox to be disabled on MacOS, so that
|
|
.NET can find `/usr/bin/codesign` to sign the compiled binary.
|
|
This problem is common to all .NET packages on MacOS with Nix.
|
|
'';
|
|
mainProgram = "git-credential-manager";
|
|
};
|
|
}
|