Files
nix-flake/modules/global/home.nix
T
greyweather 023fc0c424 add features.applications.shellScripts option
uses a custom function from my helper flake to convert a basic attrset of strings into a format `home.file` will accept
2026-08-30 02:54:08 +01:00

82 lines
1.8 KiB
Nix

{ inputs, self, ... }: {
flake.homeModules.global = { lib, config, pkgs, ... }: {
nix.gc = {
automatic = true;
persistent = true;
dates = "Sun 05:00";
};
nixpkgs.config = lib.mkIf (config.info.isStandalone) {
allowUnfree = true;
};
home = {
stateVersion = config.info.stateVersion;
packages = with pkgs; [
speedtest-go
] ++ config.features.applications.extraPackages
++ (if config.info.isStandalone then [
pkgs.home-manager
] else []);
shell.enableBashIntegration = true;
username = "grey";
homeDirectory = "/home/${config.home.username}";
file = inputs.helpers.homeFilesFromStringAttrs {
dir = ".local/bin";
attrs = config.features.applications.shellScripts;
exec = true;
};
};
xdg = {
enable = true;
localBinInPath = true;
};
programs = {
git = {
enable = true;
lfs.enable = true;
settings = {
user.name = "Grey Jones";
user.email = "grey@greyweather.dev";
};
signing = {
format = "openpgp";
key = "CC7388DF8E1890729921BCFF7C67C51C2FF524D9";
signByDefault = true;
};
};
gpg = {
enable = true;
};
ssh = {
enable = true;
enableDefaultConfig = false;
settings = {
"git.greyweather.dev" = {
HostName = "git.greyweather.dev";
Port = "222";
User = "git";
IdentityFile = "~/.ssh/id_gitea";
};
"github.com" = {
HostName = "github.com";
Port = 22;
User = "git";
IdentityFile = "~/.ssh/id_github";
};
};
};
};
};
}