This commit is contained in:
2026-06-18 06:57:00 +09:00
parent af06dd6499
commit b8298618b6
2 changed files with 15 additions and 0 deletions
+9
View File
@@ -32,6 +32,15 @@ in
default = { };
description = "SSH match blocks";
};
githubIdentityFiles = lib.mkOption {
type = lib.types.listOf lib.types.str;
default = [
"~/.ssh/id_ed25519_sk_rk"
"~/.ssh/id_ed25519"
];
description = "SSH identity files for GitHub (tried in order)";
};
};
config = lib.mkIf cfg.enable {
+6
View File
@@ -25,6 +25,12 @@ in
enableDefaultConfig = false;
settings = cfg.matchBlocks // {
"github.com" = {
IdentityFile = cfg.githubIdentityFiles;
IdentitiesOnly = true;
AddKeysToAgent = cfg.addKeysToAgent;
};
"*" = {
IdentityFile = cfg.defaultIdentityFile;
AddKeysToAgent = cfg.addKeysToAgent;