re-work cli aspect for nixos and homeModules
This commit is contained in:
parent
5f1c05f090
commit
bfa2521ed0
13 changed files with 264 additions and 230 deletions
|
|
@ -1,6 +1,13 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
flake.modules.homeManager.cli-btop =
|
flake.modules = {
|
||||||
|
nixos.btop =
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
environment.systemPackages = with pkgs; [ btop ];
|
||||||
|
};
|
||||||
|
|
||||||
|
homeManager.btop =
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
lib,
|
lib,
|
||||||
|
|
@ -17,4 +24,5 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
28
aspects/cli/cli.nix
Normal file
28
aspects/cli/cli.nix
Normal file
|
|
@ -0,0 +1,28 @@
|
||||||
|
{ inputs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
flake.modules = {
|
||||||
|
nixos.cli =
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
imports = with inputs.self.modules.nixos; [
|
||||||
|
btop
|
||||||
|
helix
|
||||||
|
tmux
|
||||||
|
];
|
||||||
|
};
|
||||||
|
homeManager.cli =
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
imports = with inputs.self.modules.nixos; [
|
||||||
|
btop
|
||||||
|
comma
|
||||||
|
direnv
|
||||||
|
helix
|
||||||
|
hm-cli
|
||||||
|
starship
|
||||||
|
tmux
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
flake.modules.homeManager.cli-comma =
|
flake.modules.homeManager.comma =
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
lib,
|
lib,
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
flake.modules.homeManager.cli-direnv =
|
flake.modules.homeManager.direnv =
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
lib,
|
lib,
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,15 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
flake.modules.homeManager.cli-helix =
|
flake.modules = {
|
||||||
|
nixos.helix =
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
helix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
homeManager.helix =
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
lib,
|
lib,
|
||||||
|
|
@ -54,4 +63,5 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
flake.modules.homeManager.cli-base =
|
flake.modules.homeManager.hm-cli =
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
lib,
|
lib,
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
flake.modules.homeManager.cli-starship =
|
flake.modules.homeManager.starship =
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
lib,
|
lib,
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,15 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
flake.modules.homeManager.cli-tmux =
|
flake.modules = {
|
||||||
|
nixos.tmux =
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
tmux
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
homeManager.tmux =
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
lib,
|
lib,
|
||||||
|
|
@ -16,4 +25,5 @@
|
||||||
keyMode = "vi";
|
keyMode = "vi";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -8,13 +8,10 @@
|
||||||
### Dev Tools ###
|
### Dev Tools ###
|
||||||
git
|
git
|
||||||
### System Utilities ###
|
### System Utilities ###
|
||||||
btop
|
|
||||||
fastfetch
|
fastfetch
|
||||||
helix
|
|
||||||
nixos-firewall-tool
|
nixos-firewall-tool
|
||||||
nvd
|
nvd
|
||||||
sysz
|
sysz
|
||||||
tmux
|
|
||||||
wget
|
wget
|
||||||
yazi
|
yazi
|
||||||
];
|
];
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
{ inputs, ... }:
|
{ inputs, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
flake.nixosConfigurations.alexandria = inputs.nixpkgs-stable.lib.nixosSystem {
|
flake.nixosConfigurations.alexandria = inputs.nixpkgs-stable.lib.nixosSystem {
|
||||||
|
|
@ -13,39 +13,34 @@
|
||||||
inputs.self.overlays.default
|
inputs.self.overlays.default
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
((inputs.import-tree.initFilter (p: lib.hasSuffix ".nix" p)) ./_alexandria)
|
||||||
|
]
|
||||||
|
++ (with inputs.self.modules.nixos; [
|
||||||
|
cli
|
||||||
|
|
||||||
# Common aspects (always included)
|
# Common aspects (always included)
|
||||||
inputs.self.modules.nixos.common-boot
|
common-boot
|
||||||
inputs.self.modules.nixos.common-console
|
common-console
|
||||||
inputs.self.modules.nixos.common-firewall
|
common-firewall
|
||||||
inputs.self.modules.nixos.common-locale
|
common-locale
|
||||||
inputs.self.modules.nixos.common-nix
|
common-nix
|
||||||
inputs.self.modules.nixos.common-openssh
|
common-openssh
|
||||||
inputs.self.modules.nixos.common-programs
|
common-programs
|
||||||
inputs.self.modules.nixos.common-security
|
common-security
|
||||||
inputs.self.modules.nixos.common-services
|
common-services
|
||||||
inputs.self.modules.nixos.common-tailscale
|
common-tailscale
|
||||||
|
|
||||||
# User aspects
|
# User aspects
|
||||||
inputs.self.modules.nixos.user
|
user
|
||||||
inputs.self.modules.nixos.root
|
root
|
||||||
|
|
||||||
# Server aspects
|
# Server aspects
|
||||||
inputs.self.modules.nixos.server-boot
|
server-boot
|
||||||
inputs.self.modules.nixos.server-nix
|
server-nix
|
||||||
inputs.self.modules.nixos.server-tailscale
|
server-tailscale
|
||||||
|
|
||||||
# Other aspects
|
# Other aspects
|
||||||
inputs.self.modules.nixos.fwupd
|
fwupd
|
||||||
inputs.self.modules.nixos.podman
|
]);
|
||||||
|
|
||||||
# Host-specific files (from _alexandria/)
|
|
||||||
./_alexandria/hardware-configuration.nix
|
|
||||||
./_alexandria/jellyfin.nix
|
|
||||||
./_alexandria/nextcloud.nix
|
|
||||||
./_alexandria/nginx.nix
|
|
||||||
./_alexandria/unbound.nix
|
|
||||||
./_alexandria/vaultwarden.nix
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
{ inputs, self, ... }:
|
{ inputs, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
flake.nixosConfigurations.io = inputs.nixpkgs.lib.nixosSystem {
|
flake.nixosConfigurations.io = inputs.nixpkgs.lib.nixosSystem {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
|
|
@ -12,48 +13,43 @@
|
||||||
inputs.self.overlays.default
|
inputs.self.overlays.default
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
((inputs.import-tree.initFilter (p: lib.hasSuffix ".nix" p)) ./_io)
|
||||||
# Common aspects (always included)
|
|
||||||
inputs.self.modules.nixos.common-boot
|
|
||||||
inputs.self.modules.nixos.common-console
|
|
||||||
inputs.self.modules.nixos.common-firewall
|
|
||||||
inputs.self.modules.nixos.common-locale
|
|
||||||
inputs.self.modules.nixos.common-nix
|
|
||||||
inputs.self.modules.nixos.common-openssh
|
|
||||||
inputs.self.modules.nixos.common-programs
|
|
||||||
inputs.self.modules.nixos.common-security
|
|
||||||
inputs.self.modules.nixos.common-services
|
|
||||||
inputs.self.modules.nixos.common-tailscale
|
|
||||||
|
|
||||||
# User aspects
|
|
||||||
inputs.self.modules.nixos.user
|
|
||||||
inputs.self.modules.nixos.root
|
|
||||||
|
|
||||||
# Desktop aspects
|
|
||||||
inputs.self.modules.nixos.desktop-boot
|
|
||||||
inputs.self.modules.nixos.desktop-desktop
|
|
||||||
inputs.self.modules.nixos.desktop-nix
|
|
||||||
inputs.self.modules.nixos.desktop-services
|
|
||||||
|
|
||||||
# Other aspects based on tags
|
|
||||||
inputs.self.modules.nixos.ai
|
|
||||||
inputs.self.modules.nixos.bluetooth
|
|
||||||
inputs.self.modules.nixos.dev
|
|
||||||
inputs.self.modules.nixos.libvirtd
|
|
||||||
inputs.self.modules.nixos.networkmanager
|
|
||||||
inputs.self.modules.nixos.podman
|
|
||||||
|
|
||||||
# Factory-generated ephemeral module
|
|
||||||
(inputs.self.factory.ephemeral {
|
(inputs.self.factory.ephemeral {
|
||||||
rootDevice = "/dev/mapper/cryptroot";
|
rootDevice = "/dev/mapper/cryptroot";
|
||||||
})
|
})
|
||||||
|
]
|
||||||
|
++ (with inputs.self.modules.nixos; [
|
||||||
|
cli
|
||||||
|
|
||||||
# Host-specific files (from _io/)
|
# Common aspects (always included)
|
||||||
./_io/hardware-configuration.nix
|
common-boot
|
||||||
./_io/disko.nix
|
common-console
|
||||||
./_io/boot.nix
|
common-firewall
|
||||||
./_io/programs.nix
|
common-locale
|
||||||
./_io/services.nix
|
common-nix
|
||||||
];
|
common-openssh
|
||||||
|
common-programs
|
||||||
|
common-security
|
||||||
|
common-services
|
||||||
|
common-tailscale
|
||||||
|
|
||||||
|
# User aspects
|
||||||
|
user
|
||||||
|
root
|
||||||
|
|
||||||
|
# Desktop aspects
|
||||||
|
desktop-boot
|
||||||
|
desktop-desktop
|
||||||
|
desktop-nix
|
||||||
|
desktop-services
|
||||||
|
|
||||||
|
# Other aspects
|
||||||
|
ai
|
||||||
|
bluetooth
|
||||||
|
dev
|
||||||
|
libvirtd
|
||||||
|
networkmanager
|
||||||
|
podman
|
||||||
|
]);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
{ inputs, ... }:
|
{ inputs, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
flake.nixosConfigurations.rotterdam = inputs.nixpkgs.lib.nixosSystem {
|
flake.nixosConfigurations.rotterdam = inputs.nixpkgs.lib.nixosSystem {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
|
|
@ -12,53 +13,48 @@
|
||||||
inputs.self.overlays.default
|
inputs.self.overlays.default
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
((inputs.import-tree.initFilter (p: lib.hasSuffix ".nix" p)) ./_rotterdam)
|
||||||
# Common aspects (always included)
|
|
||||||
inputs.self.modules.nixos.common-boot
|
|
||||||
inputs.self.modules.nixos.common-console
|
|
||||||
inputs.self.modules.nixos.common-firewall
|
|
||||||
inputs.self.modules.nixos.common-locale
|
|
||||||
inputs.self.modules.nixos.common-nix
|
|
||||||
inputs.self.modules.nixos.common-openssh
|
|
||||||
inputs.self.modules.nixos.common-programs
|
|
||||||
inputs.self.modules.nixos.common-security
|
|
||||||
inputs.self.modules.nixos.common-services
|
|
||||||
inputs.self.modules.nixos.common-tailscale
|
|
||||||
|
|
||||||
# User aspects
|
|
||||||
inputs.self.modules.nixos.user
|
|
||||||
inputs.self.modules.nixos.root
|
|
||||||
|
|
||||||
# Desktop aspects
|
|
||||||
inputs.self.modules.nixos.desktop-boot
|
|
||||||
inputs.self.modules.nixos.desktop-desktop
|
|
||||||
inputs.self.modules.nixos.desktop-nix
|
|
||||||
inputs.self.modules.nixos.desktop-services
|
|
||||||
|
|
||||||
# Other aspects based on tags
|
|
||||||
inputs.self.modules.nixos.ai
|
|
||||||
inputs.self.modules.nixos.bluetooth
|
|
||||||
inputs.self.modules.nixos.dev
|
|
||||||
inputs.self.modules.nixos.fwupd
|
|
||||||
inputs.self.modules.nixos.gaming-steam
|
|
||||||
inputs.self.modules.nixos.gaming-hardware
|
|
||||||
inputs.self.modules.nixos.gaming-flatpak
|
|
||||||
inputs.self.modules.nixos.gaming-launchers
|
|
||||||
inputs.self.modules.nixos.libvirtd
|
|
||||||
inputs.self.modules.nixos.networkmanager
|
|
||||||
inputs.self.modules.nixos.podman
|
|
||||||
|
|
||||||
# Factory-generated ephemeral module
|
|
||||||
(inputs.self.factory.ephemeral {
|
(inputs.self.factory.ephemeral {
|
||||||
rootDevice = "/dev/mapper/cryptroot";
|
rootDevice = "/dev/mapper/cryptroot";
|
||||||
})
|
})
|
||||||
|
]
|
||||||
|
++ (with inputs.self.modules.nixos; [
|
||||||
|
cli
|
||||||
|
|
||||||
# Host-specific files (from _rotterdam/)
|
# Common aspects (always included)
|
||||||
./_rotterdam/hardware-configuration.nix
|
common-boot
|
||||||
./_rotterdam/boot.nix
|
common-console
|
||||||
./_rotterdam/hardware.nix
|
common-firewall
|
||||||
./_rotterdam/programs.nix
|
common-locale
|
||||||
./_rotterdam/services.nix
|
common-nix
|
||||||
];
|
common-openssh
|
||||||
|
common-programs
|
||||||
|
common-security
|
||||||
|
common-services
|
||||||
|
common-tailscale
|
||||||
|
|
||||||
|
# User aspects
|
||||||
|
user
|
||||||
|
root
|
||||||
|
|
||||||
|
# Desktop aspects
|
||||||
|
desktop-boot
|
||||||
|
desktop-desktop
|
||||||
|
desktop-nix
|
||||||
|
desktop-services
|
||||||
|
|
||||||
|
# Other aspects based on tags
|
||||||
|
ai
|
||||||
|
bluetooth
|
||||||
|
dev
|
||||||
|
fwupd
|
||||||
|
gaming-steam
|
||||||
|
gaming-hardware
|
||||||
|
gaming-flatpak
|
||||||
|
gaming-launchers
|
||||||
|
libvirtd
|
||||||
|
networkmanager
|
||||||
|
podman
|
||||||
|
]);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
{ inputs, self, ... }:
|
{ inputs, lib, ... }:
|
||||||
{
|
{
|
||||||
flake.nixosConfigurations.trantor = inputs.nixpkgs-stable.lib.nixosSystem {
|
flake.nixosConfigurations.trantor = inputs.nixpkgs-stable.lib.nixosSystem {
|
||||||
system = "aarch64-linux";
|
system = "aarch64-linux";
|
||||||
|
|
@ -13,42 +13,36 @@
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
# Common aspects (always included)
|
|
||||||
inputs.self.modules.nixos.common-boot
|
|
||||||
inputs.self.modules.nixos.common-console
|
|
||||||
inputs.self.modules.nixos.common-firewall
|
|
||||||
inputs.self.modules.nixos.common-locale
|
|
||||||
inputs.self.modules.nixos.common-nix
|
|
||||||
inputs.self.modules.nixos.common-openssh
|
|
||||||
inputs.self.modules.nixos.common-programs
|
|
||||||
inputs.self.modules.nixos.common-security
|
|
||||||
inputs.self.modules.nixos.common-services
|
|
||||||
inputs.self.modules.nixos.common-tailscale
|
|
||||||
|
|
||||||
# User aspects
|
|
||||||
inputs.self.modules.nixos.user
|
|
||||||
inputs.self.modules.nixos.root
|
|
||||||
|
|
||||||
# Server aspects
|
|
||||||
inputs.self.modules.nixos.server-boot
|
|
||||||
inputs.self.modules.nixos.server-nix
|
|
||||||
inputs.self.modules.nixos.server-tailscale
|
|
||||||
|
|
||||||
# Factory-generated ephemeral module
|
# Factory-generated ephemeral module
|
||||||
(inputs.self.factory.ephemeral {
|
(inputs.self.factory.ephemeral {
|
||||||
rootDevice = "/dev/disk/by-id/scsi-360b207ed25d84372a95d1ecf842f8e20-part2";
|
rootDevice = "/dev/disk/by-id/scsi-360b207ed25d84372a95d1ecf842f8e20-part2";
|
||||||
})
|
})
|
||||||
|
|
||||||
# Host-specific files (from _trantor/)
|
((inputs.import-tree.initFilter (p: lib.hasSuffix ".nix" p)) ./_trantor)
|
||||||
./_trantor/hardware-configuration.nix
|
]
|
||||||
./_trantor/disko.nix
|
++ (with inputs.self.modules.nixos; [
|
||||||
./_trantor/boot.nix
|
cli
|
||||||
./_trantor/fail2ban.nix
|
|
||||||
./_trantor/forgejo.nix
|
# Common aspects (always included)
|
||||||
./_trantor/networking.nix
|
common-boot
|
||||||
./_trantor/nginx.nix
|
common-console
|
||||||
./_trantor/openssh.nix
|
common-firewall
|
||||||
./_trantor/unbound.nix
|
common-locale
|
||||||
];
|
common-nix
|
||||||
|
common-openssh
|
||||||
|
common-programs
|
||||||
|
common-security
|
||||||
|
common-services
|
||||||
|
common-tailscale
|
||||||
|
|
||||||
|
# User aspects
|
||||||
|
user
|
||||||
|
root
|
||||||
|
|
||||||
|
# Server aspects
|
||||||
|
server-boot
|
||||||
|
server-nix
|
||||||
|
server-tailscale
|
||||||
|
]);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue