diff --git a/config/bash.nix b/config/bash.nix index da63707..e5dc0c3 100644 --- a/config/bash.nix +++ b/config/bash.nix @@ -1,4 +1,9 @@ -{ config, pkgs, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: { programs.bash = { @@ -8,7 +13,10 @@ # History configuration historySize = 1000; historyFileSize = 2000; - historyControl = [ "ignoredups" "ignorespace" ]; + historyControl = [ + "ignoredups" + "ignorespace" + ]; # Bash options and extra configuration bashrcExtra = '' @@ -120,7 +128,8 @@ "docker-compose" = "docker compose"; # Modern tools aliases - "l" = "eza --header --long --git --group-directories-first --group --icons --color=always --sort=name --hyperlink -o --no-permissions"; + "l" = + "eza --header --long --git --group-directories-first --group --icons --color=always --sort=name --hyperlink -o --no-permissions"; "ll" = "l"; "la" = "l -a"; "cat" = "bat"; @@ -139,8 +148,10 @@ "dcps" = "docker compose ps"; "dcpr" = "dcp && dcd && dcu -d && dcl -f"; "dcr" = "dcd && dcu -d && dcl -f"; - "ddpul" = "docker compose down && docker compose pull && docker compose up -d && docker compose logs -f"; - "docker-nuke" = "docker kill $(docker ps -q) && docker rm $(docker ps -a -q) && docker system prune --all --volumes --force && docker volume prune --force"; + "ddpul" = + "docker compose down && docker compose pull && docker compose up -d && docker compose logs -f"; + "docker-nuke" = + "docker kill $(docker ps -q) && docker rm $(docker ps -a -q) && docker system prune --all --volumes --force && docker volume prune --force"; # Git aliases "g" = "git"; @@ -267,5 +278,4 @@ ]; }; - } diff --git a/config/git.nix b/config/git.nix index 0da77bb..622d20d 100644 --- a/config/git.nix +++ b/config/git.nix @@ -1,4 +1,9 @@ -{ config, pkgs, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: { programs.git = { diff --git a/config/starship.nix b/config/starship.nix index 24538cd..0168288 100644 --- a/config/starship.nix +++ b/config/starship.nix @@ -1,4 +1,9 @@ -{ config, pkgs, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: { programs.starship = { diff --git a/flake.nix b/flake.nix index bf966ed..b7a56c1 100644 --- a/flake.nix +++ b/flake.nix @@ -18,28 +18,36 @@ opnix, }: let - supportedSystems = [ "x86_64-linux" "aarch64-linux" ]; + supportedSystems = [ + "x86_64-linux" + "aarch64-linux" + ]; forAllSystems = nixpkgs.lib.genAttrs supportedSystems; - pkgsFor = system: import nixpkgs { - inherit system; - config.allowUnfree = true; - }; + pkgsFor = + system: + import nixpkgs { + inherit system; + config.allowUnfree = true; + }; in { - homeConfigurations = let - mkHomeConfig = system: hostname: isServer: - home-manager.lib.homeManagerConfiguration { - pkgs = pkgsFor system; - modules = [ ./home.nix ]; - extraSpecialArgs = { + homeConfigurations = + let + mkHomeConfig = + system: hostname: isServer: + home-manager.lib.homeManagerConfiguration { pkgs = pkgsFor system; - inherit opnix isServer hostname; + modules = [ ./home.nix ]; + extraSpecialArgs = { + pkgs = pkgsFor system; + inherit opnix isServer hostname; + }; }; - }; - in { - "mennos-vps" = mkHomeConfig "aarch64-linux" "mennos-vps" true; - "mennos-desktop" = mkHomeConfig "x86_64-linux" "mennos-desktop" false; - "mennos-laptop" = mkHomeConfig "x86_64-linux" "mennos-laptop" false; - }; + in + { + "mennos-vps" = mkHomeConfig "aarch64-linux" "mennos-vps" true; + "mennos-desktop" = mkHomeConfig "x86_64-linux" "mennos-desktop" false; + "mennos-laptop" = mkHomeConfig "x86_64-linux" "mennos-laptop" false; + }; }; } diff --git a/home.nix b/home.nix index 2a369b7..aa5836c 100644 --- a/home.nix +++ b/home.nix @@ -13,24 +13,23 @@ allowUnfreePredicate = pkg: true; }; - imports = - [ - opnix.homeManagerModules.default - ./config/default.nix - ./packages/common/default.nix - ] - ++ ( - if isServer then - [ - ./packages/server/default.nix - ./server/default.nix - ] - else - [ - ./packages/workstation/default.nix - ./workstation/default.nix - ] - ); + imports = [ + opnix.homeManagerModules.default + ./config/default.nix + ./packages/common/default.nix + ] + ++ ( + if isServer then + [ + ./packages/server/default.nix + ./server/default.nix + ] + else + [ + ./packages/workstation/default.nix + ./workstation/default.nix + ] + ); home = { username = "menno";