forked from jan-leila/nix-config
made leyla configs optional
This commit is contained in:
parent
4f195245ce
commit
2820252c54
6 changed files with 477 additions and 470 deletions
|
@ -1,5 +1,6 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
osConfig,
|
||||
pkgs,
|
||||
...
|
||||
|
@ -12,22 +13,22 @@ in {
|
|||
./firefox.nix
|
||||
];
|
||||
|
||||
nixpkgs.config = {
|
||||
allowUnfree = true;
|
||||
};
|
||||
config = lib.mkMerge [
|
||||
(lib.mkIf userConfig.isTerminalUser {
|
||||
home.packages = with pkgs; [
|
||||
# command line tools
|
||||
sox
|
||||
yt-dlp
|
||||
ffmpeg
|
||||
imagemagick
|
||||
];
|
||||
})
|
||||
(lib.mkIf userConfig.isDesktopUser {
|
||||
nixpkgs.config = {
|
||||
allowUnfree = true;
|
||||
};
|
||||
|
||||
home = {
|
||||
packages =
|
||||
lib.lists.optionals userConfig.isTerminalUser (
|
||||
with pkgs; [
|
||||
# command line tools
|
||||
sox
|
||||
yt-dlp
|
||||
ffmpeg
|
||||
imagemagick
|
||||
]
|
||||
)
|
||||
++ (
|
||||
home.packages = (
|
||||
lib.lists.optionals userConfig.isDesktopUser (
|
||||
(with pkgs; [
|
||||
# helvetica font
|
||||
|
@ -91,5 +92,44 @@ in {
|
|||
)
|
||||
)
|
||||
);
|
||||
};
|
||||
programs = lib.mkIf userConfig.isDesktopUser {
|
||||
# Let Home Manager install and manage itself.
|
||||
home-manager.enable = true;
|
||||
|
||||
# set up git defaults
|
||||
git = {
|
||||
enable = true;
|
||||
userName = "Leyla Becker";
|
||||
userEmail = "git@jan-leila.com";
|
||||
extraConfig.init.defaultBranch = "main";
|
||||
};
|
||||
|
||||
# add direnv to auto load flakes for development
|
||||
direnv = {
|
||||
enable = true;
|
||||
enableBashIntegration = true;
|
||||
nix-direnv.enable = true;
|
||||
config = {
|
||||
global.hide_env_diff = true;
|
||||
whitelist.exact = ["/home/leyla/documents/code/nix-config"];
|
||||
};
|
||||
};
|
||||
bash.enable = true;
|
||||
|
||||
openssh = {
|
||||
authorizedKeys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJHeItmt8TRW43uNcOC+eIurYC7Eunc0V3LGocQqLaYj leyla@horizon"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIILimFIW2exEH/Xo7LtXkqgE04qusvnPNpPWSCeNrFkP leyla@defiant"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKBiZkg1c2aaNHiieBX4cEziqvJVj9pcDfzUrKU/mO0I leyla@twilight"
|
||||
];
|
||||
hostKeys = [
|
||||
{
|
||||
type = "ed25519";
|
||||
path = "${config.home.username}_${osConfig.networking.hostName}_ed25519";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
})
|
||||
];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue