These modules keep my identity data in one place and only emit the small config fragments that each tool needs.
They do not enable git, jj, or sl for you. They only write identity
snippets, so you can drop them into an existing Home Manager setup without
pulling in a full tool configuration.
gitincludes with fixed SSH signingjjconfig fragments with SSH signing- SOPS-backed secrets for names, emails, and signing keys
Import the shared module once, then enable the identities you want:
{
inputs.identities.url = "github:shikanime/identities";
inputs.sops-nix.url = "github:mic92/sops-nix";
outputs = { home-manager, identities, sops-nix, ... }: {
homeConfigurations.user = home-manager.lib.homeConfiguration {
modules = [
sops-nix.homeModules.default
identities.homeModules.default
{
identities = {
shikanime.enable = true;
gouv = {
enable = true;
git.condition = "gitpath:/home/shika/Source/Repos/github.com/cloud-pi-native";
jj.extraConfig."--when".repositories = [
"/home/shika/Source/Repos/github.com/cloud-pi-native"
];
};
automata = {
enable = true;
git.condition = "gitpath:/home/shika/Source/Repos/github.com/yohra-operator";
jj.extraConfig."--when".repositories = [
"/home/shika/Source/Repos/github.com/yohra-operator"
];
};
};
}
];
};
};
}The design is intentionally small:
identities.enableturns on the identity systemidentities.git.enable,identities.jj.enable, andidentities.ghstack.enableandidentities.glab.enablecontrol the global defaults forshikanimeghstack and glab configidentities.<name>.enableturns a specific identity on or offidentities.<name>.git.enableand.jj.enablecontrol that identity's tool outputidentities.shikanime.ghstack.enableand.glab.enablecontrol whether those config fragments are emitted forshikanimeidentities.<name>.git.extraConfigmerges into the generated Git includeidentities.<name>.git.conditionsets the Git include conditionidentities.<name>.jj.extraConfigmerges into the generated JJ configidentities.shikanime.ghstack.extraConfigmerges into the generatedghstackrcidentities.shikanime.glab.extraConfigmerges into the generated glab config
SSH signing is fixed in the modules. extraConfig is only for the remaining
tool settings.
shikanimejj/conf.d/shikanime.toml
gouvjj/conf.d/gouv.toml
automatajj/conf.d/automata.toml
Git identity snippets are written through programs.git.includes.
The encrypted values live in:
secrets/shikanime.enc.yamlsecrets/gouv.enc.yamlsecrets/automata.enc.yaml
The repo ships a SOPS-enabled dev shell. Edit secrets in the identities
repository with:
sops secrets/<name>.enc.yamldirenv allow # or: nix develop
nix fmt
nix flake check- The modules are meant to be composable.
- They only emit identity fragments.
- If you enable multiple identities, each one stays isolated by its own
git.conditionand JJ repository scoping.
See AGENTS.md for the full module contract and coding conventions.
