another another installer attempt

This commit is contained in:
2024-10-20 13:44:44 -05:00
parent a97a749a5f
commit 82ca092265
10 changed files with 203 additions and 2132 deletions

1982
flake.lock generated

File diff suppressed because it is too large Load Diff

View File

@@ -64,31 +64,52 @@
#inherit iso_system; #inherit iso_system;
specialArgs = { specialArgs = {
core_inputs = (core_inputs // {host = "live";}); core_inputs = (core_inputs // {host = "installer";});
}; };
modules = [ modules = [
({ pkgs, modulesPath, ... }: { ({ lib, pkgs, modulesPath, ... }: {
imports = [ imports = [
(modulesPath + "/installer/cd-dvd/installation-cd-minimal.nix") (modulesPath + "/installer/cd-dvd/installation-cd-minimal.nix")
]; ];
environment.etc = { homeconfig = {
"nixos/disko/default.nix".source = ./system/disko/default.nix; minimal = true;
"nixos/disko/disko.nix".source = ./system/disko/disko.nix; externalPackages.enable = false;
"nixos/disko/disko_bonus.nix".source = ./system/disko/disko_bonus.nix; calcurse.enable = false;
"nixos/disko/impermanent.nix".source = ./system/disko/impermanent.nix; wayvnc.enable = true;
"nixos/impermanence/default.nix".source = ./system/impermanence/default.nix; rofi.enable = true;
"nixos/flake.nix".source = ./system/configuration/live/flake.nix; mpd.enable = false;
wal.enable = true;
ags.enable = true;
hyprland.enable = true;
swaylock.enable = true;
}; };
services.openssh = { sysconfig = {
enable = true; opts = {
firstBoot = true;
host = "installer";
inherit username;
openssh.enable = true;
hyprland.enable = true;
ags.enable = true;
pipewire.enable = true;
git.enable = true;
steam.enable = false;
nh.enable = false;
};
};
disko.enable = lib.mkForce false;
nix.settings = {
experimental-features = [ "nix-command" "flakes" ];
}; };
networking = { networking = {
hostName = "live"; hostName = "installer";
firewall.allowedTCPPorts = [ 22 ]; firewall.allowedTCPPorts = [ 22 ];
}; };
@@ -96,6 +117,9 @@
}) })
core_inputs.system.module
core_inputs.home-manager.nixosModules.home-manager
]; ];
}; };

View File

@@ -4,71 +4,68 @@
(lib.mkIf config.homeconfig.ags.enable { (lib.mkIf config.homeconfig.ags.enable {
home.file = let home.file = let
files = [ dir = "ags";
"ags/bluetooth.js" in builtins.mapAttrs (
"ags/brightness.js" n: v: { source = v.value; target = v.name; }) (
"ags/clock.js" builtins.mapAttrs (
"ags/config.js" _name: _value: {
"ags/media.js" name = ".config/${dir}/${_name}"; value = ./${dir}/${_name};
"ags/notif.js" }
"ags/notification.js" ) (builtins.readDir ./${dir})
"ags/power.js" );
"ags/settings.js"
"ags/systemtray.js"
"ags/wifi.js"
"ags/workspaces.js"
];
in builtins.mapAttrs (n: v: { source = v; target = n; }) (builtins.listToAttrs (builtins.map (_name: { name = ".config/${_name}"; value = ./${_name}; }) files));
})
(lib.mkIf config.homeconfig.hyprland.enable {
home.file = let
files = [
"Wallpaper/sao.gif"
"Wallpaper/sao.png"
"Wallpaper/ngnl.jpg"
"Wallpaper/llenn.png"
"Wallpaper/sinon.gif"
"Wallpaper/galaxy.jpg"
"Wallpaper/kurisu.gif"
"Wallpaper/kurisu.jpg"
"Wallpaper/rezero.gif"
"Wallpaper/megumin.png"
"Wallpaper/megumin1.gif"
"Wallpaper/megumin2.gif"
"Wallpaper/bluescape.jpg"
"Wallpaper/orangescape.jpg"
];
in builtins.mapAttrs (n: v: { source = v; target = n; }) (builtins.listToAttrs (builtins.map (_name: { name = "Pictures/${_name}"; value = ./${_name}; }) files));
}) })
(lib.mkIf config.homeconfig.hyprland.enable { (lib.mkIf config.homeconfig.hyprland.enable {
home.file = let home.file = let
files = [ dir = "Wallpaper";
"hypr/otf.conf" in builtins.mapAttrs (
"hypr/pyprland.toml" n: v: { source = v.value; target = v.name; }) (
"hypr/main.conf" builtins.mapAttrs (
]; _name: _value: {
in builtins.mapAttrs (n: v: { source = v; target = n; }) (builtins.listToAttrs (builtins.map (_name: { name = ".config/${_name}"; value = ./${_name}; }) files)); name = ".config/${dir}/${_name}"; value = ./${dir}/${_name};
}
) (builtins.readDir ./${dir})
);
})
(lib.mkIf config.homeconfig.hyprland.enable {
home.file = let
dir = "Wallpaper";
in builtins.mapAttrs (
n: v: { source = v.value; target = v.name; }) (
builtins.mapAttrs (
_name: _value: {
name = ".config/${dir}/${_name}"; value = ./${dir}/${_name};
}
) (builtins.readDir ./${dir})
);
}) })
(lib.mkIf config.homeconfig.swaylock.enable { (lib.mkIf config.homeconfig.swaylock.enable {
home.file = let home.file = let
files = [ dir = "swaylock";
"swaylock/config" in builtins.mapAttrs (
]; n: v: { source = v.value; target = v.name; }) (
in builtins.mapAttrs (n: v: { source = v; target = n; }) (builtins.listToAttrs (builtins.map (_name: { name = ".config/${_name}"; value = ./${_name}; }) files)); builtins.mapAttrs (
_name: _value: {
name = ".config/${dir}/${_name}"; value = ./${dir}/${_name};
}
) (builtins.readDir ./${dir})
);
}) })
(lib.mkIf config.homeconfig.wal.enable { (lib.mkIf config.homeconfig.wal.enable {
home.file = let home.file = let
files = [ dir = "wal";
"wal/templates/cava_config" in builtins.mapAttrs (
"wal/templates/colors-ags.css" n: v: { source = v.value; target = v.name; }) (
"wal/templates/colors-discord.css" builtins.mapAttrs (
"wal/templates/colors-hypr.conf" _name: _value: {
]; name = ".config/${dir}/${_name}"; value = ./${dir}/${_name};
in builtins.mapAttrs (n: v: { source = v; target = n; }) (builtins.listToAttrs (builtins.map (_name: { name = ".config/${_name}"; value = ./${_name}; }) files)); }
) (builtins.readDir ./${dir})
);
}) })
]; ];
} }

View File

@@ -32,18 +32,6 @@
home.homeDirectory = "/home/nathan"; home.homeDirectory = "/home/nathan";
homeconfig = {
calcurse.enable = true;
wayvnc.enable = true;
rofi.enable = true;
mpd.enable = true;
wal.enable = true;
ags.enable = true;
hyprland.enable = true;
swaylock.enable = true;
};
home.pointerCursor = { home.pointerCursor = {
gtk.enable = true; gtk.enable = true;
package = pkgs.bibata-cursors; package = pkgs.bibata-cursors;
@@ -58,8 +46,6 @@
iconTheme.name = "Tokyonight-Dark"; iconTheme.name = "Tokyonight-Dark";
}; };
externalPackages.enable = true;
services.mpris-proxy.enable = true; services.mpris-proxy.enable = true;
programs.ssh.enable = true; programs.ssh.enable = true;

View File

@@ -1,84 +1,101 @@
{ pkgs, pkgs-us, self, ... }: { { config, lib, pkgs, pkgs-us, self, ... }: {
imports = [ imports = [
self.inputs.scripts.hmModule self.inputs.scripts.hmModule
self.inputs.external.hmModule self.inputs.external.hmModule
]; ];
nixpkgs.config.allowUnfree = true; options.homeconfig.minimal = lib.options.mkOption {
type = lib.types.bool;
default = false;
};
home.packages = with pkgs; let config = lib.mkMerge [
pypkgs = ps: with ps; [
numpy
pandas
torch
torchvision
torchaudio
transformers
datasets
pyaudio
faster-whisper
pyusb
];
in [ {
home.packages = with pkgs; [
killall
zip
unzip
gcc
zulu
rsync
lxqt.lxqt-policykit
blueberry
wl-clipboard
firefox-wayland
xfce.thunar
grim
slurp
];
}
cava (lib.mkIf (!config.homeconfig.minimal) {
gcc
android-tools
neovim-remote
(pkgs.python311.withPackages pypkgs) nixpkgs.config.allowUnfree = true;
brightnessctl home.packages = with pkgs; let
libdbusmenu-gtk3 pypkgs = ps: with ps; [
zulu numpy
lmms pandas
killall torch
#unfree { torchvision
geogebra torchaudio
#} transformers
blueberry datasets
wl-clipboard pyaudio
firefox-wayland faster-whisper
pyusb
];
neofetch in [
pkgs-us.mpv
(ncmpcpp.override { visualizerSupport = true; clockSupport = true; })
playerctl
mpc-cli
xfce.thunar
vlc
zip
unzip
pavucontrol
yewtube
ytmdl
ffmpeg_5
lxqt.lxqt-policykit
rpi-imager
rsync
grim
slurp
tigervnc
keepassxc
httplz
#school? cava
#pkgs-us.digital android-tools
neovim-remote
#3D modeling/printing (pkgs.python311.withPackages pypkgs)
kicad
blender
freecad
cura
#productivity brightnessctl
libreoffice libdbusmenu-gtk3
super-productivity lmms
#unfree {
geogebra
#}
#games neofetch
prismlauncher pkgs-us.mpv
]; (ncmpcpp.override { visualizerSupport = true; clockSupport = true; })
playerctl
mpc-cli
vlc
pavucontrol
yewtube
ytmdl
ffmpeg_5
rpi-imager
tigervnc
keepassxc
httplz
#school?
#pkgs-us.digital
#3D modeling/printing
kicad
blender
freecad
cura
#productivity
libreoffice
super-productivity
#games
prismlauncher
];
})
];
} }

View File

@@ -1,13 +1,13 @@
{ config, lib, pkgs, self, ... }: { { config, lib, pkgs, self, ... }: {
options = { options = {
externalPackages.enable = lib.options.mkOption { homeconfig.externalPackages.enable = lib.options.mkOption {
type = lib.types.bool; type = lib.types.bool;
default = false; default = false;
}; };
}; };
config = lib.mkIf config.externalPackages.enable { config = lib.mkIf config.homeconfig.externalPackages.enable {
home.packages = [ home.packages = [
self.packages.${pkgs.system}.digital self.packages.${pkgs.system}.digital
]; ];

View File

@@ -76,8 +76,8 @@
environment = { environment = {
sessionVariables = { sessionVariables = {
WLR_BACKENDS = "headless"; # WLR_BACKENDS = "headless";
WLR_LIBINPUT_NO_DEVICES = "1"; # WLR_LIBINPUT_NO_DEVICES = "1";
}; };
}; };

19
system/disko/flake.nix Normal file
View File

@@ -0,0 +1,19 @@
{
description = "disko config";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
disko.url = "github:nix-community/disko";
disko.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = { self, ... }@inputs: {
module = { config, lib, pkgs, ... }: {
imports = [
(import ./default.nix { inherit config lib pkgs; })
inputs.disko.nixosModules.default
];
};
};
}

0
system/etc/default.nix Normal file
View File

View File

@@ -0,0 +1,10 @@
{
description = "nix impermanence config";
inputs.impermanence.url = "github:nix-community/impermanence";
outputs = { self, ... }: {
module = { config, lib, ... }: import ./. { inherit config lib self; };
};
}