code cleanup (#47)
Some checks are pending
flakehub / flakehub-publish (push) Waiting to run
git-mirror / gitlab-sync (push) Waiting to run
nix-build / default-build (push) Waiting to run
nix-build / fallarbor-build (push) Waiting to run
nix-build / lavaridge-build (push) Waiting to run
nix-build / mauville-build (push) Waiting to run
nix-build / petalburg-build (push) Waiting to run
nix-build / rustboro-build (push) Waiting to run
nix-check / fmt-check (push) Waiting to run
nix-check / eval-check (push) Waiting to run

* remove unused variables and nesting issues

* more code cleanups and build fixes

* cleanup sway

* base/plymouth: removed unnecessary font override

* hosts/common: remove unnecessary host checks
This commit is contained in:
Aly Raffauf 2024-07-18 21:05:35 -04:00 committed by GitHub
parent fa2d6a7d72
commit deb36b44e1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
69 changed files with 94 additions and 256 deletions

View file

@ -1,59 +0,0 @@
name: "nix-drybuild"
on:
push:
paths-ignore:
- '*.md'
- '.github/**'
- '_img/**'
workflow_dispatch:
jobs:
fallarbor-drybuild:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@main
with:
fetch-depth: 1
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Drybuild fallarbor
run: nix build --dry-run .#nixosConfigurations.fallarbor.config.system.build.toplevel
lavaridge-drybuild:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@main
with:
fetch-depth: 1
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Drybuild lavaridge
run: nix build --dry-run .#nixosConfigurations.lavaridge.config.system.build.toplevel
mauville-drybuild:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@main
with:
fetch-depth: 1
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Drybuild mauville
run: nix build --dry-run .#nixosConfigurations.mauville.config.system.build.toplevel
petalburg-drybuild:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@main
with:
fetch-depth: 1
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Drybuild petalburg
run: nix build --dry-run .#nixosConfigurations.petalburg.config.system.build.toplevel
rustboro-drybuild:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@main
with:
fetch-depth: 1
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Drybuild rustboro
run: nix build --dry-run .#nixosConfigurations.rustboro.config.system.build.toplevel

View file

@ -5,7 +5,6 @@ variables:
GIT_STRATEGY: clone GIT_STRATEGY: clone
GIT_DEPTH: 1 GIT_DEPTH: 1
stages: stages:
- "Update" - "Update"
- "Checks" - "Checks"

View file

@ -1,17 +1,8 @@
self: { self: {lib, ...}: {
config,
lib,
pkgs,
...
}: {
boot = { boot = {
consoleLogLevel = 0; consoleLogLevel = 0;
initrd.verbose = false; initrd.verbose = false;
plymouth.enable = true;
plymouth = {
enable = true;
font = "${pkgs.nerdfonts.override {fonts = ["Noto"];}}/share/fonts/truetype/NerdFonts/NotoSansNerdFont-Regular.ttf";
};
}; };
console.useXkbConfig = true; console.useXkbConfig = true;
@ -59,6 +50,7 @@ self: {
enable = true; enable = true;
nssmdns4 = true; nssmdns4 = true;
openFirewall = true; openFirewall = true;
publish = { publish = {
enable = true; enable = true;
addresses = true; addresses = true;
@ -80,7 +72,6 @@ self: {
}; };
printing.enable = true; printing.enable = true;
system-config-printer.enable = true; system-config-printer.enable = true;
}; };

View file

@ -1,7 +1,6 @@
{ {
pkgs,
lib,
config, config,
lib,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.alacritty.enable { config = lib.mkIf config.ar.home.apps.alacritty.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: let }: let
cfg = config.ar.home.apps.backblaze; cfg = config.ar.home.apps.backblaze;

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.bash.enable { config = lib.mkIf config.ar.home.apps.bash.enable {

View file

@ -1,7 +1,6 @@
{ {
pkgs,
lib,
config, config,
lib,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.chromium.enable { config = lib.mkIf config.ar.home.apps.chromium.enable {

View file

@ -1,9 +1,4 @@
{ {
config,
lib,
pkgs,
...
}: {
imports = [ imports = [
./alacritty ./alacritty
./backblaze ./backblaze

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.emacs.enable { config = lib.mkIf config.ar.home.apps.emacs.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.fastfetch.enable { config = lib.mkIf config.ar.home.apps.fastfetch.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.firefox.enable { config = lib.mkIf config.ar.home.apps.firefox.enable {

View file

@ -1,7 +1,6 @@
{ {
pkgs,
lib,
config, config,
lib,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.fuzzel.enable { config = lib.mkIf config.ar.home.apps.fuzzel.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.keepassxc.enable { config = lib.mkIf config.ar.home.apps.keepassxc.enable {

View file

@ -1,7 +1,6 @@
{ {
pkgs,
lib,
config, config,
lib,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.librewolf.enable { config = lib.mkIf config.ar.home.apps.librewolf.enable {

View file

@ -1,7 +1,6 @@
{ {
pkgs,
lib,
config, config,
lib,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.mako.enable { config = lib.mkIf config.ar.home.apps.mako.enable {

View file

@ -1,16 +1,15 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.nemo.enable { config = lib.mkIf config.ar.home.apps.nemo.enable {
home.packages = with pkgs; [ home.packages = [pkgs.cinnamon.nemo];
cinnamon.nemo
];
dconf = { dconf = {
enable = true; enable = true;
settings = { settings = {
"org/nemo/preferences" = { "org/nemo/preferences" = {
show-image-thumbnails = "always"; show-image-thumbnails = "always";

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.swaylock.enable { config = lib.mkIf config.ar.home.apps.swaylock.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.thunar.enable { config = lib.mkIf config.ar.home.apps.thunar.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.tmux.enable { config = lib.mkIf config.ar.home.apps.tmux.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.vsCodium.enable { config = lib.mkIf config.ar.home.apps.vsCodium.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.waybar.enable { config = lib.mkIf config.ar.home.apps.waybar.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.apps.wlogout.enable { config = lib.mkIf config.ar.home.apps.wlogout.enable {

View file

@ -95,6 +95,7 @@
ui_font_size = 16; ui_font_size = 16;
vim_mode = false; vim_mode = false;
}; };
settings = defaults // config.ar.home.apps.zed.settings; settings = defaults // config.ar.home.apps.zed.settings;
in in
lib.generators.toJSON {} settings; lib.generators.toJSON {} settings;

View file

@ -1,9 +1,4 @@
self: { self: {
config,
pkgs,
lib,
...
}: {
imports = [ imports = [
./apps ./apps
./defaultApps.nix ./defaultApps.nix

View file

@ -1,7 +1,6 @@
{ {
config, config,
lib, lib,
pkgs,
... ...
}: let }: let
cfg = config.ar.home.defaultApps; cfg = config.ar.home.defaultApps;

View file

@ -1,5 +1,4 @@
{ {
pkgs,
lib, lib,
config, config,
... ...

View file

@ -2,7 +2,6 @@
config, config,
lib, lib,
osConfig, osConfig,
pkgs,
... ...
}: { }: {
imports = [ imports = [

View file

@ -1,5 +1,4 @@
{ {
pkgs,
lib, lib,
config, config,
... ...

View file

@ -2,7 +2,6 @@
config, config,
lib, lib,
pkgs, pkgs,
self,
... ...
}: let }: let
cfg = config.ar.home; cfg = config.ar.home;

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
imports = [./randomWallpaper.nix ./redShift.nix]; imports = [./randomWallpaper.nix ./redShift.nix];
@ -26,18 +26,7 @@
editor = lib.getExe config.ar.home.defaultApps.editor; editor = lib.getExe config.ar.home.defaultApps.editor;
terminal = lib.getExe config.ar.home.defaultApps.terminal; terminal = lib.getExe config.ar.home.defaultApps.terminal;
brightness = lib.getExe' pkgs.swayosd "swayosd-client";
brightness_up = "${brightness} --brightness=raise";
brightness_down = "${brightness} --brightness=lower";
volume = brightness;
volume_up = "${volume} --output-volume=raise";
volume_down = "${volume} --output-volume=lower";
volume_mute = "${volume} --output-volume=mute-toggle";
mic_mute = "${volume} --input-volume=mute-toggle";
media = lib.getExe pkgs.playerctl; media = lib.getExe pkgs.playerctl;
media_play = "${media} play-pause";
media_next = "${media} next";
media_prev = "${media} previous";
# Sway desktop utilities # Sway desktop utilities
bar = lib.getExe pkgs.waybar; bar = lib.getExe pkgs.waybar;
@ -66,9 +55,6 @@
screenshot_screen = "${screenshot} --capture output"; screenshot_screen = "${screenshot} --capture output";
screenshot_region = "${screenshot} --capture region"; screenshot_region = "${screenshot} --capture region";
qt_platform_theme = "qt6ct";
gdk_scale = "1.5";
cycleSwayDisplayModes = pkgs.writeShellScriptBin "cycleSwayDisplayModes" '' cycleSwayDisplayModes = pkgs.writeShellScriptBin "cycleSwayDisplayModes" ''
# TODO: remove petalburg hardcodes # TODO: remove petalburg hardcodes
current_mode=$(${lib.getExe' config.wayland.windowManager.sway.package "swaymsg"} -t get_outputs -p | grep "Current mode" | grep -Eo '[0-9]+x[0-9]+ @ [0-9.]+ Hz' | tr -d " " | grep 2880) current_mode=$(${lib.getExe' config.wayland.windowManager.sway.package "swaymsg"} -t get_outputs -p | grep "Current mode" | grep -Eo '[0-9]+x[0-9]+ @ [0-9.]+ Hz' | tr -d " " | grep 2880)

View file

@ -2,7 +2,6 @@
config, config,
lib, lib,
pkgs, pkgs,
self,
... ...
}: let }: let
sway-randomWallpaper = pkgs.writeShellScriptBin "sway-randomWallpaper" '' sway-randomWallpaper = pkgs.writeShellScriptBin "sway-randomWallpaper" ''
@ -38,7 +37,10 @@
''; '';
in { in {
config = lib.mkIf config.ar.home.desktop.sway.randomWallpaper { config = lib.mkIf config.ar.home.desktop.sway.randomWallpaper {
home.packages = with pkgs; [swaybg sway-randomWallpaper]; home.packages = [
pkgs.swaybg
sway-randomWallpaper
];
wayland.windowManager.sway.config.startup = [ wayland.windowManager.sway.config.startup = [
{command = "${lib.getExe sway-randomWallpaper}";} {command = "${lib.getExe sway-randomWallpaper}";}

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.home.desktop.sway.redShift { config = lib.mkIf config.ar.home.desktop.sway.redShift {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf (config.ar.home.desktop.hyprland.enable || config.ar.home.desktop.sway.enable) { config = lib.mkIf (config.ar.home.desktop.hyprland.enable || config.ar.home.desktop.sway.enable) {
@ -16,7 +16,7 @@
dconf = { dconf = {
enable = true; enable = true;
settings = { settings = {
"org/gnome/desktop/wm/preferences" = {button-layout = "";}; "org/gnome/desktop/wm/preferences".button-layout = "";
"org/gnome/nm-applet".disable-connected-notifications = true; "org/gnome/nm-applet".disable-connected-notifications = true;
}; };
}; };

View file

@ -1,8 +1,6 @@
{ {
config, imports = [
lib, ./easyeffects
pkgs, ./mpd
... ];
}: {
imports = [./easyeffects ./mpd];
} }

View file

@ -1,5 +1,4 @@
{ {
pkgs,
lib, lib,
config, config,
... ...

View file

@ -1,5 +1,4 @@
{ {
pkgs,
lib, lib,
config, config,
... ...

View file

@ -1,6 +1,5 @@
{ {
config, config,
lib,
pkgs, pkgs,
... ...
}: { }: {

View file

@ -1,6 +1,5 @@
self: { self: {
config, config,
lib,
pkgs, pkgs,
... ...
}: { }: {

View file

@ -32,7 +32,7 @@
home-manager.sharedModules = [ home-manager.sharedModules = [
{ {
gtk.gtk3.bookmarks = lib.optionals (config.networking.hostName != "mauville") [ gtk.gtk3.bookmarks = [
"file:///mnt/Media" "file:///mnt/Media"
"file:///mnt/Archive" "file:///mnt/Archive"
]; ];

View file

@ -1,8 +1,6 @@
# Framework 13 with 11th gen Intel Core i5, 16GB RAM, 512GB SSD. # Framework 13 with 11th gen Intel Core i5, 16GB RAM, 512GB SSD.
{ {
config, config,
lib,
pkgs,
self, self,
... ...
}: { }: {

View file

@ -1,9 +1,4 @@
{ {
config,
lib,
pkgs,
...
}: {
home-manager.sharedModules = [ home-manager.sharedModules = [
{ {
ar.home.desktop.hyprland.laptopMonitors = ["desc:BOE 0x095F,preferred,auto,1.566667"]; ar.home.desktop.hyprland.laptopMonitors = ["desc:BOE 0x095F,preferred,auto,1.566667"];

View file

@ -1,8 +1,6 @@
# Framework Laptop 13 with AMD Ryzen 7640U, 32GB RAM, 1TB SSD. # Framework Laptop 13 with AMD Ryzen 7640U, 32GB RAM, 1TB SSD.
{ {
config, config,
lib,
pkgs,
self, self,
... ...
}: { }: {

View file

@ -1,9 +1,4 @@
{ {
config,
lib,
pkgs,
...
}: {
home-manager.sharedModules = [ home-manager.sharedModules = [
{ {
ar.home = { ar.home = {

View file

@ -1,5 +1,4 @@
{ {
config,
lib, lib,
pkgs, pkgs,
self, self,

View file

@ -1,8 +1,6 @@
# Lenovo Yoga 9i Convertible with Intel Core i7-1360P, 16GB RAM, 512GB SSD. # Lenovo Yoga 9i Convertible with Intel Core i7-1360P, 16GB RAM, 512GB SSD.
{ {
config, config,
lib,
pkgs,
self, self,
... ...
}: { }: {

View file

@ -1,5 +1,4 @@
{ {
config,
lib, lib,
pkgs, pkgs,
self, self,

View file

@ -1,8 +1,6 @@
# Lenovo Thinkpad T440p with a Core i5 4210M, 16GB RAM, 512GB SSD. # Lenovo Thinkpad T440p with a Core i5 4210M, 16GB RAM, 512GB SSD.
{ {
config, config,
lib,
pkgs,
self, self,
... ...
}: { }: {

View file

@ -1,9 +1,4 @@
{ {lib, ...}: {
config,
lib,
pkgs,
...
}: {
home-manager.sharedModules = [ home-manager.sharedModules = [
{ {
gtk.font.size = lib.mkForce 14; gtk.font.size = lib.mkForce 14;

View file

@ -1,9 +1,9 @@
{ {
pkgs, imports = [
inputs, ./firefox
lib, ./nicotine-plus
config, ./steam
... ./podman
}: { ./virt-manager
imports = [./firefox ./nicotine-plus ./steam ./podman ./virt-manager]; ];
} }

View file

@ -1,7 +1,6 @@
{ {
config, config,
lib, lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.apps.firefox.enable { config = lib.mkIf config.ar.apps.firefox.enable {

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.apps.nicotine-plus.enable { config = lib.mkIf config.ar.apps.nicotine-plus.enable {

View file

@ -1,5 +1,4 @@
{ {
pkgs,
lib, lib,
config, config,
... ...

View file

@ -1,7 +1,6 @@
{ {
config, config,
lib, lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.apps.virt-manager.enable { config = lib.mkIf config.ar.apps.virt-manager.enable {

View file

@ -1,9 +1,4 @@
self: { self: {
config,
pkgs,
lib,
...
}: {
imports = [ imports = [
./apps ./apps
./desktop ./desktop

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.desktop.cinnamon.enable { config = lib.mkIf config.ar.desktop.cinnamon.enable {

View file

@ -1,6 +1,5 @@
{ {
config, config,
inputs,
lib, lib,
pkgs, pkgs,
... ...

View file

@ -20,16 +20,16 @@
''; '';
in { in {
config = lib.mkIf config.ar.desktop.gnome.enable { config = lib.mkIf config.ar.desktop.gnome.enable {
environment.systemPackages = with pkgs; environment.systemPackages =
[ [
gnomeExtensions.appindicator pkgs.gnomeExtensions.appindicator
gnomeExtensions.blur-my-shell pkgs.gnomeExtensions.blur-my-shell
gnomeExtensions.gsconnect pkgs.gnomeExtensions.gsconnect
gnomeExtensions.light-shell pkgs.gnomeExtensions.light-shell
gnomeExtensions.night-theme-switcher pkgs.gnomeExtensions.night-theme-switcher
gnomeExtensions.noannoyance-fork pkgs.gnomeExtensions.noannoyance-fork
gnomeExtensions.tailscale-status pkgs.gnomeExtensions.tailscale-status
gnomeExtensions.tiling-assistant pkgs.gnomeExtensions.tiling-assistant
] ]
++ [gnomeCsAdjuster]; ++ [gnomeCsAdjuster];

View file

@ -11,9 +11,9 @@
kwallet.enable = true; kwallet.enable = true;
}; };
services = { services.greetd = {
greetd = {
enable = true; enable = true;
settings = settings =
if config.ar.desktop.greetd.autologin != null if config.ar.desktop.greetd.autologin != null
then { then {
@ -32,5 +32,4 @@
}; };
}; };
}; };
};
} }

View file

@ -1,6 +1,5 @@
{ {
config, config,
inputs,
lib, lib,
pkgs, pkgs,
... ...

View file

@ -1,5 +1,4 @@
{ {
inputs,
pkgs, pkgs,
lib, lib,
config, config,

View file

@ -1,5 +1,4 @@
{ {
inputs,
pkgs, pkgs,
lib, lib,
config, config,

View file

@ -1,7 +1,6 @@
{ {
config, config,
lib, lib,
pkgs,
... ...
}: { }: {
options.ar = { options.ar = {

View file

@ -1,9 +1,4 @@
{ {
pkgs,
lib,
config,
...
}: {
imports = [ imports = [
./flatpak ./flatpak
]; ];

View file

@ -1,7 +1,7 @@
{ {
pkgs,
lib,
config, config,
lib,
pkgs,
... ...
}: { }: {
config = lib.mkIf config.ar.services.flatpak.enable { config = lib.mkIf config.ar.services.flatpak.enable {

View file

@ -1,8 +1,6 @@
{ {
config, config,
inputs,
lib, lib,
pkgs,
self, self,
... ...
}: { }: {

View file

@ -1,7 +1,6 @@
{ {
config, config,
lib, lib,
pkgs,
... ...
}: let }: let
cfg = config.ar.users.aly.syncthing; cfg = config.ar.users.aly.syncthing;

View file

@ -1,9 +1,4 @@
self: { self: {
config,
pkgs,
lib,
...
}: {
imports = [ imports = [
./aly ./aly
./dustin ./dustin

View file

@ -1,8 +1,6 @@
{ {
config, config,
inputs,
lib, lib,
pkgs,
self, self,
... ...
}: { }: {

View file

@ -1,7 +1,6 @@
{ {
config, config,
lib, lib,
pkgs,
... ...
}: { }: {
options.ar.users = let options.ar.users = let