nixpkgs/pkgs/applications/version-management/git-credential-oauth/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

37 lines
983 B
Nix
Raw Normal View History

{ lib, buildGoModule, fetchFromGitHub, installShellFiles }:
2023-06-01 21:17:38 +00:00
buildGoModule rec {
pname = "git-credential-oauth";
2024-04-27 00:59:11 +00:00
version = "0.11.2";
2023-06-01 21:17:38 +00:00
src = fetchFromGitHub {
owner = "hickford";
repo = pname;
rev = "v${version}";
2024-04-27 00:59:11 +00:00
hash = "sha256-dGn1I47/S6DYXva5zjvcQnB+I4Ex354xMmZ/3OkpjMw=";
2023-06-01 21:17:38 +00:00
};
nativeBuildInputs = [ installShellFiles ];
2023-06-01 21:17:38 +00:00
ldflags = [
"-s"
"-w"
"-X main.version=${version}"
];
2024-04-27 00:59:11 +00:00
vendorHash = "sha256-nbwrVihcH+ARLHylsjogsv3LVP+0+YtQ+7cozB7pAWo=";
2023-06-01 21:17:38 +00:00
postInstall = ''
installManPage $src/git-credential-oauth.1
'';
2023-06-01 21:17:38 +00:00
meta = {
description = "Git credential helper that securely authenticates to GitHub, GitLab and BitBucket using OAuth";
homepage = "https://github.com/hickford/git-credential-oauth";
changelog = "https://github.com/hickford/git-credential-oauth/releases/tag/${src.rev}";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ shyim ];
2023-11-27 01:17:53 +00:00
mainProgram = "git-credential-oauth";
2023-06-01 21:17:38 +00:00
};
}