Importing a user home manager nix config
This commit is contained in:
parent
d7faff3901
commit
6777fca56b
2 changed files with 72 additions and 4 deletions
|
|
@ -7,12 +7,19 @@
|
|||
}:
|
||||
let
|
||||
tailscaleMagicDNS = "neon-dory.ts.net";
|
||||
|
||||
homeParameters = {
|
||||
username = "pazpi";
|
||||
commonName = "Davide Pasetto";
|
||||
userEmail = "pasettodavide@gmail.com";
|
||||
extraPackages = [ ];
|
||||
};
|
||||
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./boot.nix
|
||||
# home-manager.nixosModules.home-manager
|
||||
];
|
||||
|
||||
age = {
|
||||
|
|
@ -22,15 +29,13 @@ in
|
|||
};
|
||||
};
|
||||
|
||||
|
||||
|
||||
my = {
|
||||
desktop = {
|
||||
audio.enable = false;
|
||||
|
||||
desktopUser = {
|
||||
enable = true;
|
||||
userName = "pazpi";
|
||||
userName = homeParameters.username;
|
||||
hashedPassword = "$y$j9T$dA94KVg1/jYLqclQQbTDk.$cnfxBWUN8P4shr8Kkipv5bU/RCtQNoAwYFDZ0X/BYs5";
|
||||
};
|
||||
|
||||
|
|
@ -64,6 +69,16 @@ in
|
|||
};
|
||||
};
|
||||
|
||||
home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
backupFileExtension = "backup";
|
||||
users.${homeParameters.username} = import ./pazpi-home.nix;
|
||||
extraSpecialArgs = {
|
||||
inherit homeParameters;
|
||||
};
|
||||
};
|
||||
|
||||
time.timeZone = "Europe/Rome";
|
||||
|
||||
# Vedi https://github.com/TLATER/dotfiles/blob/f989a86890f27f6b089e9d74b7e8356ec8e5683d/home-config/hosts/yui.nix
|
||||
|
|
|
|||
53
hosts/deadbeef/pazpi-home.nix
Normal file
53
hosts/deadbeef/pazpi-home.nix
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
homeParameters,
|
||||
...
|
||||
}:
|
||||
{
|
||||
|
||||
home.username = homeParameters.username;
|
||||
home.homeDirectory = "/home/${homeParameters.username}";
|
||||
|
||||
imports = [ ../../modules/home ];
|
||||
|
||||
programs.git = {
|
||||
userName = homeParameters.username;
|
||||
userEmail = homeParameters.userEmail;
|
||||
};
|
||||
|
||||
# set cursor size and dpi for 4k monitor
|
||||
xresources.properties = {
|
||||
"Xcursor.size" = 16;
|
||||
"Xft.dpi" = 172;
|
||||
};
|
||||
|
||||
programs.bash = {
|
||||
enable = true;
|
||||
enableCompletion = true;
|
||||
# TODO add your custom bashrc here
|
||||
bashrcExtra = ''
|
||||
export PATH="$PATH:$HOME/bin:$HOME/.local/bin:$HOME/go/bin"
|
||||
'';
|
||||
|
||||
# set some aliases, feel free to add more or remove some
|
||||
shellAliases = {
|
||||
k = "kubectl";
|
||||
urldecode = "python3 -c 'import sys, urllib.parse as ul; print(ul.unquote_plus(sys.stdin.read()))'";
|
||||
urlencode = "python3 -c 'import sys, urllib.parse as ul; print(ul.quote_plus(sys.stdin.read()))'";
|
||||
};
|
||||
};
|
||||
|
||||
# This value determines the home Manager release that your
|
||||
# configuration is compatible with. This helps avoid breakage
|
||||
# when a new home Manager release introduces backwards
|
||||
# incompatible changes.
|
||||
#
|
||||
# You can update home Manager without changing this value. See
|
||||
# the home Manager release notes for a list of state version
|
||||
# changes in each release.
|
||||
home.stateVersion = "24.05";
|
||||
|
||||
# Let home Manager install and manage itself.
|
||||
programs.home-manager.enable = true;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue