Compare commits

..

No commits in common. "136653b0fa0755cfc6ab87875869e4b34c1d9ad1" and "6d2a7f50dfa29f84bc0cbb5b48b1db262d56ca4e" have entirely different histories.

19 changed files with 121 additions and 134 deletions

61
.dotter/global.toml Normal file
View File

@ -0,0 +1,61 @@
[helpers]
[default]
depends = []
[manjaro.files]
manjaro = "~"
[mc.files]
mc = "~/.config/mc"
[vim.files]
# type symbolic prevents interpreting '{{' as template
"vim/.vimrc" = { target = "~/.vimrc", type = "symbolic" }
[nvim.files]
"vim/init.vim" = { target = "~/.config/nvim/init.vim", type = "symbolic" }
[i3.files]
"i3/i3" = "~/.config/i3"
"i3/i3blocks" = { target = "~/.config/i3blocks", type = "symbolic" }
"i3/rofi" = "~/.config/rofi"
"i3/i3-scrot.conf" = "~/.config/i3-scrot.conf"
"i3/i3status-rust" = "~/.config/i3status-rust"
"i3/.profile" = "~/.profile"
[i3.variables]
monitor-primary = "not-specified"
monitor-secondary = "not-specified"
screenlayout-script = "echo screenlayout-script not specified"
bar-font-size = 15
tray-output = "tray_output primary"
[emacs.files]
"emacs/doom" = "~/.config/doom"
# "emacs/spacemacs/.spacemacs" = "~/.spacemacs"
# "emacs/chemacs/.emacs-profiles.el" = "~/.emacs-profiles.el"
[alacritty.files]
alacritty = "~/.config/alacritty"
[starship.files]
starship = "~/.config/"
[zsh.files]
"zsh/.zshrc" = "~/.zshrc"
"zsh/custom-plugins" = "~/.oh-my-zsh/custom"
[polybar.files]
polybar = "~/.config/polybar"
[leftwm.files]
leftwm = "~/.config/leftwm"
[xmonad.files]
xmonad = "~/.xmonad"
[nix.files]
"direnvrc" = "~/.config/direnv/direnvrc"
"nix/configuration.nix" = "/etc/nixos/configuration.nix"
"nix/flake.nix" = "/etc/nixos/flake.nix"

6
.dotter/kardorf.toml Normal file
View File

@ -0,0 +1,6 @@
[i3.variables]
monitor-primary = "DVI-D-0"
monitor-secondary = "DVI-D-1"
screenlayout-script = "~/.screenlayout/2desktop-dvi.sh"
bar-font-size = 15
tray-output = "tray_output DVI-D-1"

View File

@ -0,0 +1,4 @@
[i3.variables]
monitor-primary = "HDMI-1"
monitor-secondary = "eDP-1"
screenlayout-script = "~/.screenlayout/laptop-at-home.sh"

5
.dotter/laptop.toml Normal file
View File

@ -0,0 +1,5 @@
[i3.variables]
monitor-primary = "HDMI-1"
monitor-secondary = "eDP-1"
tray-output = "tray_output eDP-1"
screenlayout-script = "$scripts/display-layoutpicker"

View File

@ -0,0 +1,2 @@
includes = [".dotter/kardorf.toml"]
packages = ["i3", "emacs", "alacritty", "zsh", "starship", "nix"]

View File

@ -0,0 +1,2 @@
includes = [".dotter/laptop.toml"]
packages = []

View File

@ -3,8 +3,6 @@ keys:
- &aspi-ssh age1q8lc5340gz5xw2f57nglrss68wv0j0hf36py2pdtrl6ky3yrq9qqk0njr4 - &aspi-ssh age1q8lc5340gz5xw2f57nglrss68wv0j0hf36py2pdtrl6ky3yrq9qqk0njr4
- &pianonix-ssh age1hsmfz8fjxu83sax9lr487h8xr6cyge0apdq4zpge4c8jpcjj2cksj825ct - &pianonix-ssh age1hsmfz8fjxu83sax9lr487h8xr6cyge0apdq4zpge4c8jpcjj2cksj825ct
- &builder-ssh age1kw4kmdm45zprvdkrrpvgq966l7585vhusmum083qlwnr0xxgd3uqatcyja - &builder-ssh age1kw4kmdm45zprvdkrrpvgq966l7585vhusmum083qlwnr0xxgd3uqatcyja
- &kardorf-ssh age15lxw97z03q40xrdscnxqqugh5ky5aqrerg2t2rphkcqm6rnllurq8v98q5
creation_rules: creation_rules:
- path_regex: hosts/common/secrets.yaml$ - path_regex: hosts/common/secrets.yaml$
key_groups: key_groups:
@ -12,7 +10,6 @@ creation_rules:
- *primary - *primary
- *aspi-ssh - *aspi-ssh
- *pianonix-ssh - *pianonix-ssh
- *kardorf-ssh
- path_regex: hosts/builder/secrets.yaml$ - path_regex: hosts/builder/secrets.yaml$
key_groups: key_groups:

View File

@ -106,7 +106,7 @@
}; };
}; };
kardorf = lib.nixosSystem { kardorf = lib.nixosSystem {
modules = [./hosts/kardorf]; modules = [./hosts/pianonix];
specialArgs = { specialArgs = {
inherit inputs outputs; inherit inputs outputs;
}; };
@ -148,7 +148,7 @@
./homes/julian/kardorf.nix ./homes/julian/kardorf.nix
./homes/julian/hm-standalone-config.nix ./homes/julian/hm-standalone-config.nix
]; ];
pkgs = pkgsFor.x86_64-linux; pkgs = pkgsFor.aarch64-linux;
extraSpecialArgs = { extraSpecialArgs = {
inherit inputs outputs; inherit inputs outputs;
}; };
@ -158,7 +158,7 @@
./homes/julian/v3ms ./homes/julian/v3ms
./homes/julian/hm-standalone-config.nix ./homes/julian/hm-standalone-config.nix
]; ];
pkgs = pkgsFor.x86_64-linux; pkgs = pkgsFor.aarch64-linux;
extraSpecialArgs = { extraSpecialArgs = {
inherit inputs outputs; inherit inputs outputs;
}; };

View File

@ -21,35 +21,4 @@
hostName = "aspi"; hostName = "aspi";
is-nixos = true; is-nixos = true;
terminal = "kitty"; terminal = "kitty";
# ------- ----------
# | eDP-1 | | HDMI-A-1 |
# ------- ----------
monitors = [
{
name = "HDMI-A-1";
# width = 1680;
# height = 1050;
workspaces = [
"1"
"2"
"3"
"4"
"5"
];
primary = true;
}
{
name = "eDP-1";
# width = 1680;
# height = 1050;
workspaces = [
"6"
"7"
"8"
"9"
"10"
];
}
];
} }

View File

@ -142,7 +142,7 @@ in {
"$mod" = "SUPER"; "$mod" = "SUPER";
# Monitors # Monitors
monitor = ",preferred,auto,1"; monitor = ",preferred,auto,auto";
# Autostart # Autostart
exec-once = ["firefox"]; exec-once = ["firefox"];
@ -231,17 +231,23 @@ in {
]; ];
# Workspace rules # Workspace rules
workspace = workspace = [
[ "1, monitor:HDMI-A-1"
# smart gaps (none when only one window in workspace) "2, monitor:HDMI-A-1"
"w[t1], gapsin:0, gapsout:0, border:1" "3, monitor:HDMI-A-1"
"w[tg1], gapsin:0, gapsout:0, border:1" "4, monitor:HDMI-A-1"
"f[1], gapsin:0, gapsout:0, border:1" "5, monitor:HDMI-A-1"
] "6, monitor:eDP-1"
# builds like "1, e-DP1" "2, HDMI-1" etc. "7, monitor:eDP-1"
++ builtins.concatLists ( "8, monitor:eDP-1"
map (monitor: map (ws: "${ws}, monitor:${monitor.name}") monitor.workspaces) config.monitors "9, monitor:eDP-1"
); "10, monitor:eDP-1"
# smart gaps (none when only one window in workspace)
"w[t1], gapsin:0, gapsout:0, border:1"
"w[tg1], gapsin:0, gapsout:0, border:1"
"f[1], gapsin:0, gapsout:0, border:1"
];
# Mouse binds # Mouse binds
bindm = [ bindm = [

View File

@ -12,7 +12,6 @@
./features/emacs ./features/emacs
./features/hyprland ./features/hyprland
# ./features/i3
./features/suites/cli ./features/suites/cli
./features/suites/desktop ./features/suites/desktop
@ -22,35 +21,4 @@
hostName = "kardorf"; hostName = "kardorf";
is-nixos = true; is-nixos = true;
terminal = "kitty"; terminal = "kitty";
# --------- ---------
# | DVI-D-1 | | DVI-D-2 |
# --------- ---------
monitors = [
{
name = "DVI-D-1";
width = 1680;
height = 1050;
workspaces = [
"1"
"2"
"3"
"4"
"5"
];
primary = true;
}
{
name = "DVI-D-2";
width = 1680;
height = 1050;
workspaces = [
"6"
"7"
"8"
"9"
"10"
];
}
];
} }

View File

@ -8,7 +8,6 @@
# TODO: apply this to hm and nixos without duplicate code # TODO: apply this to hm and nixos without duplicate code
overlays = builtins.attrValues outputs.overlays; overlays = builtins.attrValues outputs.overlays;
config = { config = {
nvidia.acceptLicense = true;
allowUnfree = true; allowUnfree = true;
allowUnfreePredicate = _: true; # TODO: what is this allowUnfreePredicate = _: true; # TODO: what is this
warn-dirty = false; warn-dirty = false;

View File

@ -15,7 +15,7 @@ in {
# TODO: remove? only rely on ssh or pgp keys (e.g. ubikey like misterio is using!!!) # TODO: remove? only rely on ssh or pgp keys (e.g. ubikey like misterio is using!!!)
keyFile = "/home/julian/.config/sops/age/keys.txt"; keyFile = "/home/julian/.config/sops/age/keys.txt";
# Generate key if none of the above worked. With this, building will still work, just without secrets # Generate key if none of the above worked. With this, building will still work, just without secrets
generateKey = false; # TODO: building should not work without secrets!? generateKey = true;
}; };
sops.defaultSopsFile = ../secrets.yaml; sops.defaultSopsFile = ../secrets.yaml;

View File

@ -0,0 +1,13 @@
{
config,
lib,
pkgs,
inputs,
...
}: {
programs.hyprland.enable = true;
programs.hyprland.package = inputs.hyprland.packages.${pkgs.system}.hyprland; # does only work with nixos-unstable
programs.hyprland.xwayland.enable = true;
security.pam.services.hyprlock = {};
services.displayManager.defaultSession = "hyprland";
}

View File

@ -28,8 +28,7 @@ in {
openssh.authorizedKeys.keys = lib.splitString "\n" ( openssh.authorizedKeys.keys = lib.splitString "\n" (
builtins.readFile ../../../../homes/julian/ssh.pub builtins.readFile ../../../../homes/julian/ssh.pub
); );
# hashedPasswordFile = config.sops.secrets.julian-password.path; hashedPasswordFile = config.sops.secrets.julian-password.path;
hashedPassword = "$y$j9T$N33kLJQbV8soUoCbDkpwA1$r/yahJDgOPo4GGOrAi6BUG5zLTzmaBrA5NQ4nno561A";
packages = [pkgs.home-manager]; packages = [pkgs.home-manager];
}; };
users.groups.julian = { users.groups.julian = {

View File

@ -1,30 +0,0 @@
{
pkgs,
config,
...
}: let
ifTheyExist = groups: builtins.filter (group: builtins.hasAttr group config.users.groups) groups;
in {
users.mutableUsers = false;
users.users.wolfi = {
description = "Wolfi";
group = "wolfi";
isNormalUser = true;
shell = pkgs.fish;
extraGroups = ifTheyExist [
"networkmanager"
"wheel"
"audio"
"network"
"video"
"podman"
"docker"
"git"
"gamemode"
];
hashedPassword = "$y$j9T$ifzWjoZaRtPUOOfMYnbJ20$uFOO1EyDApL52vRUicZYgupaTA/a6sGNUj3imZ/lcb6";
packages = [pkgs.home-manager];
};
users.groups.wolfi = {};
}

View File

@ -4,15 +4,11 @@
../common/global ../common/global
../common/users/julian ../common/users/julian
../common/users/wolfi
../common/optional/remote-builder.nix ../common/optional/remote-builder.nix
../common/optional/boot-efi.nix ../common/optional/boot-efi.nix
../common/optional/greetd.nix ../common/optional/greetd.nix
# ../common/optional/gdm.nix
# ../common/optional/i3.nix
../common/optional/authentication.nix ../common/optional/authentication.nix
../common/optional/pcmanfm.nix ../common/optional/pcmanfm.nix
../common/optional/pipewire.nix ../common/optional/pipewire.nix
@ -24,18 +20,12 @@
networking.hostName = "kardorf"; networking.hostName = "kardorf";
system.stateVersion = "22.11"; system.stateVersion = "22.11";
# Not using the drivers leads to way better results services.xserver.videoDrivers = ["nvidia"];
# services.xserver.videoDrivers = [ "nvidia" ];
programs.kdeconnect.enable = true; programs.kdeconnect.enable = true;
# services.xserver.desktopManager.xfce.enable = true;
services.xserver.desktopManager.plasma6.enable = true;
# Enable CUPS to print documents. # Enable CUPS to print documents.
services.printing.enable = true; services.printing.enable = true;
services.printing.browsing = true; services.printing.browsing = true;
services.printing.drivers = with pkgs; [gutenprint]; services.printing.drivers = with pkgs; [gutenprint];
services.libinput.enable = true;
} }

View File

@ -12,12 +12,11 @@
"xhci_pci" "xhci_pci"
"usbhid" "usbhid"
"uas" "uas"
"usb_storage"
"sd_mod" "sd_mod"
"sr_mod" "sr_mod"
]; ];
boot.initrd.kernelModules = []; boot.initrd.kernelModules = [];
boot.kernelModules = ["kvm-intel"]; boot.kernelModules = [];
boot.extraModulePackages = []; boot.extraModulePackages = [];
boot.loader.efi.efiSysMountPoint = "/boot/efi"; boot.loader.efi.efiSysMountPoint = "/boot/efi";
@ -81,8 +80,5 @@
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.legacy_470; hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.legacy_470;
# hardware.nvidia.modesetting.enable = true; # produces errors, display manager fails to start # hardware.nvidia.modesetting.enable = true; # for wayland
# hardware.nvidia.nvidiaSettings = true;
hardware.nvidia.open = false;
} }

View File

@ -37,8 +37,8 @@ in {
type = types.bool; type = types.bool;
default = true; default = true;
}; };
workspaces = mkOption { workspace = mkOption {
type = types.nullOr (types.listOf types.str); type = types.nullOr types.str;
default = null; default = null;
}; };
}; };