1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2024-12-15 17:50:53 +00:00
home-manager/modules/programs/git-credential-oauth.nix
2023-06-14 23:26:14 +02:00

24 lines
530 B
Nix

{ config, lib, pkgs, ... }:
let
cfg = config.programs.git-credential-oauth;
in {
meta.maintainers = [ lib.maintainers.tomodachi94 ];
options = {
programs.git-credential-oauth = {
enable = lib.mkEnableOption "Git authentication handler for OAuth";
package = lib.mkPackageOption pkgs "git-credential-oauth" { };
};
};
config = lib.mkIf cfg.enable {
home.packages = [ cfg.package ];
programs.git.extraConfig.credential.helper =
[ "${cfg.package}/bin/git-credential-oauth" ];
};
}