From 64d5097f1ada44e7af4405266c8a5c905645f52d Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 13 Feb 2025 12:23:39 +1000 Subject: [PATCH 001/197] added nixd lsp to helix --- DEV_ENV | 65 ++++++++++++++++++++++++++++++++++ HELIX_LSP_GUIDE | 18 ++++++++++ homes/modules/editor/helix.nix | 65 +++++++++++++++++++--------------- hosts/lolcathost/default.nix | 5 +++ 4 files changed, 125 insertions(+), 28 deletions(-) create mode 100644 DEV_ENV create mode 100644 HELIX_LSP_GUIDE diff --git a/DEV_ENV b/DEV_ENV new file mode 100644 index 0000000..5d6ffca --- /dev/null +++ b/DEV_ENV @@ -0,0 +1,65 @@ +This file will document what features I believe I need +for NixOS to be a good development environment. + + +Issues I've encountered: +- [X] Audio not working +- [ ] Tesseract is a pain in the ass to setup on Nix +- [ ] ags no longer supports `-t` flag, so applauncher won't work, requires switching to Astral +- [ ] script to enable/disable passwordless sudo + +- [ ] Move Emile.Vault to new vault (I lost the password...) + +- [ ] Add a simple and ugly bar + +- [ ] Install powertop (funny name) for monitoring power usage by processes +- [ ] Try to make my battery life bettery + +- [ ] Apply for JetBrains student license +- [ ] JetBrains Rider and VSCodium for C# +2. Imperative development environment behind NixOS (declarative), +similar to python's virtualenv but for the entirety of my system. + +- [ ] Call my wishlist command "subspace (highway)" (Scott Pilgrim reference) + +- [ ] Create a GitHub profile readme like this persons: + https://github.com/yuyudhn +- [ ] Set a new GitHub profile picture (like github:@Vendicated) + artists credit: https://dotpict.net/users/1598051 +- [ ] Change GitHub location to /dev/zero, /dev/null, www, World Wide Web, etc +- [ ] Clean up my GitHub profile (only have things I'm proud of) + +- [X] Put a template website on my VPS +- [ ] Put a neoweb-esque webiste on my VPS +- [ ] Host a blog on my VPS + +- [ ] Clean laptop and PC, there's tons of unnecessary files and documents now +- [ ] Clean nixdots repo, start modularising it ^_^ +- [ ] Disable `allowUnfree` in nixdots everywhere, if a program needs it then they + can `mkForce` override it + +- [X] Add LSP for Nix in helix +- [ ] Make a way for me to put my laptop in a low power state, doing very specific actions like: + 1. disabling LSP use by default temporarily + +TODO: +- [X] make btop theming declarative +- [ ] Merge laptop and PC dotfiles repos + + +Cool Technologies: +- wishlist (by charmbracelet) +- Vaultwarden server + Keyguard client +- devbox + + + +Random Idea List: +- [ ] powertop is cool but it's outdated and ugly, make a prettier one with charmbracelet's tui library + and call it powerbtm lmao +- [ ] Blog Post: a modern alternative to the suckless philosphy, + why GNU keeps failing cause their programs are amazing but + aren't designed for humans. suckless programs are excellent + too when writing shell scripts, but they suck in dev environments. + The solution is to gamify our code and focus on aesthetics + and "ergonomics" (usability) like what CharmBracelet does diff --git a/HELIX_LSP_GUIDE b/HELIX_LSP_GUIDE new file mode 100644 index 0000000..e8bf5c5 --- /dev/null +++ b/HELIX_LSP_GUIDE @@ -0,0 +1,18 @@ +`gd` (goto definition when LSP is active) +`gy` (goto type definition) +`gr` (goto references) +`gi` (goto implementation) + +`k` (show documentation for item under cursor) +`s` (show picker for symbols in file) +`S` (show picker for symbols in workspace) +`d` (document diagnostics picker for file) +`D` (document diagnostics picker for workspace) +`r` (rename symbol) +`a` (apply code action, not show what that means though...) +`h` (select symbol references) + +`]d` (goto next diagnostic) +`[d` (goto previous diagnostic) +`]D` (goto last diagnostic in document) +`[D` (goto first diagnostic in document) diff --git a/homes/modules/editor/helix.nix b/homes/modules/editor/helix.nix index 4a66841..52c629a 100644 --- a/homes/modules/editor/helix.nix +++ b/homes/modules/editor/helix.nix @@ -1,13 +1,10 @@ -{ - config, - pkgs, - ... -}: { +{pkgs, ...}: { # read https://docs.helix-editor.com/editor.html programs.helix = { enable = true; settings = { theme = "dracula"; + editor = { line-number = "absolute"; popup-border = "all"; @@ -107,29 +104,41 @@ }; }; - languages.language = [ - { - name = "nix"; - indent = { - tab-width = 2; - unit = " "; + languages = { + language = [ + { + name = "nix"; + indent = { + tab-width = 2; + unit = " "; + }; + block-comment-tokens = { + start = "/*"; + end = "*/"; + }; + auto-format = true; + formatter.command = "${pkgs.alejandra}/bin/alejandra"; + language-servers = ["nixd"]; + } + { + name = "python"; + indent = { + tab-width = 4; + unit = " "; + }; + auto-format = false; # my python is beautiful ^_^ + rulers = [80]; + } + ]; + + language-server = { + # use nixd as default nix lsp (I haven't tried nil yet) + # NOTE: nixd will be supported by default after nix 24.07 + # SOURCE: https://github.com/nix-community/nixd/blob/main/nixd/docs/editor-setup.md#Helix + nixd = { + command = "${pkgs.nixd}/bin/nixd"; }; - block-comment-tokens = { - start = "/*"; - end = "*/"; - }; - auto-format = true; - formatter.command = "${pkgs.alejandra}/bin/alejandra"; - } - { - name = "python"; - indent = { - tab-width = 4; - unit = " "; - }; - auto-format = false; # my python is beautiful ^_^ - rulers = [80]; - } - ]; + }; + }; }; } diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 172aa0f..0167200 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -200,6 +200,11 @@ in { tldr btop + # TODO: once upgraded past Nix-24.07 this line won't be necessary (I think) + # helix will support nixd by default + # SOURCE: https://github.com/nix-community/nixd/blob/main/nixd/docs/editor-setup.md#Helix + nixd # lsp for nix + # Pretty necessary git brightnessctl From d178606f7dc77682857eed68121e64aa06069d14 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 21 Feb 2025 18:48:51 +1000 Subject: [PATCH 002/197] fixed ssh --- DEV_ENV | 2 + btop.conf.bak | 248 ++++++++++++++++++++++++++++++++ gitkraken_issue_solution | 10 ++ gitkraken_themes | 1 + homes/me/default.nix | 25 ++++ homes/modules/btop.nix | 79 ++++++++++ homes/modules/hypr/hyprland.nix | 2 + hosts/lolcathost/default.nix | 6 +- modules/hyprland/default.nix | 16 +-- 9 files changed, 380 insertions(+), 9 deletions(-) create mode 100644 btop.conf.bak create mode 100644 gitkraken_issue_solution create mode 100644 gitkraken_themes create mode 100644 homes/modules/btop.nix diff --git a/DEV_ENV b/DEV_ENV index 5d6ffca..32e6adf 100644 --- a/DEV_ENV +++ b/DEV_ENV @@ -42,6 +42,8 @@ similar to python's virtualenv but for the entirety of my system. - [ ] Make a way for me to put my laptop in a low power state, doing very specific actions like: 1. disabling LSP use by default temporarily +- [ ] Add https://github.com/levnikmyskin/hyprland-virtual-desktops + TODO: - [X] make btop theming declarative - [ ] Merge laptop and PC dotfiles repos diff --git a/btop.conf.bak b/btop.conf.bak new file mode 100644 index 0000000..bbd095e --- /dev/null +++ b/btop.conf.bak @@ -0,0 +1,248 @@ +#? Config file for btop v. 1.4.0 + +#* Name of a btop++/bpytop/bashtop formatted ".theme" file, "Default" and "TTY" for builtin themes. +#* Themes should be placed in "../share/btop/themes" relative to binary or "$HOME/.config/btop/themes" +color_theme = "Default" + +#* If the theme set background should be shown, set to False if you want terminal background transparency. +theme_background = True + +#* Sets if 24-bit truecolor should be used, will convert 24-bit colors to 256 color (6x6x6 color cube) if false. +truecolor = True + +#* Set to true to force tty mode regardless if a real tty has been detected or not. +#* Will force 16-color mode and TTY theme, set all graph symbols to "tty" and swap out other non tty friendly symbols. +force_tty = False + +#* Define presets for the layout of the boxes. Preset 0 is always all boxes shown with default settings. Max 9 presets. +#* Format: "box_name:P:G,box_name:P:G" P=(0 or 1) for alternate positions, G=graph symbol to use for box. +#* Use whitespace " " as separator between different presets. +#* Example: "cpu:0:default,mem:0:tty,proc:1:default cpu:0:braille,proc:0:tty" +presets = "cpu:1:default,proc:0:default cpu:0:default,mem:0:default,net:0:default cpu:0:block,net:0:tty" + +#* Set to True to enable "h,j,k,l,g,G" keys for directional control in lists. +#* Conflicting keys for h:"help" and k:"kill" is accessible while holding shift. +vim_keys = False + +#* Rounded corners on boxes, is ignored if TTY mode is ON. +rounded_corners = True + +#* Default symbols to use for graph creation, "braille", "block" or "tty". +#* "braille" offers the highest resolution but might not be included in all fonts. +#* "block" has half the resolution of braille but uses more common characters. +#* "tty" uses only 3 different symbols but will work with most fonts and should work in a real TTY. +#* Note that "tty" only has half the horizontal resolution of the other two, so will show a shorter historical view. +graph_symbol = "braille" + +# Graph symbol to use for graphs in cpu box, "default", "braille", "block" or "tty". +graph_symbol_cpu = "default" + +# Graph symbol to use for graphs in gpu box, "default", "braille", "block" or "tty". +graph_symbol_gpu = "default" + +# Graph symbol to use for graphs in cpu box, "default", "braille", "block" or "tty". +graph_symbol_mem = "default" + +# Graph symbol to use for graphs in cpu box, "default", "braille", "block" or "tty". +graph_symbol_net = "default" + +# Graph symbol to use for graphs in cpu box, "default", "braille", "block" or "tty". +graph_symbol_proc = "default" + +#* Manually set which boxes to show. Available values are "cpu mem net proc" and "gpu0" through "gpu5", separate values with whitespace. +shown_boxes = "cpu mem net proc" + +#* Update time in milliseconds, recommended 2000 ms or above for better sample times for graphs. +update_ms = 2000 + +#* Processes sorting, "pid" "program" "arguments" "threads" "user" "memory" "cpu lazy" "cpu direct", +#* "cpu lazy" sorts top process over time (easier to follow), "cpu direct" updates top process directly. +proc_sorting = "memory" + +#* Reverse sorting order, True or False. +proc_reversed = False + +#* Show processes as a tree. +proc_tree = False + +#* Use the cpu graph colors in the process list. +proc_colors = True + +#* Use a darkening gradient in the process list. +proc_gradient = True + +#* If process cpu usage should be of the core it's running on or usage of the total available cpu power. +proc_per_core = False + +#* Show process memory as bytes instead of percent. +proc_mem_bytes = True + +#* Show cpu graph for each process. +proc_cpu_graphs = True + +#* Use /proc/[pid]/smaps for memory information in the process info box (very slow but more accurate) +proc_info_smaps = False + +#* Show proc box on left side of screen instead of right. +proc_left = False + +#* (Linux) Filter processes tied to the Linux kernel(similar behavior to htop). +proc_filter_kernel = False + +#* In tree-view, always accumulate child process resources in the parent process. +proc_aggregate = False + +#* Sets the CPU stat shown in upper half of the CPU graph, "total" is always available. +#* Select from a list of detected attributes from the options menu. +cpu_graph_upper = "Auto" + +#* Sets the CPU stat shown in lower half of the CPU graph, "total" is always available. +#* Select from a list of detected attributes from the options menu. +cpu_graph_lower = "Auto" + +#* If gpu info should be shown in the cpu box. Available values = "Auto", "On" and "Off". +show_gpu_info = "Auto" + +#* Toggles if the lower CPU graph should be inverted. +cpu_invert_lower = True + +#* Set to True to completely disable the lower CPU graph. +cpu_single_graph = False + +#* Show cpu box at bottom of screen instead of top. +cpu_bottom = False + +#* Shows the system uptime in the CPU box. +show_uptime = True + +#* Show cpu temperature. +check_temp = True + +#* Which sensor to use for cpu temperature, use options menu to select from list of available sensors. +cpu_sensor = "Auto" + +#* Show temperatures for cpu cores also if check_temp is True and sensors has been found. +show_coretemp = True + +#* Set a custom mapping between core and coretemp, can be needed on certain cpus to get correct temperature for correct core. +#* Use lm-sensors or similar to see which cores are reporting temperatures on your machine. +#* Format "x:y" x=core with wrong temp, y=core with correct temp, use space as separator between multiple entries. +#* Example: "4:0 5:1 6:3" +cpu_core_map = "" + +#* Which temperature scale to use, available values: "celsius", "fahrenheit", "kelvin" and "rankine". +temp_scale = "celsius" + +#* Use base 10 for bits/bytes sizes, KB = 1000 instead of KiB = 1024. +base_10_sizes = False + +#* Show CPU frequency. +show_cpu_freq = True + +#* Draw a clock at top of screen, formatting according to strftime, empty string to disable. +#* Special formatting: /host = hostname | /user = username | /uptime = system uptime +clock_format = "%X" + +#* Update main ui in background when menus are showing, set this to false if the menus is flickering too much for comfort. +background_update = True + +#* Custom cpu model name, empty string to disable. +custom_cpu_name = "" + +#* Optional filter for shown disks, should be full path of a mountpoint, separate multiple values with whitespace " ". +#* Begin line with "exclude=" to change to exclude filter, otherwise defaults to "most include" filter. Example: disks_filter="exclude=/boot /home/user". +disks_filter = "" + +#* Show graphs instead of meters for memory values. +mem_graphs = True + +#* Show mem box below net box instead of above. +mem_below_net = False + +#* Count ZFS ARC in cached and available memory. +zfs_arc_cached = True + +#* If swap memory should be shown in memory box. +show_swap = True + +#* Show swap as a disk, ignores show_swap value above, inserts itself after first disk. +swap_disk = True + +#* If mem box should be split to also show disks info. +show_disks = True + +#* Filter out non physical disks. Set this to False to include network disks, RAM disks and similar. +only_physical = True + +#* Read disks list from /etc/fstab. This also disables only_physical. +use_fstab = True + +#* Setting this to True will hide all datasets, and only show ZFS pools. (IO stats will be calculated per-pool) +zfs_hide_datasets = False + +#* Set to true to show available disk space for privileged users. +disk_free_priv = False + +#* Toggles if io activity % (disk busy time) should be shown in regular disk usage view. +show_io_stat = True + +#* Toggles io mode for disks, showing big graphs for disk read/write speeds. +io_mode = False + +#* Set to True to show combined read/write io graphs in io mode. +io_graph_combined = False + +#* Set the top speed for the io graphs in MiB/s (100 by default), use format "mountpoint:speed" separate disks with whitespace " ". +#* Example: "/mnt/media:100 /:20 /boot:1". +io_graph_speeds = "" + +#* Set fixed values for network graphs in Mebibits. Is only used if net_auto is also set to False. +net_download = 100 + +net_upload = 100 + +#* Use network graphs auto rescaling mode, ignores any values set above and rescales down to 10 Kibibytes at the lowest. +net_auto = True + +#* Sync the auto scaling for download and upload to whichever currently has the highest scale. +net_sync = True + +#* Starts with the Network Interface specified here. +net_iface = "" + +#* Show battery stats in top right if battery is present. +show_battery = True + +#* Which battery to use if multiple are present. "Auto" for auto detection. +selected_battery = "Auto" + +#* Show power stats of battery next to charge indicator. +show_battery_watts = True + +#* Set loglevel for "~/.config/btop/btop.log" levels are: "ERROR" "WARNING" "INFO" "DEBUG". +#* The level set includes all lower levels, i.e. "DEBUG" will show all logging info. +log_level = "WARNING" + +#* Measure PCIe throughput on NVIDIA cards, may impact performance on certain cards. +nvml_measure_pcie_speeds = True + +#* Horizontally mirror the GPU graph. +gpu_mirror_graph = True + +#* Custom gpu0 model name, empty string to disable. +custom_gpu_name0 = "" + +#* Custom gpu1 model name, empty string to disable. +custom_gpu_name1 = "" + +#* Custom gpu2 model name, empty string to disable. +custom_gpu_name2 = "" + +#* Custom gpu3 model name, empty string to disable. +custom_gpu_name3 = "" + +#* Custom gpu4 model name, empty string to disable. +custom_gpu_name4 = "" + +#* Custom gpu5 model name, empty string to disable. +custom_gpu_name5 = "" diff --git a/gitkraken_issue_solution b/gitkraken_issue_solution new file mode 100644 index 0000000..4d8b58b --- /dev/null +++ b/gitkraken_issue_solution @@ -0,0 +1,10 @@ +If gitkraken won't work make sure: + +The ssh-agent is running and "$SSH_AUTH_SOCK" equals "$XDG_RUNTIME_DIR/ssh-agent" +(this is the known ssh-agent issue I've already solved). + +Next make sure whatever you're cloning/etc from is in your ~/.ssh/known_hosts file +(if using ssh). Gitkraken may fail to do this automatically. ie for gitlab run: +```sh +ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts +``` diff --git a/gitkraken_themes b/gitkraken_themes new file mode 100644 index 0000000..e7afa74 --- /dev/null +++ b/gitkraken_themes @@ -0,0 +1 @@ +https://jonbunator.github.io/gitkraken-custom-themes/#dracula---source diff --git a/homes/me/default.nix b/homes/me/default.nix index 19d85d8..6be5fd4 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -16,6 +16,7 @@ ../modules/fish.nix ../modules/editor/helix.nix + ../modules/btop.nix ../modules/rio.nix ../modules/firefox.nix ../modules/nixcord.nix @@ -89,6 +90,25 @@ # these are both required for home-manager to work home-manager.enable = true; + # set ssh profiles + # (all we need is hyrule, everything else is through wishlist) + # NOTE: (IMPORTANT) this DOES NOT start the ssh-agent + # for that you need to use `services.ssh-agent-enable` + ssh = { + enable = true; + forwardAgent = true; + addKeysToAgent = "yes"; # always add keys to ssh-agent + + matchBlocks = { + hyrule = { + hostname = "imbored.dev"; + user = "ae"; + port = 22; + identityFile = "/home/me/.ssh/id_hyrule"; + }; + }; + }; + ags = { enable = true; configDir = ./ags; @@ -131,6 +151,11 @@ */ }; + # enable OpenSSH private key agent + services.ssh-agent.enable = true; + # the ssh-agent won't set this for itself... + systemd.user.sessionVariables.SSH_AUTH_SOCK = "$XDG_RUNTIME_DIR/ssh-agent"; + # ----- SERVICES ----- # Nicely reload system units when changing configs systemd.user.startServices = "sd-switch"; diff --git a/homes/modules/btop.nix b/homes/modules/btop.nix new file mode 100644 index 0000000..119da4f --- /dev/null +++ b/homes/modules/btop.nix @@ -0,0 +1,79 @@ +{config, ...}: { + programs.btop = { + enable = true; + + settings = { + # Theming + color_theme = "dracula"; + theme_background = true; + truecolor = true; + force_tty = false; + vim_keys = false; # allow vim keybindings + # Units + clock_format = "%I:%M %p, %b %d"; + temp_scale = "celsius"; + base_10_sizes = false; # use KB or KiB + + # UI + background_update = true; + update_ms = 2000; + rounded_corners = false; + graph_symbol = "braille"; # braille/block/tty + graph_symbol_cpu = "default"; + graph_symbol_mem = "default"; + graph_symbol_net = "default"; + graph_symbol_proc = "default"; + + # Processes Window + proc_left = true; # show on left side of window + proc_colors = true; + proc_gradient = true; + proc_per_core = false; # false: % of ALL cores + proc_mem_bytes = false; # show mem usage as % + proc_sorting = "cpu lazy"; + proc_filter_kernel = false; # hide kernel child processes + proc_tree = false; + + # CPU Window + cpu_bottom = false; # display at bottom of window + show_uptime = true; + show_cpu_freq = true; + check_temp = true; # show cpu temp + show_coretemp = true; # show temp per core + cpu_graph_upper = "total"; # upper graph shows total CPU usage + cpu_graph_lower = "user"; # lower graph shows user's CPU usage + cpu_invert_lower = true; + cpu_single_graph = false; # disable lower graph + show_gpu_info = "Off"; # Auto/On/Off + gpu_mirror_graph = false; # horizontally mirror gpu graph + + # Memory Window + mem_below_net = false; # show below net window + mem_graphs = true; # show graphs not meters + show_swap = true; # show swap memory usage + # Disks Subwindow + show_disks = true; # split mem box to show disk info + swap_disk = true; # show swap memory as disk + show_io_stat = true; + io_graph_combined = false; # combine read/write stats + io_mode = true; # show io stat as graph + use_fstab = true; # read disk list from /etc/fstab + only_physical = false; # ignore non-physical disks + + # Network Window + net_iface = ""; # default network interface to monitor + net_auto = true; # overrides net_download/net_upload (below) + net_sync = false; # sync download/upload graph scales + net_download = 100; # max download speed graphed + net_upload = 100; # max upload speed graphed + + # Battery + show_battery = true; + selected_battery = "Auto"; + show_battery_watts = true; + + # Other + log_level = "WARNING"; # ERROR/WARNING/INFO/DEBUG + }; + }; +} diff --git a/homes/modules/hypr/hyprland.nix b/homes/modules/hypr/hyprland.nix index e69de29..40a1d99 100644 --- a/homes/modules/hypr/hyprland.nix +++ b/homes/modules/hypr/hyprland.nix @@ -0,0 +1,2 @@ +# NOTE: hyprland must be enabled in BOTH your host config (for running hyprland) +# and your home-manager config (for managing hyprland's config files) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 0167200..9b1e1c2 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -132,6 +132,9 @@ in { # for graphical applications flatpak gnome-software + + jetbrains.rider + gitkraken ]; }; @@ -181,7 +184,8 @@ in { easyeffects ani-cli wl-clipboard # clipboard for wayland - kcalc # TEMP: (FOR TESTING) + + pavucontrol (callPackage ./sddm-theme-corners.nix {}).sddm-theme-corners # dependencies for my sddm theme: diff --git a/modules/hyprland/default.nix b/modules/hyprland/default.nix index 71ee559..530f075 100755 --- a/modules/hyprland/default.nix +++ b/modules/hyprland/default.nix @@ -1,12 +1,12 @@ -{ +# NOTE: hyprland must be enabled in BOTH your host config (for running hyprland) +# and your home-manager config (for managing hyprland's config files) +{ pkgs, inputs, config, - lib, - ... -}: - -{ + lib, + ... +}: { options.hyprland = { enable = lib.mkEnableOption "Hyprland"; }; @@ -17,7 +17,7 @@ #package = inputs.hyprland.packages.${pkgs.system}.hyprland; xwayland.enable = true; }; - + xdg.portal = { enable = true; extraPortals = with pkgs; [ @@ -26,5 +26,5 @@ }; # TODO: finish this (I didn't like the dotfiles I was getting inspo from and stopped) - }; + }; } From 5aa769343fb2a01ed6d7ebe58fbc963641c469b9 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 21 Feb 2025 19:38:42 +1000 Subject: [PATCH 003/197] pre-merge preparation --- .gitignore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitignore b/.gitignore index e69de29..e32e851 100755 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1,2 @@ +ISSUES/ +secrets/ From 61b4615aee1b82932369dd0092afd35884cb5617 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 21 Feb 2025 21:49:44 +1000 Subject: [PATCH 004/197] light cleaning --- HELIX_LSP_GUIDE | 18 --- btop.conf.bak | 248 ----------------------------- DEVDOC.md => docs/DEVDOC.md | 0 DEV_ENV => docs/DEV_ENV.md | 12 +- TODO => docs/TODO.md | 0 TODO_UI => docs/TODO_UI.md | 0 INSPIRATION => docs/inspiration.md | 0 gitkraken_issue_solution | 10 -- gitkraken_themes | 1 - homes/modules/btop.nix | 2 +- hosts/lolcathost/default.nix | 1 + hosts/myputer/default.nix | 1 + result | 1 - 13 files changed, 9 insertions(+), 285 deletions(-) delete mode 100644 HELIX_LSP_GUIDE delete mode 100644 btop.conf.bak rename DEVDOC.md => docs/DEVDOC.md (100%) rename DEV_ENV => docs/DEV_ENV.md (87%) rename TODO => docs/TODO.md (100%) rename TODO_UI => docs/TODO_UI.md (100%) rename INSPIRATION => docs/inspiration.md (100%) delete mode 100644 gitkraken_issue_solution delete mode 100644 gitkraken_themes delete mode 120000 result diff --git a/HELIX_LSP_GUIDE b/HELIX_LSP_GUIDE deleted file mode 100644 index e8bf5c5..0000000 --- a/HELIX_LSP_GUIDE +++ /dev/null @@ -1,18 +0,0 @@ -`gd` (goto definition when LSP is active) -`gy` (goto type definition) -`gr` (goto references) -`gi` (goto implementation) - -`k` (show documentation for item under cursor) -`s` (show picker for symbols in file) -`S` (show picker for symbols in workspace) -`d` (document diagnostics picker for file) -`D` (document diagnostics picker for workspace) -`r` (rename symbol) -`a` (apply code action, not show what that means though...) -`h` (select symbol references) - -`]d` (goto next diagnostic) -`[d` (goto previous diagnostic) -`]D` (goto last diagnostic in document) -`[D` (goto first diagnostic in document) diff --git a/btop.conf.bak b/btop.conf.bak deleted file mode 100644 index bbd095e..0000000 --- a/btop.conf.bak +++ /dev/null @@ -1,248 +0,0 @@ -#? Config file for btop v. 1.4.0 - -#* Name of a btop++/bpytop/bashtop formatted ".theme" file, "Default" and "TTY" for builtin themes. -#* Themes should be placed in "../share/btop/themes" relative to binary or "$HOME/.config/btop/themes" -color_theme = "Default" - -#* If the theme set background should be shown, set to False if you want terminal background transparency. -theme_background = True - -#* Sets if 24-bit truecolor should be used, will convert 24-bit colors to 256 color (6x6x6 color cube) if false. -truecolor = True - -#* Set to true to force tty mode regardless if a real tty has been detected or not. -#* Will force 16-color mode and TTY theme, set all graph symbols to "tty" and swap out other non tty friendly symbols. -force_tty = False - -#* Define presets for the layout of the boxes. Preset 0 is always all boxes shown with default settings. Max 9 presets. -#* Format: "box_name:P:G,box_name:P:G" P=(0 or 1) for alternate positions, G=graph symbol to use for box. -#* Use whitespace " " as separator between different presets. -#* Example: "cpu:0:default,mem:0:tty,proc:1:default cpu:0:braille,proc:0:tty" -presets = "cpu:1:default,proc:0:default cpu:0:default,mem:0:default,net:0:default cpu:0:block,net:0:tty" - -#* Set to True to enable "h,j,k,l,g,G" keys for directional control in lists. -#* Conflicting keys for h:"help" and k:"kill" is accessible while holding shift. -vim_keys = False - -#* Rounded corners on boxes, is ignored if TTY mode is ON. -rounded_corners = True - -#* Default symbols to use for graph creation, "braille", "block" or "tty". -#* "braille" offers the highest resolution but might not be included in all fonts. -#* "block" has half the resolution of braille but uses more common characters. -#* "tty" uses only 3 different symbols but will work with most fonts and should work in a real TTY. -#* Note that "tty" only has half the horizontal resolution of the other two, so will show a shorter historical view. -graph_symbol = "braille" - -# Graph symbol to use for graphs in cpu box, "default", "braille", "block" or "tty". -graph_symbol_cpu = "default" - -# Graph symbol to use for graphs in gpu box, "default", "braille", "block" or "tty". -graph_symbol_gpu = "default" - -# Graph symbol to use for graphs in cpu box, "default", "braille", "block" or "tty". -graph_symbol_mem = "default" - -# Graph symbol to use for graphs in cpu box, "default", "braille", "block" or "tty". -graph_symbol_net = "default" - -# Graph symbol to use for graphs in cpu box, "default", "braille", "block" or "tty". -graph_symbol_proc = "default" - -#* Manually set which boxes to show. Available values are "cpu mem net proc" and "gpu0" through "gpu5", separate values with whitespace. -shown_boxes = "cpu mem net proc" - -#* Update time in milliseconds, recommended 2000 ms or above for better sample times for graphs. -update_ms = 2000 - -#* Processes sorting, "pid" "program" "arguments" "threads" "user" "memory" "cpu lazy" "cpu direct", -#* "cpu lazy" sorts top process over time (easier to follow), "cpu direct" updates top process directly. -proc_sorting = "memory" - -#* Reverse sorting order, True or False. -proc_reversed = False - -#* Show processes as a tree. -proc_tree = False - -#* Use the cpu graph colors in the process list. -proc_colors = True - -#* Use a darkening gradient in the process list. -proc_gradient = True - -#* If process cpu usage should be of the core it's running on or usage of the total available cpu power. -proc_per_core = False - -#* Show process memory as bytes instead of percent. -proc_mem_bytes = True - -#* Show cpu graph for each process. -proc_cpu_graphs = True - -#* Use /proc/[pid]/smaps for memory information in the process info box (very slow but more accurate) -proc_info_smaps = False - -#* Show proc box on left side of screen instead of right. -proc_left = False - -#* (Linux) Filter processes tied to the Linux kernel(similar behavior to htop). -proc_filter_kernel = False - -#* In tree-view, always accumulate child process resources in the parent process. -proc_aggregate = False - -#* Sets the CPU stat shown in upper half of the CPU graph, "total" is always available. -#* Select from a list of detected attributes from the options menu. -cpu_graph_upper = "Auto" - -#* Sets the CPU stat shown in lower half of the CPU graph, "total" is always available. -#* Select from a list of detected attributes from the options menu. -cpu_graph_lower = "Auto" - -#* If gpu info should be shown in the cpu box. Available values = "Auto", "On" and "Off". -show_gpu_info = "Auto" - -#* Toggles if the lower CPU graph should be inverted. -cpu_invert_lower = True - -#* Set to True to completely disable the lower CPU graph. -cpu_single_graph = False - -#* Show cpu box at bottom of screen instead of top. -cpu_bottom = False - -#* Shows the system uptime in the CPU box. -show_uptime = True - -#* Show cpu temperature. -check_temp = True - -#* Which sensor to use for cpu temperature, use options menu to select from list of available sensors. -cpu_sensor = "Auto" - -#* Show temperatures for cpu cores also if check_temp is True and sensors has been found. -show_coretemp = True - -#* Set a custom mapping between core and coretemp, can be needed on certain cpus to get correct temperature for correct core. -#* Use lm-sensors or similar to see which cores are reporting temperatures on your machine. -#* Format "x:y" x=core with wrong temp, y=core with correct temp, use space as separator between multiple entries. -#* Example: "4:0 5:1 6:3" -cpu_core_map = "" - -#* Which temperature scale to use, available values: "celsius", "fahrenheit", "kelvin" and "rankine". -temp_scale = "celsius" - -#* Use base 10 for bits/bytes sizes, KB = 1000 instead of KiB = 1024. -base_10_sizes = False - -#* Show CPU frequency. -show_cpu_freq = True - -#* Draw a clock at top of screen, formatting according to strftime, empty string to disable. -#* Special formatting: /host = hostname | /user = username | /uptime = system uptime -clock_format = "%X" - -#* Update main ui in background when menus are showing, set this to false if the menus is flickering too much for comfort. -background_update = True - -#* Custom cpu model name, empty string to disable. -custom_cpu_name = "" - -#* Optional filter for shown disks, should be full path of a mountpoint, separate multiple values with whitespace " ". -#* Begin line with "exclude=" to change to exclude filter, otherwise defaults to "most include" filter. Example: disks_filter="exclude=/boot /home/user". -disks_filter = "" - -#* Show graphs instead of meters for memory values. -mem_graphs = True - -#* Show mem box below net box instead of above. -mem_below_net = False - -#* Count ZFS ARC in cached and available memory. -zfs_arc_cached = True - -#* If swap memory should be shown in memory box. -show_swap = True - -#* Show swap as a disk, ignores show_swap value above, inserts itself after first disk. -swap_disk = True - -#* If mem box should be split to also show disks info. -show_disks = True - -#* Filter out non physical disks. Set this to False to include network disks, RAM disks and similar. -only_physical = True - -#* Read disks list from /etc/fstab. This also disables only_physical. -use_fstab = True - -#* Setting this to True will hide all datasets, and only show ZFS pools. (IO stats will be calculated per-pool) -zfs_hide_datasets = False - -#* Set to true to show available disk space for privileged users. -disk_free_priv = False - -#* Toggles if io activity % (disk busy time) should be shown in regular disk usage view. -show_io_stat = True - -#* Toggles io mode for disks, showing big graphs for disk read/write speeds. -io_mode = False - -#* Set to True to show combined read/write io graphs in io mode. -io_graph_combined = False - -#* Set the top speed for the io graphs in MiB/s (100 by default), use format "mountpoint:speed" separate disks with whitespace " ". -#* Example: "/mnt/media:100 /:20 /boot:1". -io_graph_speeds = "" - -#* Set fixed values for network graphs in Mebibits. Is only used if net_auto is also set to False. -net_download = 100 - -net_upload = 100 - -#* Use network graphs auto rescaling mode, ignores any values set above and rescales down to 10 Kibibytes at the lowest. -net_auto = True - -#* Sync the auto scaling for download and upload to whichever currently has the highest scale. -net_sync = True - -#* Starts with the Network Interface specified here. -net_iface = "" - -#* Show battery stats in top right if battery is present. -show_battery = True - -#* Which battery to use if multiple are present. "Auto" for auto detection. -selected_battery = "Auto" - -#* Show power stats of battery next to charge indicator. -show_battery_watts = True - -#* Set loglevel for "~/.config/btop/btop.log" levels are: "ERROR" "WARNING" "INFO" "DEBUG". -#* The level set includes all lower levels, i.e. "DEBUG" will show all logging info. -log_level = "WARNING" - -#* Measure PCIe throughput on NVIDIA cards, may impact performance on certain cards. -nvml_measure_pcie_speeds = True - -#* Horizontally mirror the GPU graph. -gpu_mirror_graph = True - -#* Custom gpu0 model name, empty string to disable. -custom_gpu_name0 = "" - -#* Custom gpu1 model name, empty string to disable. -custom_gpu_name1 = "" - -#* Custom gpu2 model name, empty string to disable. -custom_gpu_name2 = "" - -#* Custom gpu3 model name, empty string to disable. -custom_gpu_name3 = "" - -#* Custom gpu4 model name, empty string to disable. -custom_gpu_name4 = "" - -#* Custom gpu5 model name, empty string to disable. -custom_gpu_name5 = "" diff --git a/DEVDOC.md b/docs/DEVDOC.md similarity index 100% rename from DEVDOC.md rename to docs/DEVDOC.md diff --git a/DEV_ENV b/docs/DEV_ENV.md similarity index 87% rename from DEV_ENV rename to docs/DEV_ENV.md index 32e6adf..65e8bb0 100644 --- a/DEV_ENV +++ b/docs/DEV_ENV.md @@ -4,13 +4,13 @@ for NixOS to be a good development environment. Issues I've encountered: - [X] Audio not working -- [ ] Tesseract is a pain in the ass to setup on Nix +- [X] Tesseract is a pain in the ass to setup on Nix - [ ] ags no longer supports `-t` flag, so applauncher won't work, requires switching to Astral - [ ] script to enable/disable passwordless sudo -- [ ] Move Emile.Vault to new vault (I lost the password...) +- [X] Move Emile.Vault to new vault (I lost the password...) -- [ ] Add a simple and ugly bar +- [X] Add a simple and ugly bar - [ ] Install powertop (funny name) for monitoring power usage by processes - [ ] Try to make my battery life bettery @@ -20,7 +20,7 @@ Issues I've encountered: 2. Imperative development environment behind NixOS (declarative), similar to python's virtualenv but for the entirety of my system. -- [ ] Call my wishlist command "subspace (highway)" (Scott Pilgrim reference) +- [X] Call my wishlist command "subspace (highway)" (Scott Pilgrim reference) - [ ] Create a GitHub profile readme like this persons: https://github.com/yuyudhn @@ -46,8 +46,8 @@ similar to python's virtualenv but for the entirety of my system. TODO: - [X] make btop theming declarative -- [ ] Merge laptop and PC dotfiles repos - +- [X] Merge laptop and PC dotfiles repos +- [ ] declaratively install themes for gitkraken using home-manager Cool Technologies: - wishlist (by charmbracelet) diff --git a/TODO b/docs/TODO.md similarity index 100% rename from TODO rename to docs/TODO.md diff --git a/TODO_UI b/docs/TODO_UI.md similarity index 100% rename from TODO_UI rename to docs/TODO_UI.md diff --git a/INSPIRATION b/docs/inspiration.md similarity index 100% rename from INSPIRATION rename to docs/inspiration.md diff --git a/gitkraken_issue_solution b/gitkraken_issue_solution deleted file mode 100644 index 4d8b58b..0000000 --- a/gitkraken_issue_solution +++ /dev/null @@ -1,10 +0,0 @@ -If gitkraken won't work make sure: - -The ssh-agent is running and "$SSH_AUTH_SOCK" equals "$XDG_RUNTIME_DIR/ssh-agent" -(this is the known ssh-agent issue I've already solved). - -Next make sure whatever you're cloning/etc from is in your ~/.ssh/known_hosts file -(if using ssh). Gitkraken may fail to do this automatically. ie for gitlab run: -```sh -ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts -``` diff --git a/gitkraken_themes b/gitkraken_themes deleted file mode 100644 index e7afa74..0000000 --- a/gitkraken_themes +++ /dev/null @@ -1 +0,0 @@ -https://jonbunator.github.io/gitkraken-custom-themes/#dracula---source diff --git a/homes/modules/btop.nix b/homes/modules/btop.nix index 119da4f..918eb25 100644 --- a/homes/modules/btop.nix +++ b/homes/modules/btop.nix @@ -18,7 +18,7 @@ background_update = true; update_ms = 2000; rounded_corners = false; - graph_symbol = "braille"; # braille/block/tty + graph_symbol = "block"; # braille/block/tty graph_symbol_cpu = "default"; graph_symbol_mem = "default"; graph_symbol_net = "default"; diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 42defdb..2c4d794 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -204,6 +204,7 @@ in { # Pretty necessary git + git-filter-repo brightnessctl acpi vim diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 73d2eb1..3f5afed 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -208,6 +208,7 @@ in { # Pretty necessary git + git-filter-repo brightnessctl acpi vim diff --git a/result b/result deleted file mode 120000 index fab173e..0000000 --- a/result +++ /dev/null @@ -1 +0,0 @@ -/nix/store/clc95m2c889yns3n8c71vfgb1q2qd419-nixos-system-myputer-24.11.20250212.0ff09db \ No newline at end of file From 9636eab7f612d67b2f5a68ddf02e6622d13d1180 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 24 Feb 2025 13:18:46 +1000 Subject: [PATCH 005/197] added hyprpanel, fixed colmena for laptop, and minor ssh config changes --- docs/inspiration.md | 4 ++ flake.lock | 6 +-- flake.nix | 46 +++++----------------- homes/me/default.nix | 75 ++++++++++++++++++++++++++++++++++++ hosts/lolcathost/default.nix | 57 ++++++++++++++++++--------- hosts/myputer/default.nix | 4 +- 6 files changed, 132 insertions(+), 60 deletions(-) diff --git a/docs/inspiration.md b/docs/inspiration.md index 2c5adf0..fdb73ab 100755 --- a/docs/inspiration.md +++ b/docs/inspiration.md @@ -6,3 +6,7 @@ Gorgeous Very nice https://github.com/linuxmobile/hyprland-dots + + +I love their hyprpanel! + https://www.reddit.com/r/unixporn/comments/1ha3mjw/hyprlandnixos_is_the_pretty_ucking_solid_i_love/ diff --git a/flake.lock b/flake.lock index 4e31fa3..9e28c75 100755 --- a/flake.lock +++ b/flake.lock @@ -560,11 +560,11 @@ }, "nixpkgs_6": { "locked": { - "lastModified": 1729880355, - "narHash": "sha256-RP+OQ6koQQLX5nw0NmcDrzvGL8HDLnyXt/jHhL1jwjM=", + "lastModified": 1739866667, + "narHash": "sha256-EO1ygNKZlsAC9avfcwHkKGMsmipUk1Uc0TbrEZpkn64=", "owner": "nixos", "repo": "nixpkgs", - "rev": "18536bf04cd71abd345f9579158841376fdd0c5a", + "rev": "73cf49b8ad837ade2de76f87eb53fc85ed5d4680", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 861295a..e31b8ac 100755 --- a/flake.nix +++ b/flake.nix @@ -4,7 +4,6 @@ inputs = { # nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05"; nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11"; - #nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; #home-manager = { # url = "github:nix-community/home-manager"; @@ -23,6 +22,11 @@ # is this necessary? (aren't I enabling it in `configuration.nix` anyways?) hyprland.url = "github:hyprwm/Hyprland"; + hyprpanel = { + url = "github:Jas-SinghFSU/HyprPanel"; + #inputs.nixpkgs.follows = "nixpkgs"; + }; + swww.url = "github:LGFae/swww"; # TODO: declarative flatpak management @@ -30,14 +34,8 @@ ags.url = "github:Aylur/ags"; - hyprpanel.url = "github:Jas-SinghFSU/HyprPanel"; - # colmena.url = "github:zhaofengli/colmena"; colmena.url = "github:zhaofengli/colmena/?rev=47b6414d800c8471e98ca072bc0835345741a56a"; - # alternative to colmena (currently in testing) - #deploy-rs.url = "github:serokell/deploy-rs"; - - #wishlist.url = "path:/home/me/nixdots/flakes/wishlist"; }; outputs = { @@ -47,18 +45,20 @@ hyprland, grub2-themes, nixcord, + hyprpanel, colmena, - #deploy-rs, ... } @ inputs: let system = "x86_64-linux"; pkgs = import nixpkgs { inherit system; - config = { allowUnfree = true; }; + overlays = [ + inputs.hyprpanel.overlay + ]; }; # TODO: come back to this its really cool @@ -93,36 +93,8 @@ grub2-themes.nixosModules.default ]; }; - - # meine vps - # hyrule = nixpkgs.lib.nixosSystem { - # # manually set system architecture since - # # this is for a remote deployment - # system = "x86_64-linux"; - # specialargs = {inherit inputs pkgs;}; - # - # modules = [ - # ./hosts/hyrule - # ]; - # }; }; - # remote deployment with deploy-rs - # deploy.nodes.hyrule = { - # hostname = "imbored.dev"; - # # create a primary profile called "system" - # profiles.system = { - # user = "root"; # user to deploy to - # path = deploy-rs.lib.x86_64-linux.activate.nixos self.nixosConfigurations.hyrule; - # - # # ssh configuration for reaching the server - # sshUser = "ae"; - # #interactiveSudo = true; # TODO: use this and revoke passwordless sudo for ae - # sshOpts = ["-i" "/home/me/.ssh/id_hyrule"]; - # remoteBuild = false; # build locally then deploy to remote host - # }; - # }; - # remote deployment to my servers!! colmenaHive = colmena.lib.makeHive { meta = { diff --git a/homes/me/default.nix b/homes/me/default.nix index 80d2878..2636693 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -11,6 +11,7 @@ }; imports = [ + #inputs.hyprpanel.packages.homeManagerModules.hyprpanel ../modules/git.nix ../modules/bat.nix ../modules/fish.nix @@ -115,6 +116,9 @@ user = "ae"; port = 22; identityFile = "~/.ssh/id_hyrule"; + setEnv = { + TERM = "linux"; + }; }; subspace = { hostname = "imbored.dev"; @@ -122,9 +126,80 @@ port = 22; identityFile = "~/.ssh/id_subspace"; }; + youcue = { + hostname = "moss.labs.eait.uq.edu.au"; + user = "s4740056"; + port = 22; + identityFile = "~/.ssh/id_youcue"; + setEnv = { + TERM = "xterm-256color"; + }; + }; + deadlyserver = { + hostname = "deadlyserver.com"; + user = "emile"; + port = 29843; + identityFile = "~/.ssh/id_deadlyserver"; + setEnv = { + TERM = "xterm-256color"; + }; + }; }; }; + /* + hyprpanel = { + enable = true; + # automatically restart when config changes + systemd.enable = true; # TODO: change to false + # add `exec-once hyprpanel` to hyprland config + hyprland.enable = true; + + # fix the overwrite issue with hyprpanel on NixOS + overwrite.enable = true; + + # import a theme from './themes/*.json' + # theme = ""; + + # override the final config + #override = {}; + + # config the bar layouts for monitors + layout = { + "bar.layouts" = { + "0" = { + left = ["dashboard" "workspaces"]; + middle = ["media"]; + right = ["volume" "systray" "notifications"]; + }; + }; + }; + + # settings = { + # bar.launcher.autoDetectIcon = true; + # bar.workspaces.show_icons = true; + # + # menus.clock = { + # time = { + # military = true; + # hideSeconds = true; + # }; + # weather.unit = "metric"; + # }; + # + # menus.dashboard.directories.enabled = false; + # menus.dashboard.stats.enable_gpu = true; + # + # theme.bar.transparent = true; + # + # theme.font = { + # name = "CaskaydiaCove NF"; + # size = "16px"; + # }; + # }; + }; + */ + # I want to use fish as my login shell but it always # goes terrible cause it isn't POSIX compliant, so # instead Bash is my login and it will just exec fish diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 2c4d794..c06299d 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -6,7 +6,8 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz"; - sha256 = "15k41il0mvmwyv6jns4z8k6khhmb22jk5gpcqs1paym3l01g6abn"; + sha256 = "0c07xj74vsj37d3a8f98i9rhhhr99ckwlp45n40f0qkmigm3pk8s"; + #sha256 = "15k41il0mvmwyv6jns4z8k6khhmb22jk5gpcqs1paym3l01g6abn"; }; in { imports = [ @@ -37,7 +38,7 @@ in { efiSupport = true; #efiInstallAsRemovable = true; # in case canTouchEfiVariables doesn't work on this system device = "nodev"; - useOSProber = true; + useOSProber = false; }; # GitHub: vinceliuice/grub2-themes grub2-theme = { @@ -118,19 +119,34 @@ in { isNormalUser = true; extraGroups = ["wheel"]; shell = pkgs.bash; #pkgs.fish - packages = with pkgs; [ - firefox - nitch - starfetch + packages = let + # TODO: can I just do this: https://nix.dev/manual/nix/2.18/command-ref/new-cli/nix3-flake#url-like-syntax + # instead to use colmena's flake.nix by specifying a rev hash in the flake input? + colmena-src = pkgs.fetchFromGitHub { + owner = "zhaofengli"; + repo = "colmena"; + rev = "47b6414d800c8471e98ca072bc0835345741a56a"; + sha256 = "rINodqeUuezuCWOnpJgrH7u9vJ86fYT+Dj8Mu8T/IBc="; + }; + colmena-latest = pkgs.callPackage "${colmena-src}/package.nix" {}; + in + with pkgs; [ + firefox + nitch + starfetch - # flatpak requires gnome-software - # for graphical applications - flatpak - gnome-software + hyprpanel - jetbrains.rider - gitkraken - ]; + # flatpak requires gnome-software + # for graphical applications + flatpak + gnome-software + + colmena-latest + + jetbrains.rider + gitkraken + ]; }; # user for my professional jobs and stuff @@ -163,10 +179,11 @@ in { home-manager = { users.me = import ../../homes/me; + #extraSpecialArgs = {inherit inputs pkgs;}; sharedModules = [ - inputs.nixcord.homeManagerModules.nixcord inputs.ags.homeManagerModules.default - {nixpkgs.overlays = [inputs.hyprpanel.overlay];} + inputs.nixcord.homeManagerModules.nixcord + #{nixpkgs.overlays = [inputs.hyprpanel.overlay];} ]; }; @@ -180,13 +197,16 @@ in { wl-clipboard # clipboard for wayland pavucontrol - (callPackage ./sddm-theme-corners.nix {}).sddm-theme-corners + (callPackage ../sddm-theme-corners.nix {}).sddm-theme-corners # dependencies for my sddm theme: pkgs.libsForQt5.qt5.qtgraphicaleffects python311 # I use 3.11 since it's in a pretty stable state now poetry # python dependency management and packaging + # DEBUG: using neofetch temporarily to see if my system upgrades properly + neofetch + # fish plugins grc # colorise command outputs @@ -208,6 +228,7 @@ in { brightnessctl acpi vim + powertop # Unix Commands wget @@ -219,8 +240,8 @@ in { programs = { hyprland = { enable = true; - package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; - portalPackage = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland; + #package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; + #portalPackage = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland; xwayland.enable = true; }; diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 3f5afed..117cfee 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -121,7 +121,7 @@ in { rev = "47b6414d800c8471e98ca072bc0835345741a56a"; sha256 = "rINodqeUuezuCWOnpJgrH7u9vJ86fYT+Dj8Mu8T/IBc="; }; - colmena-new = pkgs.callPackage "${colmena-src}/package.nix" {}; + colmena-latest = pkgs.callPackage "${colmena-src}/package.nix" {}; in with pkgs; [ firefox @@ -132,7 +132,7 @@ in { flatpak gnome-software - colmena-new + colmena-latest gitkraken # NOTE: downloadthing this causes my PC to freak!! ("too many open files" error) From c3b02c5f7bd2454c53132b91394abfe3e5e59d36 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 24 Feb 2025 13:19:36 +1000 Subject: [PATCH 006/197] improved organisation moved host modules to hosts/modules and modified deploy script --- deploy | 16 ++++++++++++++++ deploy-remote | 13 ------------- homes/modules/ags/config.js | 10 +++++++--- homes/modules/ags/widgets/fullscreen.js | 8 ++++---- {modules => hosts/modules}/colmena.nix | 0 {modules => hosts/modules}/core/bluetooth.nix | 0 .../modules}/core/bootloader/grub.nix | 0 .../modules}/core/bootloader/systemd-boot.nix | 0 .../modules}/core/garbage-collector.nix | 0 .../modules}/core/sound/default.nix | 0 .../modules}/core/sound/pipewire.nix | 0 {modules => hosts/modules}/discord/nixcord.nix | 0 {flakes => hosts/modules/flakes}/wishlist/README | 0 .../modules/flakes}/wishlist/flake.nix | 0 .../modules/flakes}/wishlist/wishlist.nix | 0 {modules => hosts/modules}/hyprland/default.nix | 0 {modules => hosts/modules}/wishlist.nix | 0 {modules => hosts/modules}/wishlist.nix.bak | 0 18 files changed, 27 insertions(+), 20 deletions(-) delete mode 100755 deploy-remote rename {modules => hosts/modules}/colmena.nix (100%) rename {modules => hosts/modules}/core/bluetooth.nix (100%) rename {modules => hosts/modules}/core/bootloader/grub.nix (100%) rename {modules => hosts/modules}/core/bootloader/systemd-boot.nix (100%) rename {modules => hosts/modules}/core/garbage-collector.nix (100%) rename {modules => hosts/modules}/core/sound/default.nix (100%) rename {modules => hosts/modules}/core/sound/pipewire.nix (100%) rename {modules => hosts/modules}/discord/nixcord.nix (100%) rename {flakes => hosts/modules/flakes}/wishlist/README (100%) rename {flakes => hosts/modules/flakes}/wishlist/flake.nix (100%) rename {flakes => hosts/modules/flakes}/wishlist/wishlist.nix (100%) rename {modules => hosts/modules}/hyprland/default.nix (100%) rename {modules => hosts/modules}/wishlist.nix (100%) rename {modules => hosts/modules}/wishlist.nix.bak (100%) diff --git a/deploy b/deploy index 4dc0576..adec8b2 100755 --- a/deploy +++ b/deploy @@ -6,6 +6,7 @@ usage="Usage: $(basename $0) [OPTIONS] Options: -f, --fresh Remove old content in the nixstore (good for debugging) -b, --bootloader Reinstall the bootloader + -r, --remote Locally build and remotely deploy Colmena hive -h, --help Show this message (^_^)" # delete all cached entries @@ -25,11 +26,26 @@ rebuild_flake () { fi } +deploy_hive () { + echo "[+] Adding keys to ssh-agent" + ssh-add ~/.ssh/id_hyrule + printf "\n" + + git add . --verbose + # Deploy to all Colmena hives + colmena build --experimental-flake-eval + colmena apply --experimental-flake-eval + # colmena apply --on hyrule --experimental-flake-eval +} + # check which flags were given flag_fresh=false flag_bootloader=false for flag in "$@"; do case "$flag" in + -r|--remote) + deploy_hive + exit 0 ;; -f|--fresh) flag_fresh=true ;; -b|--bootloader) diff --git a/deploy-remote b/deploy-remote deleted file mode 100755 index be09c7d..0000000 --- a/deploy-remote +++ /dev/null @@ -1,13 +0,0 @@ -#!/usr/bin/env bash - -set -e # terminate if any command fails - -echo "[+] Adding keys to ssh-agent" -ssh-add ~/.ssh/id_hyrule -printf "\n" - -git add . -# Deploy to all Colmena hives -colmena build --experimental-flake-eval -colmena apply --experimental-flake-eval -# colmena apply --on hyrule --experimental-flake-eval diff --git a/homes/modules/ags/config.js b/homes/modules/ags/config.js index 904ba9e..5a11efc 100755 --- a/homes/modules/ags/config.js +++ b/homes/modules/ags/config.js @@ -1,24 +1,28 @@ import { AppLauncher } from "./widgets/applauncher.js" -import { Notifications } from "./widgets/notifications.js" +//import { Notifications } from "./widgets/notifications.js" +/* const date = Variable('', { poll: [1000, 'date'], }) +*/ +/* const Bar = (monitor = 0) => Widget.Window({ monitor, name: 'bar${monitor}', anchor: ['top', 'left', 'right'], child: Widget.Label({ label: date.bind() }), }) +*/ App.config({ style: "./style.css", // icons: "./assets", windows: [ - Bar(), + //Bar(), AppLauncher, - Notifications() + //Notifications() ] // gtkTheme: "Adwaita-dark", // cursorTheme: "Qogir", diff --git a/homes/modules/ags/widgets/fullscreen.js b/homes/modules/ags/widgets/fullscreen.js index a6c60f0..72682f2 100755 --- a/homes/modules/ags/widgets/fullscreen.js +++ b/homes/modules/ags/widgets/fullscreen.js @@ -2,10 +2,10 @@ const WINDOW_NAME = "fullscreen"; const Fullscreen = (children) => Widget.Box({ vertical: true, - css: "background-image: url('https://images2.alphacoders.com/135/1351579.png');" - + "background-size: cover;" - + "background-position: center;" - + "background-repeat: no-repeat;", + css: "background-image: url('~/downloads/wallpaper/kill-my-firstborn/astronaut-pink-blue.png');", + //+ "background-size: cover;" + //+ "background-position: center;" + //+ "background-repeat: no-repeat;", children: children, }) diff --git a/modules/colmena.nix b/hosts/modules/colmena.nix similarity index 100% rename from modules/colmena.nix rename to hosts/modules/colmena.nix diff --git a/modules/core/bluetooth.nix b/hosts/modules/core/bluetooth.nix similarity index 100% rename from modules/core/bluetooth.nix rename to hosts/modules/core/bluetooth.nix diff --git a/modules/core/bootloader/grub.nix b/hosts/modules/core/bootloader/grub.nix similarity index 100% rename from modules/core/bootloader/grub.nix rename to hosts/modules/core/bootloader/grub.nix diff --git a/modules/core/bootloader/systemd-boot.nix b/hosts/modules/core/bootloader/systemd-boot.nix similarity index 100% rename from modules/core/bootloader/systemd-boot.nix rename to hosts/modules/core/bootloader/systemd-boot.nix diff --git a/modules/core/garbage-collector.nix b/hosts/modules/core/garbage-collector.nix similarity index 100% rename from modules/core/garbage-collector.nix rename to hosts/modules/core/garbage-collector.nix diff --git a/modules/core/sound/default.nix b/hosts/modules/core/sound/default.nix similarity index 100% rename from modules/core/sound/default.nix rename to hosts/modules/core/sound/default.nix diff --git a/modules/core/sound/pipewire.nix b/hosts/modules/core/sound/pipewire.nix similarity index 100% rename from modules/core/sound/pipewire.nix rename to hosts/modules/core/sound/pipewire.nix diff --git a/modules/discord/nixcord.nix b/hosts/modules/discord/nixcord.nix similarity index 100% rename from modules/discord/nixcord.nix rename to hosts/modules/discord/nixcord.nix diff --git a/flakes/wishlist/README b/hosts/modules/flakes/wishlist/README similarity index 100% rename from flakes/wishlist/README rename to hosts/modules/flakes/wishlist/README diff --git a/flakes/wishlist/flake.nix b/hosts/modules/flakes/wishlist/flake.nix similarity index 100% rename from flakes/wishlist/flake.nix rename to hosts/modules/flakes/wishlist/flake.nix diff --git a/flakes/wishlist/wishlist.nix b/hosts/modules/flakes/wishlist/wishlist.nix similarity index 100% rename from flakes/wishlist/wishlist.nix rename to hosts/modules/flakes/wishlist/wishlist.nix diff --git a/modules/hyprland/default.nix b/hosts/modules/hyprland/default.nix similarity index 100% rename from modules/hyprland/default.nix rename to hosts/modules/hyprland/default.nix diff --git a/modules/wishlist.nix b/hosts/modules/wishlist.nix similarity index 100% rename from modules/wishlist.nix rename to hosts/modules/wishlist.nix diff --git a/modules/wishlist.nix.bak b/hosts/modules/wishlist.nix.bak similarity index 100% rename from modules/wishlist.nix.bak rename to hosts/modules/wishlist.nix.bak From b646675328666b3f7856040b5327439c74e85852 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 25 Feb 2025 14:03:03 +1000 Subject: [PATCH 007/197] ssh host changes for lolcathost and hyrule --- homes/me/default.nix | 21 ++++++++++----------- homes/subspace/default.nix | 19 +++++++++++++++++-- hosts/hyrule/default.nix | 3 +-- hosts/lolcathost/default.nix | 1 + hosts/myputer/default.nix | 1 + 5 files changed, 30 insertions(+), 15 deletions(-) diff --git a/homes/me/default.nix b/homes/me/default.nix index 2636693..b469574 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -11,7 +11,6 @@ }; imports = [ - #inputs.hyprpanel.packages.homeManagerModules.hyprpanel ../modules/git.nix ../modules/bat.nix ../modules/fish.nix @@ -23,7 +22,7 @@ ../modules/nixcord.nix #../modules/hypr/hypridle.nix - #../modules/hypr/hyprlock.nix + ../modules/hypr/hyprlock.nix ../modules/kanshi.nix ../modules/ags ]; @@ -126,6 +125,15 @@ port = 22; identityFile = "~/.ssh/id_subspace"; }; + dead = { + hostname = "deadlyserver.com"; + user = "emile"; + port = 29843; + identityFile = "~/.ssh/id_deadlyserver"; + setEnv = { + TERM = "xterm-256color"; + }; + }; youcue = { hostname = "moss.labs.eait.uq.edu.au"; user = "s4740056"; @@ -135,15 +143,6 @@ TERM = "xterm-256color"; }; }; - deadlyserver = { - hostname = "deadlyserver.com"; - user = "emile"; - port = 29843; - identityFile = "~/.ssh/id_deadlyserver"; - setEnv = { - TERM = "xterm-256color"; - }; - }; }; }; diff --git a/homes/subspace/default.nix b/homes/subspace/default.nix index 6b1c0fa..4cda2a2 100644 --- a/homes/subspace/default.nix +++ b/homes/subspace/default.nix @@ -35,18 +35,33 @@ forwardAgent = true; addKeysToAgent = "yes"; - matchBlocks = { + machBlocks = { hyrule = { hostname = "imbored.dev"; user = "ae"; port = 22; identityFile = "~/.ssh/id_hyrule"; + setEnv = { + TERM = "linux"; + }; }; - YearnForTheMines = { + dead = { hostname = "deadlyserver.com"; user = "emile"; port = 29843; identityFile = "~/.ssh/id_deadlyserver"; + setEnv = { + TERM = "xterm-256color"; + }; + }; + youcue = { + hostname = "moss.labs.eait.uq.edu.au"; + user = "s4740056"; + port = 22; + identityFile = "~/.ssh/id_youcue"; + setEnv = { + TERM = "xterm-256color"; + }; }; }; }; diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 11048b6..c2c0461 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -450,10 +450,9 @@ in { }; environment.systemPackages = with pkgs; [ + git vim helix - - #wishlist ]; programs = { diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index c06299d..b348b47 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -229,6 +229,7 @@ in { acpi vim powertop + gcc # Unix Commands wget diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 117cfee..7e8c5ce 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -213,6 +213,7 @@ in { acpi vim nix-prefetch-git + gcc # Unix Commands wget From b3bb2227d1b77712821e0eb94add874a3f2c1267 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 26 Feb 2025 08:42:18 +1000 Subject: [PATCH 008/197] made all hosts more similar --- deploy | 1 + docs/nixos_notes.md | 2 ++ homes/me/default.nix | 2 +- homes/subspace/default.nix | 2 +- hosts/imbored/default.nix | 1 + hosts/lolcathost/default.nix | 4 +++- 6 files changed, 9 insertions(+), 3 deletions(-) create mode 100644 docs/nixos_notes.md diff --git a/deploy b/deploy index adec8b2..9e2f02e 100755 --- a/deploy +++ b/deploy @@ -20,6 +20,7 @@ rebuild_flake () { git add . --verbose if [ "$1" = "reinstall-bootloader" ]; then sudo nixos-rebuild switch --flake . --install-bootloader + # STC_DISPLAY_ALL_UNITS=1 (verbose, show output of all units) else sudo nixos-rebuild switch --flake . #nixos-rebuild build --flake .# --cores 8 -j 1 diff --git a/docs/nixos_notes.md b/docs/nixos_notes.md new file mode 100644 index 0000000..e396b10 --- /dev/null +++ b/docs/nixos_notes.md @@ -0,0 +1,2 @@ +Building specific parts of a NixOS system +https://nixos.org/manual/nixos/stable/#sec-building-parts diff --git a/homes/me/default.nix b/homes/me/default.nix index b469574..f35678d 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -92,7 +92,7 @@ # DEBUG: testing if my xdg-desktop-portal-hyprland is working or not obs-studio = { - enable = true; + enable = false; plugins = with pkgs.obs-studio-plugins; [ wlrobs obs-backgroundremoval diff --git a/homes/subspace/default.nix b/homes/subspace/default.nix index 4cda2a2..c827022 100644 --- a/homes/subspace/default.nix +++ b/homes/subspace/default.nix @@ -35,7 +35,7 @@ forwardAgent = true; addKeysToAgent = "yes"; - machBlocks = { + matchBlocks = { hyrule = { hostname = "imbored.dev"; user = "ae"; diff --git a/hosts/imbored/default.nix b/hosts/imbored/default.nix index df99d85..0e0e268 100755 --- a/hosts/imbored/default.nix +++ b/hosts/imbored/default.nix @@ -76,6 +76,7 @@ in { #}; environment.SystemPackages = with pkgs; [ + btop ]; programs = { diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index b348b47..2dcf179 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -117,7 +117,7 @@ in { # literally me fr (personal account) me = { isNormalUser = true; - extraGroups = ["wheel"]; + extraGroups = ["wheel" "docker"]; shell = pkgs.bash; #pkgs.fish packages = let # TODO: can I just do this: https://nix.dev/manual/nix/2.18/command-ref/new-cli/nix3-flake#url-like-syntax @@ -309,6 +309,8 @@ in { "flakes" ]; + virtualisation.docker.enable = true; + # Some programs need SUID wrappers, can be configured further or are # started in user sessions. # programs.mtr.enable = true; From 35b54acb85dc88b361434febafe73046fe2b06c1 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 1 May 2025 21:16:15 +1000 Subject: [PATCH 009/197] no fucking clue what I changed but good luck (^_^)* --- TODO | 9 +++++++ homes/me/default.nix | 4 ++- homes/modules/editor/vscodium.nix | 9 +++++++ homes/modules/fish.nix | 35 ++++++++++++++++--------- homes/modules/term/default.nix | 9 +++++++ homes/modules/term/ghostty.nix | 43 +++++++++++++++++++++++++++++++ homes/modules/{ => term}/rio.nix | 10 ++++++- hosts/lolcathost/default.nix | 29 ++++++++++++++++----- hosts/modules/steam.nix | 24 +++++++++++++++++ 9 files changed, 151 insertions(+), 21 deletions(-) create mode 100644 TODO create mode 100644 homes/modules/editor/vscodium.nix create mode 100644 homes/modules/term/default.nix create mode 100644 homes/modules/term/ghostty.nix rename homes/modules/{ => term}/rio.nix (90%) create mode 100644 hosts/modules/steam.nix diff --git a/TODO b/TODO new file mode 100644 index 0000000..21efb53 --- /dev/null +++ b/TODO @@ -0,0 +1,9 @@ +Create a command palette accessible with MOD+P (MOD => Windows Key) + (ie make fullscreen, send to monitor, etc) + +Make each monitor's window styling slightly different (just for fun) + +Bind 5 workspaces per connected monitor. + Then use the command palette (discussed prior) to send to + a different workspace (ie because I currently use MOD+SHIFT+n + but if n>=10 then it doesnt work! hence we need a command palette!) diff --git a/homes/me/default.nix b/homes/me/default.nix index f35678d..14e6d99 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -15,9 +15,11 @@ ../modules/bat.nix ../modules/fish.nix ../modules/editor/helix.nix + ../modules/editor/vscodium.nix ../modules/btop.nix - ../modules/rio.nix + ../modules/term/ghostty.nix + ../modules/term/rio.nix ../modules/firefox.nix ../modules/nixcord.nix diff --git a/homes/modules/editor/vscodium.nix b/homes/modules/editor/vscodium.nix new file mode 100644 index 0000000..c5daf64 --- /dev/null +++ b/homes/modules/editor/vscodium.nix @@ -0,0 +1,9 @@ +{pkgs, ...}: { + programs.vscode = { + enable = true; + package = pkgs.vscodium; + + extensions = with pkgs.vscode-extensions; [ + ]; + }; +} diff --git a/homes/modules/fish.nix b/homes/modules/fish.nix index e46175d..bcc7d77 100755 --- a/homes/modules/fish.nix +++ b/homes/modules/fish.nix @@ -1,19 +1,30 @@ { config, + lib, pkgs, ... }: { - programs.fish = { - enable = true; - interactiveShellInit = '' - #set -g fish_greeting "Welcome weary traveler to my shop" - cat ~/banner - ''; - plugins = [ - { - name = "grc"; - src = pkgs.fishPlugins.grc.src; - } - ]; + options = { + morphBashToFish = lib.mkEnableOption "morphBashToFish"; + }; + + config = { + programs.fish = { + enable = true; + interactiveShellInit = '' + # add dotnet completions if it exists (ie we're in a virtual environment) + if type -q dotnet + complete -f -c dotnet -a "(dotnet complete (commandline -cp))" + end + + set -g fish_greeting "Welcome weary traveller to my shop" + ''; + plugins = [ + { + name = "grc"; + src = pkgs.fishPlugins.grc.src; + } + ]; + }; }; } diff --git a/homes/modules/term/default.nix b/homes/modules/term/default.nix new file mode 100644 index 0000000..d446b15 --- /dev/null +++ b/homes/modules/term/default.nix @@ -0,0 +1,9 @@ +{ + lib, + ... +}: +{ + options = { + + } +} diff --git a/homes/modules/term/ghostty.nix b/homes/modules/term/ghostty.nix new file mode 100644 index 0000000..5eb2591 --- /dev/null +++ b/homes/modules/term/ghostty.nix @@ -0,0 +1,43 @@ +{pkgs, ...}: { + home = { + packages = [ + pkgs.ghostty + #(pkgs.writeShellScriptBin "xterm" ''${pkgs.ghostty}/bin/ghostty "$@"'') + ]; + + sessionVariables.TERMINAL = "ghostty"; + }; + + programs.ghostty = { + enable = true; + + settings = { + theme = "Dracula"; + font-family = "Geist Nerd Font"; + font-feature = ["liga" "calt"]; + + window-padding-x = 12; + window-padding-y = 6; + window-theme = "system"; + + window-height = 26; + window-width = 90; + copy-on-select = true; + gtk-single-instance = false; + adw-toolbar-style = "flat"; + + keybind = [ + "ctrl+shift+plus=increase_font_size:1" + "ctrl+shift+minus=decrease_font_size:1" + + "ctrl+h=goto_split:left" + "ctrl+l=goto_split:right" + ]; + }; + + #themes = { + #aylur-dark = colors (import ./colors.nix {scheme = "dark";}); + #aylur-light = colors (import ./colors.nix {scheme = "light";}); + #}; + }; +} diff --git a/homes/modules/rio.nix b/homes/modules/term/rio.nix similarity index 90% rename from homes/modules/rio.nix rename to homes/modules/term/rio.nix index 84ea3a2..88ef968 100755 --- a/homes/modules/rio.nix +++ b/homes/modules/term/rio.nix @@ -3,8 +3,16 @@ pkgs, ... }: { + home = { + packages = [ + pkgs.rio + ]; + + # currently set to ghostty (on lolcathost) + #sessionVariables.TERMINAL = "rio"; + }; + # The terminal I use - # TODO: this is dependent on nvim being installed # TODO: make this into a module with a configurable editor option programs.rio = { enable = true; diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 2dcf179..a75c426 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -6,14 +6,15 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz"; - sha256 = "0c07xj74vsj37d3a8f98i9rhhhr99ckwlp45n40f0qkmigm3pk8s"; - #sha256 = "15k41il0mvmwyv6jns4z8k6khhmb22jk5gpcqs1paym3l01g6abn"; + sha256 = "1qsvg11b5d05z2gvxq2pp6xfg3gpcd363id0h52sicikx3vai93s"; }; in { imports = [ ./hardware-configuration.nix (import "${home-manager}/nixos") inputs.spicetify-nix.nixosModules.default + + ../modules/steam.nix ]; programs.spicetify = let @@ -67,10 +68,10 @@ in { networking.networkmanager.enable = true; # Open ports in the firewall. - # networking.firewall.allowedTCPPorts = [ ... ]; + #networking.firewall.allowedTCPPorts = [ ... ]; # networking.firewall.allowedUDPPorts = [ ... ]; # Or disable the firewall altogether. - networking.firewall.enable = true; + networking.firewall.enable = false; # ----- SERVICES ----- services = { @@ -117,7 +118,7 @@ in { # literally me fr (personal account) me = { isNormalUser = true; - extraGroups = ["wheel" "docker"]; + extraGroups = ["wheel" "netdev" "docker"]; shell = pkgs.bash; #pkgs.fish packages = let # TODO: can I just do this: https://nix.dev/manual/nix/2.18/command-ref/new-cli/nix3-flake#url-like-syntax @@ -187,6 +188,15 @@ in { ]; }; + # set environment variables + environment.sessionVariables = { + # folder names with capitalisation look awful! + XDG_DOWNLOAD_DIR = "$HOME/downloads"; + + # Hint Electrons apps to use Wayland + NIXOS_OZONE_WL = "1"; + }; + # ---- SYSTEM PACKAGES ----- environment.systemPackages = with pkgs; [ # User Environment @@ -207,6 +217,9 @@ in { # DEBUG: using neofetch temporarily to see if my system upgrades properly neofetch + openvpn + inetutils + # fish plugins grc # colorise command outputs @@ -250,6 +263,8 @@ in { zsh.enable = true; fish.enable = true; + nix-ld.enable = true; + # I want to use fish as my login shell but it always goes terrible # cause it isn't POSIX compliant, so instead Bash is my login and # will just exec fish (^-^) @@ -295,8 +310,8 @@ in { # TODO: change my default fonts fontconfig = { defaultFonts = { - serif = ["Iosevka"]; # TODO: package Iosevka Etoile since Iosevka isn't a serif font - sansSerif = ["Iosevka "]; + serif = ["Geist"]; # TODO: package Iosevka Etoile since Iosevka isn't a serif font + sansSerif = ["Geist"]; monospace = ["Cousine"]; emoji = ["Noto Emoji"]; }; diff --git a/hosts/modules/steam.nix b/hosts/modules/steam.nix new file mode 100644 index 0000000..afd9b33 --- /dev/null +++ b/hosts/modules/steam.nix @@ -0,0 +1,24 @@ +{ + pkgs, + lib, + ... +}: { + nixpkgs.config.allowUnfreePredicate = pkg: + builtins.elem (lib.getName pkg) [ + "steam" + "steam-original" + "steam-unwrapped" + "steam-run" + ]; + + programs.steam = { + enable = true; + remotePlay.openFirewall = true; + dedicatedServer.openFirewall = true; + localNetworkGameTransfers.openFirewall = true; + }; + + environment.systemPackages = with pkgs; [ + steamcmd + ]; +} From 09c38f02eaf08f1dba1dead54d901db1085a02ef Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 6 May 2025 16:41:52 +1000 Subject: [PATCH 010/197] added steam + other gaming support specifically applied to laptop only currently --- hosts/lolcathost/default.nix | 6 ++++++ hosts/modules/steam.nix | 22 +++++++++++++++++----- 2 files changed, 23 insertions(+), 5 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index a75c426..889e9d5 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -340,6 +340,12 @@ in { # Enable OpenGL hardware = { graphics.enable = true; + + # opengl = { + # enable = true; + # driSupport = true; + # driSupport32Bit = true; + # } }; # DO NOT MODIFY diff --git a/hosts/modules/steam.nix b/hosts/modules/steam.nix index afd9b33..07f3ae1 100644 --- a/hosts/modules/steam.nix +++ b/hosts/modules/steam.nix @@ -11,14 +11,26 @@ "steam-run" ]; - programs.steam = { - enable = true; - remotePlay.openFirewall = true; - dedicatedServer.openFirewall = true; - localNetworkGameTransfers.openFirewall = true; + programs = { + steam = { + enable = true; + gamescopeSession.enable = true; + + remotePlay.openFirewall = true; + dedicatedServer.openFirewall = true; + localNetworkGameTransfers.openFirewall = true; + }; + + gamemode.enable = true; }; environment.systemPackages = with pkgs; [ steamcmd + + mangohud + protonup-qt + lutris + bottles + heroic ]; } From c626227f55f7096a1adb166d24bcb7a7ed6ae0bf Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 7 May 2025 02:40:49 +1000 Subject: [PATCH 011/197] Added host module for Obsidian app specifically applied to laptop only currently --- hosts/lolcathost/default.nix | 1 + hosts/modules/obsidian.nix | 5 +++++ 2 files changed, 6 insertions(+) create mode 100644 hosts/modules/obsidian.nix diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 889e9d5..d60e71f 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -15,6 +15,7 @@ in { inputs.spicetify-nix.nixosModules.default ../modules/steam.nix + ../modules/obsidian.nix ]; programs.spicetify = let diff --git a/hosts/modules/obsidian.nix b/hosts/modules/obsidian.nix new file mode 100644 index 0000000..ed800c3 --- /dev/null +++ b/hosts/modules/obsidian.nix @@ -0,0 +1,5 @@ +{pkgs, ...}: { + environment.systemPackages = with pkgs; [ + obsidian + ]; +} From 3bc320cc6a8e8260a358338afcdcadb7948add1c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 11 May 2025 22:29:40 +1000 Subject: [PATCH 012/197] added modules for qFlipper, ChameleonUltraGUI, and AngryOxide ChameleonUltraGUI and AngryOxide also had derivations written to package them --- NEW_TODO | 2 + hosts/hyrule/default.nix | 2 + hosts/imbored/default.nix | 7 +- hosts/lolcathost/default.nix | 10 +- hosts/modules/angryoxide.nix | 5 + hosts/modules/chameleonultragui.nix | 5 + hosts/modules/flipperzero.nix | 6 + hosts/myputer/default.nix | 2 + hosts/packages/README | 5 + hosts/packages/angryoxide/default.nix | 84 +++ hosts/packages/chameleonultragui/default.nix | 483 ++++++++++++++++++ .../chameleonultragui/default.nix.bak1 | 474 +++++++++++++++++ 12 files changed, 1082 insertions(+), 3 deletions(-) create mode 100644 NEW_TODO create mode 100644 hosts/modules/angryoxide.nix create mode 100644 hosts/modules/chameleonultragui.nix create mode 100644 hosts/modules/flipperzero.nix create mode 100644 hosts/packages/README create mode 100644 hosts/packages/angryoxide/default.nix create mode 100644 hosts/packages/chameleonultragui/default.nix create mode 100644 hosts/packages/chameleonultragui/default.nix.bak1 diff --git a/NEW_TODO b/NEW_TODO new file mode 100644 index 0000000..b206852 --- /dev/null +++ b/NEW_TODO @@ -0,0 +1,2 @@ +- [ ] True using `gitHashes` argument instead of patching? + diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index c2c0461..1a1dafd 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -459,6 +459,8 @@ in { fish.enable = true; bash = { + completion.enable = true; + interactiveShellInit = '' if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]] then diff --git a/hosts/imbored/default.nix b/hosts/imbored/default.nix index 0e0e268..c5df73c 100755 --- a/hosts/imbored/default.nix +++ b/hosts/imbored/default.nix @@ -9,7 +9,7 @@ sha256 = "19w63qccz78v0spx03911z98w1bvlxvd07hb0ma14a4vdzi4ninj"; }; in { - # TODO: + # TODO: # - add github:charmbracelet/soft-serve # - add forgejo @@ -42,7 +42,7 @@ in { networkmanager.enable = true; firewall.allowedTCPPorts = [ 22 # sshd - ] + ]; }; users = { @@ -80,5 +80,8 @@ in { ]; programs = { + bash = { + completion.enable = true; + }; }; } diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index d60e71f..6c3daa8 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -1,7 +1,6 @@ { pkgs, inputs, - lib, ... }: let home-manager = builtins.fetchTarball { @@ -16,6 +15,10 @@ in { ../modules/steam.nix ../modules/obsidian.nix + + ../modules/angryoxide.nix + ../modules/flipperzero.nix + ../modules/chameleonultragui.nix ]; programs.spicetify = let @@ -230,6 +233,8 @@ in { doggo tldr btop + eza + ripgrep # TODO: once upgraded past Nix-24.07 this line won't be necessary (I think) # helix will support nixd by default @@ -241,6 +246,7 @@ in { git-filter-repo brightnessctl acpi + upower vim powertop gcc @@ -270,6 +276,8 @@ in { # cause it isn't POSIX compliant, so instead Bash is my login and # will just exec fish (^-^) bash = { + completion.enable = true; + interactiveShellInit = '' if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]] then diff --git a/hosts/modules/angryoxide.nix b/hosts/modules/angryoxide.nix new file mode 100644 index 0000000..ae4faa7 --- /dev/null +++ b/hosts/modules/angryoxide.nix @@ -0,0 +1,5 @@ +{pkgs, ...}: { + environment.systemPackages = with pkgs; [ + (callPackage ../packages/angryoxide {}) + ]; +} diff --git a/hosts/modules/chameleonultragui.nix b/hosts/modules/chameleonultragui.nix new file mode 100644 index 0000000..6999022 --- /dev/null +++ b/hosts/modules/chameleonultragui.nix @@ -0,0 +1,5 @@ +{pkgs, ...}: { + environment.systemPackages = with pkgs; [ + (callPackage ../packages/chameleonultragui {}) + ]; +} diff --git a/hosts/modules/flipperzero.nix b/hosts/modules/flipperzero.nix new file mode 100644 index 0000000..7c466ad --- /dev/null +++ b/hosts/modules/flipperzero.nix @@ -0,0 +1,6 @@ +{pkgs, ...}: { + environment.systemPackages = with pkgs; [ + # flipper zero desktop app + qflipper + ]; +} diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 7e8c5ce..78ddafb 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -273,6 +273,8 @@ in { # cause it isn't POSIX compliant, so instead Bash is my login and # will just exec fish (^-^) bash = { + completion.enable = true; + interactiveShellInit = '' if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]] then diff --git a/hosts/packages/README b/hosts/packages/README new file mode 100644 index 0000000..e6e892c --- /dev/null +++ b/hosts/packages/README @@ -0,0 +1,5 @@ +This directory (`hosts/packages`) contains custom package derivations, and differs +from `hosts/modules/` which contains importable modules for my nixdots. + +Often each package I write will have a corresponding module that simply +calls `pkgs.callPackage` to install the derivation to the system environment. diff --git a/hosts/packages/angryoxide/default.nix b/hosts/packages/angryoxide/default.nix new file mode 100644 index 0000000..8111339 --- /dev/null +++ b/hosts/packages/angryoxide/default.nix @@ -0,0 +1,84 @@ +{ + pkgs, + lib, + ... +}: let + # shared/global properties + angryoxide-owner = "Ragnt"; + angryoxide-pname = "AngryOxide"; + angryoxide-version = "0.8.32"; + angryoxide-meta = { + homepage = "https://github.com/${angryoxide-owner}/${angryoxide-pname}"; + license = lib.licenses.gpl3; + maintainers = [lib.maintainers.emileclarkb]; + }; + + # "Vendored LibWifi used in AngryOxide" + angryoxide-libwifi-src = pkgs.fetchFromGitHub { + owner = angryoxide-owner; + repo = "libwifi"; + # this specific revision is requested (by rev "e1352..." of AngryOxide) + rev = "71268e1898ad88b8b5d709e186836db417b33e81"; + sha256 = "0af9y7bvr3rban6bslsd9smrvibfp1b7d4nfw7wkdxfp49kx6zyr"; + }; + + # Using `mkDerivation` not `buildRustPackage` because + # AngryOxide uses Git submodules for a patched version of "LibWifi", + # and these aren't moved into `/build/source/libs/` for the `buildPhase`. + # Simply fix right? Well no I can't override `buildPhase`... + angryoxide-src = pkgs.stdenv.mkDerivation rec { + pname = "${angryoxide-pname}-source"; + version = angryoxide-version; + + src = pkgs.fetchFromGitHub { + owner = "Ragnt"; + repo = pname; + rev = "e1352c8aad370efa8db69d175686e4353c6002bd"; + sha256 = "07nhvy7kp7z4y0fdslv56pw7kz6idcpma42f4hyilrmazjbbjmja"; + # clone git submodules (needed for the rust workspace libs) + fetchSubmodules = true; + }; + + buildPhase = '' + # ensure $out and /libwifi paths exist + mkdir -p $out/libs/libwifi + # copy only the necessary source files + cp Cargo.toml Cargo.lock $out/ + cp -r $src/.cargo $src/assets $src/completions $src/libs $src/src $out/ + # ensure libwifi submodule is copied to the build environment + cp -r ${angryoxide-libwifi-src}/. $out/libs/libwifi/ + ''; + + installPhase = let + # SOURCE + completionScriptBash = "completions/bash_angry_oxide_completions"; + # DESTINATION + completionDirBash = "$out/share/bash-completion/completions"; + in '' + # mkdir -p $out/bin + #mkdir $out/bin + #cp target/release/angryoxide $out/bin + + # add bash completions + #mkdir -p ${completionDirBash} + #cp ${completionScriptBash} ${completionDirBash}/angryoxide + ''; + + meta = + { + description = "AngryOxide's source files isolated by (@emileclarkb) into a separate Nix derivation."; + } + // angryoxide-meta; + }; +in + pkgs.rustPackages.rustPlatform.buildRustPackage { + pname = angryoxide-pname; + version = angryoxide-version; + src = angryoxide-src; + cargoHash = "sha256-Dxo1iLxl+wn2qAZh3+bf2n00MPE2LlG5boB6iJC/CDA="; + meta = + { + description = "802.11 Attack Tool"; + } + // angryoxide-meta; + } diff --git a/hosts/packages/chameleonultragui/default.nix b/hosts/packages/chameleonultragui/default.nix new file mode 100644 index 0000000..0aa10ec --- /dev/null +++ b/hosts/packages/chameleonultragui/default.nix @@ -0,0 +1,483 @@ +{ + pkgs, + lib, + makeDesktopItem, + copyDesktopItems, + ... +}: +# ChameleonUltraGUI requires flutter sdk >3.0.0 +pkgs.flutter324.buildFlutterApplication +rec { + pname = "ChameleonUltraGUI"; + version = "1.1.2"; + + src = pkgs.fetchFromGitHub { + owner = "GameTec-live"; + repo = "ChameleonUltraGUI"; + sha256 = "1mb6wkqk6vaamrhflfhsgp5gvqiw2qkvmy7j65abcx7sn5990i27"; + rev = "11424abaccb4a010fcbeab9799ae8f675d8afe99"; + }; + + desktopItems = [ + (makeDesktopItem { + name = pname; + desktopName = pname; + genericName = pname; + + icon = "chameleonultragui"; + comment = meta.description; + + exec = "chameleonultragui %u"; + type = "Application"; + terminal = false; + + categories = ["Utility"]; + keywords = [ + "Flutter" + "share" + "files" + "chameleon" + "chameleonultra" + "chameleonlite" + ]; + }) + ]; + + # path to application within fetched sources + sourceRoot = "source/chameleonultragui"; + + buildInputs = [ + pkgs.imagemagick # creating mipmaps for share/icons + pkgs.yj # converting pubspec.lock yaml->json + ]; + + nativeBuildInputs = [ + copyDesktopItems + ]; + + buildArguments = ["--release"]; + + # source files compile with Flutter >3.29.0 but this + # derivation uses 3.24.0 (so we patch for compatability) + postPatch = let + argbPatch = '' + --- general.dart.old 2025-05-11 15:59:51.812132078 +1000 + +++ general.dart 2025-05-11 15:58:14.755856407 +1000 + @@ -211,7 +211,7 @@ + } + + String colorToHex(Color color) { + - return '#\''${color.toARGB32().toRadixString(16).padLeft(8, '0').substring(2)}'; + + return '#\''${color.value.toRadixString(16).padLeft(8, '0').substring(2)}'; + } + + Color hexToColor(String hex) { + ''; + in '' + # patch source files using Color.toARGB32 method (not defined in Flutter 3.24) + argbPatch="${argbPatch}" + patch lib/helpers/general.dart <(echo "$argbPatch") + ''; + + postInstall = '' + # create mipmaps of desktop logo + logoOriginal="assets/logo-color-desktop.png" + for i in 16 32 64 128 256 512; do + res="$i"x"$i" + d="$out"/share/icons/hicolor/"$res"/apps + mkdir -p $d + ${pkgs.imagemagick}/bin/magick $logoOriginal -resize $res $d/chameleonultragui.png + done + ''; + + # Nix doesn't natively have a fromYAML function (so I made this instead) + pubspecLock = let + appRoot = "${src}/chameleonultragui"; + + # when generating patch files use -u flag and then + # make sure to escape all " characters for Nix string + pubspecLockPatch = '' + --- pubspec.lock.bak2025-05-10 15:42:44.287730979 +1000 + +++ pubspec.lock2025-05-10 15:41:23.778480048 +1000 + @@ -5,18 +5,23 @@ + dependency: transitive + description: + name: _fe_analyzer_shared + - sha256: dc27559385e905ad30838356c5f5d574014ba39872d732111cd07ac0beff4c57 + + sha256: f256b0c0ba6c7577c15e2e4e114755640a875e885099367bf6e012b19314c834 + url: \"https://pub.dev\" + source: hosted + - version: \"80.0.0\" + + version: \"72.0.0\" + + _macros: + + dependency: transitive + + description: dart + + source: sdk + + version: \"0.3.2\" + analyzer: + dependency: transitive + description: + name: analyzer + - sha256: \"192d1c5b944e7e53b24b5586db760db934b177d4147c42fbca8c8c5f1eb8d11e\" + + sha256: b652861553cd3990d8ed361f7979dc6d7053a9ac8843fa73820ab68ce5410139 + url: \"https://pub.dev\" + source: hosted + - version: \"7.3.0\" + + version: \"6.7.0\" + archive: + dependency: \"direct main\" + description: + @@ -37,26 +42,26 @@ + dependency: \"direct main\" + description: + name: async + - sha256: d2872f9c19731c2e5f10444b14686eb7cc85c76274bd6c16e1816bff9a3bab63 + + sha256: \"947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c\" + url: \"https://pub.dev\" + source: hosted + - version: \"2.12.0\" + + version: \"2.11.0\" + boolean_selector: + dependency: transitive + description: + name: boolean_selector + - sha256: \"8aab1771e1243a5063b8b0ff68042d67334e3feab9e95b9490f9a6ebf73b42ea\" + + sha256: \"6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66\" + url: \"https://pub.dev\" + source: hosted + - version: \"2.1.2\" + + version: \"2.1.1\" + characters: + dependency: transitive + description: + name: characters + - sha256: f71061c654a3380576a52b451dd5532377954cf9dbd272a78fc8479606670803 + + sha256: \"04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.4.0\" + + version: \"1.3.0\" + checked_yaml: + dependency: transitive + description: + @@ -77,18 +82,18 @@ + dependency: transitive + description: + name: clock + - sha256: fddb70d9b5277016c77a80201021d40a2247104d9f4aa7bab7157b7e3f05b84b + + sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf + url: \"https://pub.dev\" + source: hosted + - version: \"1.1.2\" + + version: \"1.1.1\" + collection: + dependency: \"direct main\" + description: + name: collection + - sha256: \"2f5709ae4d3d59dd8f7cd309b4e023046b57d8a6c82130785d2b0e5868084e76\" + + sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a + url: \"https://pub.dev\" + source: hosted + - version: \"1.19.1\" + + version: \"1.18.0\" + convert: + dependency: \"direct main\" + description: + @@ -157,10 +162,10 @@ + dependency: transitive + description: + name: fake_async + - sha256: \"6a95e56b2449df2273fd8c45a662d6947ce1ebb7aafe80e550a3f68297f3cacc\" + + sha256: \"511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.3.2\" + + version: \"1.3.1\" + ffi: + dependency: \"direct main\" + description: + @@ -196,11 +201,10 @@ + file_saver: + dependency: \"direct main\" + description: + - path: \".\" + - ref: fix-windows + - resolved-ref: \"3038d74d5560dcca528423fffd745abf31eb88ae\" + - url: \"https://github.com/Foxushka/file_saver.git\" + - source: git + + name: file_saver + + sha256: \"017a127de686af2d2fbbd64afea97052d95f2a0f87d19d25b87e097407bf9c1e\" + + url: \"https://pub.dev\" + + source: hosted + version: \"0.2.14\" + fixnum: + dependency: transitive + @@ -234,11 +238,10 @@ + flutter_libserialport: + dependency: \"direct main\" + description: + - path: \".\" + - ref: main + - resolved-ref: \"6740aae075505a220a98492910b090824efc7910\" + - url: \"https://github.com/NeariX67/flutter_libserialport.git\" + - source: git + + name: flutter_libserialport + + sha256: d193b5ac819db6540d20cc8d20d9f5ec9e3396edb4d2c4a23c97863fa9132336 + + url: \"https://pub.dev\" + + source: hosted + version: \"0.5.0\" + flutter_lints: + dependency: \"direct dev\" + @@ -347,18 +350,18 @@ + dependency: transitive + description: + name: leak_tracker + - sha256: c35baad643ba394b40aac41080300150a4f08fd0fd6a10378f8f7c6bc161acec + + sha256: \"3f87a60e8c63aecc975dda1ceedbc8f24de75f09e4856ea27daf8958f2f0ce05\" + url: \"https://pub.dev\" + source: hosted + - version: \"10.0.8\" + + version: \"10.0.5\" + leak_tracker_flutter_testing: + dependency: transitive + description: + name: leak_tracker_flutter_testing + - sha256: f8b613e7e6a13ec79cfdc0e97638fddb3ab848452eff057653abd3edba760573 + + sha256: \"932549fb305594d82d7183ecd9fa93463e9914e1b67cacc34bc40906594a1806\" + url: \"https://pub.dev\" + source: hosted + - version: \"3.0.9\" + + version: \"3.0.5\" + leak_tracker_testing: + dependency: transitive + description: + @@ -399,14 +402,22 @@ + url: \"https://pub.dev\" + source: hosted + version: \"1.3.0\" + + macros: + + dependency: transitive + + description: + + name: macros + + sha256: \"0acaed5d6b7eab89f63350bccd82119e6c602df0f391260d0e32b5e23db79536\" + + url: \"https://pub.dev\" + + source: hosted + + version: \"0.1.2-main.4\" + matcher: + dependency: transitive + description: + name: matcher + - sha256: dc58c723c3c24bf8d3e2d3ad3f2f9d7bd9cf43ec6feaa64181775e60190153f2 + + sha256: d2323aa2060500f906aa31a895b4030b6da3ebdcc5619d14ce1aada65cd161cb + url: \"https://pub.dev\" + source: hosted + - version: \"0.12.17\" + + version: \"0.12.16+1\" + material_color_utilities: + dependency: transitive + description: + @@ -419,10 +430,10 @@ + dependency: transitive + description: + name: meta + - sha256: e3641ec5d63ebf0d9b41bd43201a66e3fc79a65db5f61fc181f04cd27aab950c + + sha256: bdb68674043280c3428e9ec998512fb681678676b3c54e773629ffe74419f8c7 + url: \"https://pub.dev\" + source: hosted + - version: \"1.16.0\" + + version: \"1.15.0\" + mobile_scanner: + dependency: \"direct main\" + description: + @@ -467,10 +478,10 @@ + dependency: \"direct main\" + description: + name: path + - sha256: \"75cca69d1490965be98c73ceaea117e8a04dd21217b37b292c9ddbec0d955bc5\" + + sha256: \"087ce49c3f0dc39180befefc60fdb4acd8f8620e5682fe2476afd0b3688bb4af\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.9.1\" + + version: \"1.9.0\" + path_provider: + dependency: transitive + description: + @@ -723,15 +734,15 @@ + dependency: transitive + description: flutter + source: sdk + - version: \"0.0.0\" + + version: \"0.0.99\" + source_span: + dependency: transitive + description: + name: source_span + - sha256: \"254ee5351d6cb365c859e20ee823c3bb479bf4a293c22d17a9f1bf144ce86f7c\" + + sha256: \"53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.10.1\" + + version: \"1.10.0\" + sprintf: + dependency: transitive + description: + @@ -744,42 +755,42 @@ + dependency: transitive + description: + name: stack_trace + - sha256: \"8b27215b45d22309b5cddda1aa2b19bdfec9df0e765f2de506401c071d38d1b1\" + + sha256: \"73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.12.1\" + + version: \"1.11.1\" + stream_channel: + dependency: transitive + description: + name: stream_channel + - sha256: \"969e04c80b8bcdf826f8f16579c7b14d780458bd97f56d107d3950fdbeef059d\" + + sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7 + url: \"https://pub.dev\" + source: hosted + - version: \"2.1.4\" + + version: \"2.1.2\" + string_scanner: + dependency: transitive + description: + name: string_scanner + - sha256: \"921cd31725b72fe181906c6a94d987c78e3b98c2e205b397ea399d4054872b43\" + + sha256: \"556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.4.1\" + + version: \"1.2.0\" + term_glyph: + dependency: transitive + description: + name: term_glyph + - sha256: \"7f554798625ea768a7518313e58f83891c7f5024f88e46e7182a4558850a4b8e\" + + sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84 + url: \"https://pub.dev\" + source: hosted + - version: \"1.2.2\" + + version: \"1.2.1\" + test_api: + dependency: transitive + description: + name: test_api + - sha256: fb31f383e2ee25fbbfe06b40fe21e1e458d14080e3c67e7ba0acfde4df4e0bbd + + sha256: \"5b8a98dafc4d5c4c9c72d8b31ab2b23fc13422348d2997120294d3bac86b4ddb\" + url: \"https://pub.dev\" + source: hosted + - version: \"0.7.4\" + + version: \"0.7.2\" + typed_data: + dependency: transitive + description: + @@ -855,12 +866,11 @@ + usb_serial: + dependency: \"direct main\" + description: + - path: \".\" + - ref: fix-usbserial + - resolved-ref: \"9fcbacc92bec19ea02d33a40d9f39e45d19cf637\" + - url: \"https://github.com/Foxushka/usbserial.git\" + - source: git + - version: \"0.5.1\" + + name: usb_serial + + sha256: a605a600e34e7f28d4e80851ca3999ef747e42e406138887b8a88b8c382a8b07 + + url: \"https://pub.dev\" + + source: hosted + + version: \"0.5.2\" + uuid: + dependency: \"direct main\" + description: + @@ -881,10 +891,10 @@ + dependency: transitive + description: + name: vm_service + - sha256: \"0968250880a6c5fe7edc067ed0a13d4bae1577fe2771dcf3010d52c4a9d3ca14\" + + sha256: \"5c5f338a667b4c644744b661f309fb8080bb94b18a7e91ef1dbd343bed00ed6d\" + url: \"https://pub.dev\" + source: hosted + - version: \"14.3.1\" + + version: \"14.2.5\" + wakelock_plus: + dependency: \"direct main\" + description: + @@ -958,5 +968,5 @@ + source: hosted + version: \"2.2.1\" + sdks: + - dart: \">=3.7.0-0 <4.0.0\" + + dart: \">=3.5.0 <4.0.0\" + flutter: \">=3.24.0\" + ''; + in + builtins.fromJSON + ( + builtins.readFile (pkgs.runCommand "${pname}-buildenv" { + inputs = [ + # DEBUG (both lines commented) + #pkgs.flutter324 # ChameleonUltraGUI requires sdk >3.0.0 + #pkgs.yj + ]; + } '' + # copy source files to a temporary path to rebuild the lockfile + buildPath=$(mktemp -d) + cp -r "${appRoot}/." "$buildPath/" + + outPubspecLock="$buildPath/pubspec.lock" + # MUST define variables to use multiline Nix string in bash scripting + pubspecLockPatch="${pubspecLockPatch}" + + # apply the pubspec.yaml patch and regenerate lock file + # (create a temporary home directory for flutter to play in) + #(cd $buildPath && chmod -R +w . \ + # && patch ./pubspec.yaml <(echo "$pubspecYamlPatch") \ + # && export HOME=$(mktemp -d) \ + # && flutter --disable-analytics \ + # && flutter config --no-cli-animations \ + # && ${pkgs.flutter}/bin/flutter pub get) + + # patch the lockfile + chmod +w $outPubspecLock + patch $outPubspecLock <(echo "$pubspecLockPatch") + + # convert new lockfile to json and return + ${pkgs.yj}/bin/yj < "$buildPath/pubspec.lock" > $out + '') + ); + + # TODO: try this instead of patching + # gitHashes = { + # dartssh2 = "sha256-2pypKwurziwGLZYuGaxlS2lzN3UvJp3bRTvvYYxEqRI="; + # hotkey_manager_linux = "sha256-aO0h94YZvgV/ggVupNw8GjyZsnXrq3qTHRDtuhNv3oI="; + # system_info2 = "sha256-fly7E2vG+bQ/+QGzXk+DYba73RZccltdW2LpZGDKX60="; + # tray_menu = "sha256-riiAiBEms+9ARog8i+MR1fto1Yqx+gwbBWyNbNq6VTM="; + # window_size = "sha256-71PqQzf+qY23hTJvcm0Oye8tng3Asr42E2vfF1nBmVA="; + # xterm = "sha256-h8vIonTPUVnNqZPk/A4ZV7EYCMyM0rrErL9ZOMe4ZBE="; + # }; + + meta = with lib; { + description = "A GUI for the Chameleon Ultra written in Flutter for crossplatform"; + homepage = "https://github.com/GameTec-live/ChameleonUltraGUI"; + license = licenses.gpl3; + maintainers = [maintainers.emileclarkb]; + platforms = platforms.linux; + }; +} +# find /nix/store -type f -print 2>/dev/null | rg "share/applications" +# NOTE: this command will show that there the desktop file was generated +# at some point. just not anymore?? +# NOTE2: read over ~/workshop/packaging/nixpkgs-24.11/pkgs/build-support/make-desktopitem/default.nix +# and see exactly how makeDesktopItem is defined! +# perhaps the item is added to the build environment but not the output? +# NOTE: see how it builds derivations for the desktop and makes the desktop items? +# (every time I build it does actually make the desktop items) +# HOWEVER I just dont think they're being copied over... +# /nix/store/4hqs6dkxqngi6wi95dmizbvmgm7l5cf0-ChameleonUltraGUI.desktop/share/applications/ChameleonUltraGUI.desktop +# /nix/store/869gy031lf243k0x9ir7gmrsfksipca1-ChameleonUltraGUI.desktop/share/applications/ChameleonUltraGUI.desktop +# /nix/store/adqq7slakkhpjc4hln19jd6p22cc9ci6-ChameleonUltraGUI.desktop/share/applications/ChameleonUltraGUI.desktop +# /nix/store/x9fa3na0is70h4ya4dbfsivk4m3mab57-ChameleonUltraGUI.desktop/share/applications/ChameleonUltraGUI.desktop + diff --git a/hosts/packages/chameleonultragui/default.nix.bak1 b/hosts/packages/chameleonultragui/default.nix.bak1 new file mode 100644 index 0000000..158877a --- /dev/null +++ b/hosts/packages/chameleonultragui/default.nix.bak1 @@ -0,0 +1,474 @@ +{ + pkgs, + lib, + ... +}: +# ChameleonUltraGUI requires flutter sdk >3.0.0 +pkgs.flutter324.buildFlutterApplication +(self: { + pname = "ChameleonUltraGUI"; + version = "1.1.2"; + + src = pkgs.fetchFromGitHub { + owner = "GameTec-live"; + repo = "ChameleonUltraGUI"; + sha256 = "1mb6wkqk6vaamrhflfhsgp5gvqiw2qkvmy7j65abcx7sn5990i27"; + rev = "11424abaccb4a010fcbeab9799ae8f675d8afe99"; + }; + + desktopItems = [ + (pkgs.makeDesktopItem { + name = self.pname; + desktopName = "Chameleon Ultra GUI"; + icon = self.pname; + comment = self.meta.description; + + exec = "chameleonultragui"; + terminal = false; + + categories = [ + "Utility" + ]; + }) + ]; + + # path to application within fetched sources + sourceRoot = "source/chameleonultragui"; + + buildInputs = [ + pkgs.imagemagick # creating mipmaps for share/icons + pkgs.yj # converting pubspec.lock yaml->json + ]; + + buildArguments = ["--release"]; + + # source files compile with Flutter >3.29.0 but this + # derivation uses 3.24.0 (so we patch for compatability) + postPatch = let + argbPatch = '' + --- general.dart.old 2025-05-11 15:59:51.812132078 +1000 + +++ general.dart 2025-05-11 15:58:14.755856407 +1000 + @@ -211,7 +211,7 @@ + } + + String colorToHex(Color color) { + - return '#\''${color.toARGB32().toRadixString(16).padLeft(8, '0').substring(2)}'; + + return '#\''${color.value.toRadixString(16).padLeft(8, '0').substring(2)}'; + } + + Color hexToColor(String hex) { + ''; + in '' + # patch source files using Color.toARGB32 method (not defined in Flutter 3.24) + argbPatch="${argbPatch}" + patch lib/helpers/general.dart <(echo "$argbPatch") + ''; + + # installPhase = '' + # runHook preInstall + + # # create mipmaps of desktop logo + # logoOriginal="assets/logo-color-desktop.png" + # for i in 16 32 64 128 256 512; do + # res="$i"x"$i" + # logoOut="$out"/share/icons/hicolor/"$res"/apps + # mkdir -p $logoOut + # ${pkgs.imagemagick}/bin/magick $logoOriginal -resize $res $logoOut/${pname}.png + # done + + # runHook postInstall + # ''; + + # Nix doesn't natively have a fromYAML function (so I made this instead) + pubspecLock = let + appRoot = "${self.src}/chameleonultragui"; + + # when generating patch files use -u flag and then + # make sure to escape all " characters for Nix string + pubspecLockPatch = '' + --- pubspec.lock.bak2025-05-10 15:42:44.287730979 +1000 + +++ pubspec.lock2025-05-10 15:41:23.778480048 +1000 + @@ -5,18 +5,23 @@ + dependency: transitive + description: + name: _fe_analyzer_shared + - sha256: dc27559385e905ad30838356c5f5d574014ba39872d732111cd07ac0beff4c57 + + sha256: f256b0c0ba6c7577c15e2e4e114755640a875e885099367bf6e012b19314c834 + url: \"https://pub.dev\" + source: hosted + - version: \"80.0.0\" + + version: \"72.0.0\" + + _macros: + + dependency: transitive + + description: dart + + source: sdk + + version: \"0.3.2\" + analyzer: + dependency: transitive + description: + name: analyzer + - sha256: \"192d1c5b944e7e53b24b5586db760db934b177d4147c42fbca8c8c5f1eb8d11e\" + + sha256: b652861553cd3990d8ed361f7979dc6d7053a9ac8843fa73820ab68ce5410139 + url: \"https://pub.dev\" + source: hosted + - version: \"7.3.0\" + + version: \"6.7.0\" + archive: + dependency: \"direct main\" + description: + @@ -37,26 +42,26 @@ + dependency: \"direct main\" + description: + name: async + - sha256: d2872f9c19731c2e5f10444b14686eb7cc85c76274bd6c16e1816bff9a3bab63 + + sha256: \"947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c\" + url: \"https://pub.dev\" + source: hosted + - version: \"2.12.0\" + + version: \"2.11.0\" + boolean_selector: + dependency: transitive + description: + name: boolean_selector + - sha256: \"8aab1771e1243a5063b8b0ff68042d67334e3feab9e95b9490f9a6ebf73b42ea\" + + sha256: \"6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66\" + url: \"https://pub.dev\" + source: hosted + - version: \"2.1.2\" + + version: \"2.1.1\" + characters: + dependency: transitive + description: + name: characters + - sha256: f71061c654a3380576a52b451dd5532377954cf9dbd272a78fc8479606670803 + + sha256: \"04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.4.0\" + + version: \"1.3.0\" + checked_yaml: + dependency: transitive + description: + @@ -77,18 +82,18 @@ + dependency: transitive + description: + name: clock + - sha256: fddb70d9b5277016c77a80201021d40a2247104d9f4aa7bab7157b7e3f05b84b + + sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf + url: \"https://pub.dev\" + source: hosted + - version: \"1.1.2\" + + version: \"1.1.1\" + collection: + dependency: \"direct main\" + description: + name: collection + - sha256: \"2f5709ae4d3d59dd8f7cd309b4e023046b57d8a6c82130785d2b0e5868084e76\" + + sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a + url: \"https://pub.dev\" + source: hosted + - version: \"1.19.1\" + + version: \"1.18.0\" + convert: + dependency: \"direct main\" + description: + @@ -157,10 +162,10 @@ + dependency: transitive + description: + name: fake_async + - sha256: \"6a95e56b2449df2273fd8c45a662d6947ce1ebb7aafe80e550a3f68297f3cacc\" + + sha256: \"511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.3.2\" + + version: \"1.3.1\" + ffi: + dependency: \"direct main\" + description: + @@ -196,11 +201,10 @@ + file_saver: + dependency: \"direct main\" + description: + - path: \".\" + - ref: fix-windows + - resolved-ref: \"3038d74d5560dcca528423fffd745abf31eb88ae\" + - url: \"https://github.com/Foxushka/file_saver.git\" + - source: git + + name: file_saver + + sha256: \"017a127de686af2d2fbbd64afea97052d95f2a0f87d19d25b87e097407bf9c1e\" + + url: \"https://pub.dev\" + + source: hosted + version: \"0.2.14\" + fixnum: + dependency: transitive + @@ -234,11 +238,10 @@ + flutter_libserialport: + dependency: \"direct main\" + description: + - path: \".\" + - ref: main + - resolved-ref: \"6740aae075505a220a98492910b090824efc7910\" + - url: \"https://github.com/NeariX67/flutter_libserialport.git\" + - source: git + + name: flutter_libserialport + + sha256: d193b5ac819db6540d20cc8d20d9f5ec9e3396edb4d2c4a23c97863fa9132336 + + url: \"https://pub.dev\" + + source: hosted + version: \"0.5.0\" + flutter_lints: + dependency: \"direct dev\" + @@ -347,18 +350,18 @@ + dependency: transitive + description: + name: leak_tracker + - sha256: c35baad643ba394b40aac41080300150a4f08fd0fd6a10378f8f7c6bc161acec + + sha256: \"3f87a60e8c63aecc975dda1ceedbc8f24de75f09e4856ea27daf8958f2f0ce05\" + url: \"https://pub.dev\" + source: hosted + - version: \"10.0.8\" + + version: \"10.0.5\" + leak_tracker_flutter_testing: + dependency: transitive + description: + name: leak_tracker_flutter_testing + - sha256: f8b613e7e6a13ec79cfdc0e97638fddb3ab848452eff057653abd3edba760573 + + sha256: \"932549fb305594d82d7183ecd9fa93463e9914e1b67cacc34bc40906594a1806\" + url: \"https://pub.dev\" + source: hosted + - version: \"3.0.9\" + + version: \"3.0.5\" + leak_tracker_testing: + dependency: transitive + description: + @@ -399,14 +402,22 @@ + url: \"https://pub.dev\" + source: hosted + version: \"1.3.0\" + + macros: + + dependency: transitive + + description: + + name: macros + + sha256: \"0acaed5d6b7eab89f63350bccd82119e6c602df0f391260d0e32b5e23db79536\" + + url: \"https://pub.dev\" + + source: hosted + + version: \"0.1.2-main.4\" + matcher: + dependency: transitive + description: + name: matcher + - sha256: dc58c723c3c24bf8d3e2d3ad3f2f9d7bd9cf43ec6feaa64181775e60190153f2 + + sha256: d2323aa2060500f906aa31a895b4030b6da3ebdcc5619d14ce1aada65cd161cb + url: \"https://pub.dev\" + source: hosted + - version: \"0.12.17\" + + version: \"0.12.16+1\" + material_color_utilities: + dependency: transitive + description: + @@ -419,10 +430,10 @@ + dependency: transitive + description: + name: meta + - sha256: e3641ec5d63ebf0d9b41bd43201a66e3fc79a65db5f61fc181f04cd27aab950c + + sha256: bdb68674043280c3428e9ec998512fb681678676b3c54e773629ffe74419f8c7 + url: \"https://pub.dev\" + source: hosted + - version: \"1.16.0\" + + version: \"1.15.0\" + mobile_scanner: + dependency: \"direct main\" + description: + @@ -467,10 +478,10 @@ + dependency: \"direct main\" + description: + name: path + - sha256: \"75cca69d1490965be98c73ceaea117e8a04dd21217b37b292c9ddbec0d955bc5\" + + sha256: \"087ce49c3f0dc39180befefc60fdb4acd8f8620e5682fe2476afd0b3688bb4af\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.9.1\" + + version: \"1.9.0\" + path_provider: + dependency: transitive + description: + @@ -723,15 +734,15 @@ + dependency: transitive + description: flutter + source: sdk + - version: \"0.0.0\" + + version: \"0.0.99\" + source_span: + dependency: transitive + description: + name: source_span + - sha256: \"254ee5351d6cb365c859e20ee823c3bb479bf4a293c22d17a9f1bf144ce86f7c\" + + sha256: \"53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.10.1\" + + version: \"1.10.0\" + sprintf: + dependency: transitive + description: + @@ -744,42 +755,42 @@ + dependency: transitive + description: + name: stack_trace + - sha256: \"8b27215b45d22309b5cddda1aa2b19bdfec9df0e765f2de506401c071d38d1b1\" + + sha256: \"73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.12.1\" + + version: \"1.11.1\" + stream_channel: + dependency: transitive + description: + name: stream_channel + - sha256: \"969e04c80b8bcdf826f8f16579c7b14d780458bd97f56d107d3950fdbeef059d\" + + sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7 + url: \"https://pub.dev\" + source: hosted + - version: \"2.1.4\" + + version: \"2.1.2\" + string_scanner: + dependency: transitive + description: + name: string_scanner + - sha256: \"921cd31725b72fe181906c6a94d987c78e3b98c2e205b397ea399d4054872b43\" + + sha256: \"556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde\" + url: \"https://pub.dev\" + source: hosted + - version: \"1.4.1\" + + version: \"1.2.0\" + term_glyph: + dependency: transitive + description: + name: term_glyph + - sha256: \"7f554798625ea768a7518313e58f83891c7f5024f88e46e7182a4558850a4b8e\" + + sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84 + url: \"https://pub.dev\" + source: hosted + - version: \"1.2.2\" + + version: \"1.2.1\" + test_api: + dependency: transitive + description: + name: test_api + - sha256: fb31f383e2ee25fbbfe06b40fe21e1e458d14080e3c67e7ba0acfde4df4e0bbd + + sha256: \"5b8a98dafc4d5c4c9c72d8b31ab2b23fc13422348d2997120294d3bac86b4ddb\" + url: \"https://pub.dev\" + source: hosted + - version: \"0.7.4\" + + version: \"0.7.2\" + typed_data: + dependency: transitive + description: + @@ -855,12 +866,11 @@ + usb_serial: + dependency: \"direct main\" + description: + - path: \".\" + - ref: fix-usbserial + - resolved-ref: \"9fcbacc92bec19ea02d33a40d9f39e45d19cf637\" + - url: \"https://github.com/Foxushka/usbserial.git\" + - source: git + - version: \"0.5.1\" + + name: usb_serial + + sha256: a605a600e34e7f28d4e80851ca3999ef747e42e406138887b8a88b8c382a8b07 + + url: \"https://pub.dev\" + + source: hosted + + version: \"0.5.2\" + uuid: + dependency: \"direct main\" + description: + @@ -881,10 +891,10 @@ + dependency: transitive + description: + name: vm_service + - sha256: \"0968250880a6c5fe7edc067ed0a13d4bae1577fe2771dcf3010d52c4a9d3ca14\" + + sha256: \"5c5f338a667b4c644744b661f309fb8080bb94b18a7e91ef1dbd343bed00ed6d\" + url: \"https://pub.dev\" + source: hosted + - version: \"14.3.1\" + + version: \"14.2.5\" + wakelock_plus: + dependency: \"direct main\" + description: + @@ -958,5 +968,5 @@ + source: hosted + version: \"2.2.1\" + sdks: + - dart: \">=3.7.0-0 <4.0.0\" + + dart: \">=3.5.0 <4.0.0\" + flutter: \">=3.24.0\" + ''; + in + builtins.fromJSON + ( + builtins.readFile (pkgs.runCommand "${self.pname}-buildenv" { + inputs = [ + # DEBUG (both lines commented) + #pkgs.flutter324 # ChameleonUltraGUI requires sdk >3.0.0 + #pkgs.yj + ]; + } '' + # copy source files to a temporary path to rebuild the lockfile + buildPath=$(mktemp -d) + cp -r "${appRoot}/." "$buildPath/" + + outPubspecLock="$buildPath/pubspec.lock" + # MUST define variables to use multiline Nix string in bash scripting + pubspecLockPatch="${pubspecLockPatch}" + + # apply the pubspec.yaml patch and regenerate lock file + # (create a temporary home directory for flutter to play in) + #(cd $buildPath && chmod -R +w . \ + # && patch ./pubspec.yaml <(echo "$pubspecYamlPatch") \ + # && export HOME=$(mktemp -d) \ + # && flutter --disable-analytics \ + # && flutter config --no-cli-animations \ + # && ${pkgs.flutter}/bin/flutter pub get) + + # patch the lockfile + chmod +w $outPubspecLock + patch $outPubspecLock <(echo "$pubspecLockPatch") + + # convert new lockfile to json and return + ${pkgs.yj}/bin/yj < "$buildPath/pubspec.lock" > $out + '') + ); + + # TODO: try this instead of patching + # gitHashes = { + # dartssh2 = "sha256-2pypKwurziwGLZYuGaxlS2lzN3UvJp3bRTvvYYxEqRI="; + # hotkey_manager_linux = "sha256-aO0h94YZvgV/ggVupNw8GjyZsnXrq3qTHRDtuhNv3oI="; + # system_info2 = "sha256-fly7E2vG+bQ/+QGzXk+DYba73RZccltdW2LpZGDKX60="; + # tray_menu = "sha256-riiAiBEms+9ARog8i+MR1fto1Yqx+gwbBWyNbNq6VTM="; + # window_size = "sha256-71PqQzf+qY23hTJvcm0Oye8tng3Asr42E2vfF1nBmVA="; + # xterm = "sha256-h8vIonTPUVnNqZPk/A4ZV7EYCMyM0rrErL9ZOMe4ZBE="; + # }; + + meta = with lib; { + description = "A GUI for the Chameleon Ultra written in Flutter for crossplatform"; + homepage = "https://github.com/GameTec-live/ChameleonUltraGUI"; + license = licenses.gpl3; + maintainers = [maintainers.emileclarkb]; + platforms = platforms.linux; + }; +}) +.overrideAttrs ( + previousAttrs: { + installPhase = + previousAttrs.installPhase + + '' + # create mipmaps of desktop logo + logoOriginal="assets/logo-color-desktop.png" + for i in 16 32 64 128 256 512; do + res="$i"x"$i" + logoOut="$out"/share/icons/hicolor/"$res"/apps + mkdir -p $logoOut + ${pkgs.imagemagick}/bin/magick $logoOriginal -resize $res $logoOut/${previousAttrs.pname}.png + done + ''; + } +) From 5a15c239cdb8c472df8a5c18e72eb03ae8783952 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 14 May 2025 10:45:30 +1000 Subject: [PATCH 013/197] various improvements to the "me" user home configuration also added multiple TODO items --- NEW_TODO | 2 -- PROBLEMLOG | 5 +++++ TODO | 15 ++++++++++----- TODO.LONG-TERM | 26 ++++++++++++++++++++++++++ TODO.SPECIFIC | 4 ++++ banner | 1 + homes/me/default.nix | 6 ++++++ homes/modules/bat.nix | 9 +++++++++ homes/modules/git.nix | 6 ++++++ homes/modules/term/ghostty.nix | 4 +++- 10 files changed, 70 insertions(+), 8 deletions(-) delete mode 100644 NEW_TODO create mode 100644 PROBLEMLOG create mode 100755 TODO.LONG-TERM create mode 100644 TODO.SPECIFIC create mode 100644 banner diff --git a/NEW_TODO b/NEW_TODO deleted file mode 100644 index b206852..0000000 --- a/NEW_TODO +++ /dev/null @@ -1,2 +0,0 @@ -- [ ] True using `gitHashes` argument instead of patching? - diff --git a/PROBLEMLOG b/PROBLEMLOG new file mode 100644 index 0000000..5b0e3a6 --- /dev/null +++ b/PROBLEMLOG @@ -0,0 +1,5 @@ +180GB of disk space were used by my system which seemed absurd. Running the NixOS +garbage collector only removed 7GB. The rest was found via: +`du -hs ./.local/share/Games/drive_c/Program\ Files\ \(x86\)/Steam/dumps/reports/*` +tldr: there were 2714 30MB crash report files generated every minute of May 2nd 2025 (10 days ago) + SOLUTION: delete them all and hope it doesn't happen again diff --git a/TODO b/TODO index 21efb53..46f6bdf 100644 --- a/TODO +++ b/TODO @@ -1,9 +1,14 @@ +SOON: fix having to keep specifying new sha256 for home-manager (where I fetchTarball for it) +THEN: make my nixdots more modular, there are a LOT of packages installed only to my laptop when they should be shared! + + Create a command palette accessible with MOD+P (MOD => Windows Key) (ie make fullscreen, send to monitor, etc) -Make each monitor's window styling slightly different (just for fun) -Bind 5 workspaces per connected monitor. - Then use the command palette (discussed prior) to send to - a different workspace (ie because I currently use MOD+SHIFT+n - but if n>=10 then it doesnt work! hence we need a command palette!) +Boring stuff (ie work and uni should go on a separate user account) + + + +INSPIRATION: +1. https://github.com/sabrehagen/desktop-environment diff --git a/TODO.LONG-TERM b/TODO.LONG-TERM new file mode 100755 index 0000000..e1acf2e --- /dev/null +++ b/TODO.LONG-TERM @@ -0,0 +1,26 @@ +Add a MAC Changer module like +https://github.com/XNM1/linux-nixos-hyprland-config-dotfiles/blob/main/nixos/mac-randomize.nix + +Really good security oriented NixOS stuff can be found on that repo above (XNM1/linux-nixos-hyprland-config-dotfiles) + + + +Have multiple colour schemes in my system, one that's dark (good for when there's no external lighting), +and another that's lighter (but not white) for when my windows are open). + + +### Incredible Rofi Theme Collection +https://github.com/adi1090x/rofi +https://jade.fyi/blog/flakes-arent-real/ + + + +Make each monitor's window styling slightly different (just for fun) + +Bind 5 workspaces per connected monitor. + Then use the command palette (discussed prior) to send to + a different workspace (ie because I currently use MOD+SHIFT+n + but if n>=10 then it doesnt work! hence we need a command palette!) + + + diff --git a/TODO.SPECIFIC b/TODO.SPECIFIC new file mode 100644 index 0000000..49ae64e --- /dev/null +++ b/TODO.SPECIFIC @@ -0,0 +1,4 @@ +- [ ] Try using `gitHashes` argument instead of patching? (on chameleonultragui package) +- [ ] Don't alias ripgrep to rip, download the rip util too (its cool) + https://github.com/nivekuil/rip + diff --git a/banner b/banner new file mode 100644 index 0000000..3b051d0 --- /dev/null +++ b/banner @@ -0,0 +1 @@ +Welcome weary traveller, to my shop... diff --git a/homes/me/default.nix b/homes/me/default.nix index 14e6d99..fb19f72 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -50,6 +50,12 @@ username = "me"; homeDirectory = "/home/me"; + shellAliases = { + rip = "rg"; # ripgrep + brip = "batgrep"; # bat + ripgrep + man = "batman"; # bat + man + }; + pointerCursor = { gtk.enable = true; # x11.enable = true # dont enable since im on hyprland diff --git a/homes/modules/bat.nix b/homes/modules/bat.nix index f29f49b..fca2231 100755 --- a/homes/modules/bat.nix +++ b/homes/modules/bat.nix @@ -12,4 +12,13 @@ theme = "Dracula"; }; }; + + # other commands that make normal utils prettier + home.packages = with pkgs.bat-extras; [ + batdiff + batgrep + batman + batwatch + prettybat + ]; } diff --git a/homes/modules/git.nix b/homes/modules/git.nix index c98ab4e..57b1e8f 100755 --- a/homes/modules/git.nix +++ b/homes/modules/git.nix @@ -5,6 +5,12 @@ }: { programs.git = { enable = true; + extraConfig = { + color.ui = true; + core.editor = "hx"; + github.user = "emileclarkb"; + }; + userName = "Emile Clark-Boman"; userEmail = "eclarkboman@gmail.com"; }; diff --git a/homes/modules/term/ghostty.nix b/homes/modules/term/ghostty.nix index 5eb2591..4c0b130 100644 --- a/homes/modules/term/ghostty.nix +++ b/homes/modules/term/ghostty.nix @@ -2,7 +2,6 @@ home = { packages = [ pkgs.ghostty - #(pkgs.writeShellScriptBin "xterm" ''${pkgs.ghostty}/bin/ghostty "$@"'') ]; sessionVariables.TERMINAL = "ghostty"; @@ -26,6 +25,9 @@ gtk-single-instance = false; adw-toolbar-style = "flat"; + # disable close confirmations + confirm-close-surface = false; + keybind = [ "ctrl+shift+plus=increase_font_size:1" "ctrl+shift+minus=decrease_font_size:1" From ba3f4f6f7b6309d69e1275d888576d7272013bb2 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 14 May 2025 10:48:27 +1000 Subject: [PATCH 014/197] installed gnumake and man pages for hosts --- hosts/lolcathost/default.nix | 11 ++++++++--- hosts/myputer/default.nix | 5 +++++ 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 6c3daa8..bfcc31a 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -5,7 +5,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz"; - sha256 = "1qsvg11b5d05z2gvxq2pp6xfg3gpcd363id0h52sicikx3vai93s"; + sha256 = "0gjfa3bv0m0kymxqla9iih11gjb6czyj942v34pyc7xy4qsx898k"; }; in { imports = [ @@ -232,9 +232,10 @@ in { zoxide doggo tldr - btop + # btop eza ripgrep + viddy # modern `watch` command # TODO: once upgraded past Nix-24.07 this line won't be necessary (I think) # helix will support nixd by default @@ -246,15 +247,19 @@ in { git-filter-repo brightnessctl acpi - upower + # upower vim powertop gcc + gnumake # Unix Commands wget tree unzip + # Man Pages + man-pages + man-pages-posix ]; # Enable the use of certain programs diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 78ddafb..27b6799 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -199,6 +199,7 @@ in { zoxide doggo tldr + viddy #btop tesseract # for my work with Agribit @@ -214,11 +215,15 @@ in { vim nix-prefetch-git gcc + gnumake # Unix Commands wget tree unzip + # Man Pages + man-pages + man-pages-posix # Cryptography openssl From 2bd0b967cb8a412391205898aba6515322c39827 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 1 Jul 2025 14:54:52 +1000 Subject: [PATCH 015/197] added various build artifacts for the tundra dev env --- hosts/packages/tundra/README | 12 + hosts/packages/tundra/flake.lock | 62 +++++ hosts/packages/tundra/flake.nix | 42 ++++ hosts/packages/tundra/src/app.in.vala | 31 +++ hosts/packages/tundra/src/meson.build | 47 ++++ hosts/packages/tundra/src/style.scss | 107 +++++++++ hosts/packages/tundra/src/widget/Bar.vala | 265 ++++++++++++++++++++++ 7 files changed, 566 insertions(+) create mode 100644 hosts/packages/tundra/README create mode 100644 hosts/packages/tundra/flake.lock create mode 100644 hosts/packages/tundra/flake.nix create mode 100644 hosts/packages/tundra/src/app.in.vala create mode 100644 hosts/packages/tundra/src/meson.build create mode 100644 hosts/packages/tundra/src/style.scss create mode 100644 hosts/packages/tundra/src/widget/Bar.vala diff --git a/hosts/packages/tundra/README b/hosts/packages/tundra/README new file mode 100644 index 0000000..e44647c --- /dev/null +++ b/hosts/packages/tundra/README @@ -0,0 +1,12 @@ +**Tundra** is the name I'm giving my *desktop environment.* +Made primarily with Aylur's Astal library and the Vala +programming language (as an excuse to learn it). + +NOTE: Tundra is designed specifically to work on Hyprland, +I have no idea how it'll interact with other window managers :) + + +##### Meson Notes (temporary) +Setup meson like `meson setup ` ie `meson setup build src`. +Compile meson like `meson compile -C ` where is the relative path to it, +if you're in it already just use `meson compile` otherwise if in project root use `meson compile build`. diff --git a/hosts/packages/tundra/flake.lock b/hosts/packages/tundra/flake.lock new file mode 100644 index 0000000..85ad9ef --- /dev/null +++ b/hosts/packages/tundra/flake.lock @@ -0,0 +1,62 @@ +{ + "nodes": { + "astal": { + "inputs": { + "nixpkgs": "nixpkgs" + }, + "locked": { + "lastModified": 1745934282, + "narHash": "sha256-hgUd4yUYALHzzoEi/88BnsgrxZIqk+zyQVoI3CL61IU=", + "owner": "aylur", + "repo": "astal", + "rev": "07583deff8a486fad472718572c3248f0fbea1f3", + "type": "github" + }, + "original": { + "owner": "aylur", + "repo": "astal", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1737469691, + "narHash": "sha256-nmKOgAU48S41dTPIXAq0AHZSehWUn6ZPrUKijHAMmIk=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "9e4d5190a9482a1fb9d18adf0bdb83c6e506eaab", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_2": { + "locked": { + "lastModified": 1746663147, + "narHash": "sha256-Ua0drDHawlzNqJnclTJGf87dBmaO/tn7iZ+TCkTRpRc=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "dda3dcd3fe03e991015e9a74b22d35950f264a54", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "astal": "astal", + "nixpkgs": "nixpkgs_2" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/hosts/packages/tundra/flake.nix b/hosts/packages/tundra/flake.nix new file mode 100644 index 0000000..b6e0a36 --- /dev/null +++ b/hosts/packages/tundra/flake.nix @@ -0,0 +1,42 @@ +{ + inputs = { + nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable"; + astal.url = "github:aylur/astal"; + }; + + outputs = { + self, + nixpkgs, + astal, + }: let + system = "x86_64-linux"; + pkgs = nixpkgs.legacyPackages.${system}; + in { + packages.${system} = { + default = pkgs.stdenv.mkDerivation { + name = "tundra"; + src = ./.; + + nativeBuildInputs = with pkgs; [ + meson + ninja + pkg-config + vala + gobject-introspection + dart-sass + ]; + + buildInputs = [ + astal.packages.${system}.io + astal.packages.${system}.astal3 + astal.packages.${system}.battery + astal.packages.${system}.wireplumber + astal.packages.${system}.network + astal.packages.${system}.tray + astal.packages.${system}.mpris + astal.packages.${system}.hyprland + ]; + }; + }; + }; +} diff --git a/hosts/packages/tundra/src/app.in.vala b/hosts/packages/tundra/src/app.in.vala new file mode 100644 index 0000000..b3da69e --- /dev/null +++ b/hosts/packages/tundra/src/app.in.vala @@ -0,0 +1,31 @@ +class App : Astal.Application { + public static App instance; + + public override void request (string msg, SocketConnection conn) { + print(@"$msg\n"); + AstalIO.write_sock.begin(conn, "ok"); + } + + public override void activate () { + foreach (var mon in this.monitors) + add_window(new Bar(mon)); + + apply_css("@STYLE@"); + } + + public static void main(string[] args) { + var instance_name = "vala"; + + App.instance = new App() { + instance_name = instance_name + }; + + try { + App.instance.acquire_socket(); + App.instance.run(null); + } catch (Error err) { + print(AstalIO.send_request(instance_name, string.joinv(" ", args))); + } + } +} + diff --git a/hosts/packages/tundra/src/meson.build b/hosts/packages/tundra/src/meson.build new file mode 100644 index 0000000..1cc6b10 --- /dev/null +++ b/hosts/packages/tundra/src/meson.build @@ -0,0 +1,47 @@ +project('tundra', 'vala', 'c') + +bindir = get_option('prefix') / get_option('bindir') +# bindir = './bin' +libdir = get_option('prefix') / get_option('libdir') + +pkgconfig_deps = [ + dependency('glib-2.0'), + dependency('gobject-2.0'), + dependency('gtk+-3.0'), + dependency('libnm'), + dependency('astal-io-0.1'), + dependency('astal-3.0'), + dependency('astal-battery-0.1'), + dependency('astal-wireplumber-0.1'), + dependency('astal-network-0.1'), + dependency('astal-tray-0.1'), + dependency('astal-mpris-0.1'), + dependency('astal-hyprland-0.1'), +] + +# needed for GLib.Math +deps = pkgconfig_deps + meson.get_compiler('c').find_library('m') + +main = configure_file( + input: 'app.in.vala', + output: 'app.vala', + configuration: { + 'STYLE': run_command( + find_program('sass'), + meson.project_source_root() / 'style.scss', + ).stdout(), + }, +) + +sources = files( + 'widget/Bar.vala', +) + +executable( + 'tundra', + [sources, main], + dependencies: deps, + install: true, + install_dir: bindir, +) + diff --git a/hosts/packages/tundra/src/style.scss b/hosts/packages/tundra/src/style.scss new file mode 100644 index 0000000..5c20382 --- /dev/null +++ b/hosts/packages/tundra/src/style.scss @@ -0,0 +1,107 @@ +@use "sass:color"; + +$bg: #212223; +$fg: #f1f1f1; +$accent: #378DF7; +$radius: 7px; + +window.Bar { + border: none; + box-shadow: none; + background-color: $bg; + color: $fg; + font-size: 1.1em; + font-weight: bold; + + label { + margin: 0 8px; + } + + .Workspaces { + button { + all: unset; + background-color: transparent; + + &:hover label { + background-color: color.adjust($fg, $alpha: -0.84); + border-color: color.adjust($accent, $alpha: -0.8); + } + + &:active label { + background-color: color.adjust($fg, $alpha: -0.8) + } + } + + label { + transition: 200ms; + padding: 0 8px; + margin: 2px; + border-radius: $radius; + border: 1pt solid transparent; + } + + .focused label { + color: $accent; + border-color: $accent; + } + } + + .SysTray { + margin-right: 8px; + + button { + padding: 0 4px; + } + } + + .FocusedClient { + color: $accent; + } + + .Media .Cover { + min-height: 1.2em; + min-width: 1.2em; + border-radius: $radius; + background-position: center; + background-size: contain; + } + + .Battery label { + padding-left: 0; + margin-left: 0; + } + + .AudioSlider { + * { + all: unset; + } + + icon { + margin-right: .6em; + } + + & { + margin: 0 1em; + } + + trough { + background-color: color.adjust($fg, $alpha: -0.8); + border-radius: $radius; + } + + highlight { + background-color: $accent; + min-height: .8em; + border-radius: $radius; + } + + slider { + background-color: $fg; + border-radius: $radius; + min-height: 1em; + min-width: 1em; + margin: -.2em; + } + } +} + diff --git a/hosts/packages/tundra/src/widget/Bar.vala b/hosts/packages/tundra/src/widget/Bar.vala new file mode 100644 index 0000000..f1ba8eb --- /dev/null +++ b/hosts/packages/tundra/src/widget/Bar.vala @@ -0,0 +1,265 @@ +class Workspaces : Gtk.Box { + AstalHyprland.Hyprland hypr = AstalHyprland.get_default(); + public Workspaces() { + Astal.widget_set_class_names(this, {"Workspaces"}); + hypr.notify["workspaces"].connect(sync); + sync(); + } + + void sync() { + foreach (var child in get_children()) + child.destroy(); + + // TODO: create a copy of workspaces + // then create a list of tuples (map id to index in hypr.workspaces) + // then sort new list by id + // then iterate and use index on hypr.workspaces + // NEVERMIND: read `lib/hyprland/hyprland.vala` and see how the + // `_workspaces` property is defined as a HashTable + // basically just extend on that / create a wrapper + // that allows better organisation + + hypr.workspaces.sort((a, b) => { return a.id - b.id; }); + foreach (var ws in hypr.workspaces) { + // filter out special workspaces + if (!(ws.id >= -99 && ws.id <= -2)) { + add(button(ws)); + } + } + } + + Gtk.Button button(AstalHyprland.Workspace ws) { + var btn = new Gtk.Button() { + visible = true, + label = ws.id.to_string() + }; + + hypr.notify["focused-workspace"].connect(() => { + var focused = hypr.focused_workspace == ws; + if (focused) { + Astal.widget_set_class_names(btn, {"focused"}); + } else { + Astal.widget_set_class_names(btn, {}); + } + }); + + btn.clicked.connect(ws.focus); + return btn; + } +} + +class FocusedClient : Gtk.Box { + public FocusedClient() { + Astal.widget_set_class_names(this, {"Focused"}); + AstalHyprland.get_default().notify["focused-client"].connect(sync); + sync(); + } + + void sync() { + foreach (var child in get_children()) + child.destroy(); + + var client = AstalHyprland.get_default().focused_client; + if (client == null) + return; + + var label = new Gtk.Label(client.title) { visible = true }; + client.bind_property("title", label, "label", BindingFlags.SYNC_CREATE); + add(label); + } +} + +class Media : Gtk.Box { + AstalMpris.Mpris mpris = AstalMpris.get_default(); + + public Media() { + Astal.widget_set_class_names(this, {"Media"}); + mpris.notify["players"].connect(sync); + sync(); + } + + void sync() { + foreach (var child in get_children()) + child.destroy(); + + if (mpris.players.length() == 0) { + add(new Gtk.Label("Nothing Playing")); + return; + } + + var player = mpris.players.nth_data(0); + var label = new Gtk.Label(null); + var cover = new Gtk.Box(Gtk.Orientation.HORIZONTAL, 0) { + valign = Gtk.Align.CENTER + }; + + Astal.widget_set_class_names(cover, {"Cover"}); + player.bind_property("metadata", label, "label", BindingFlags.SYNC_CREATE, (_, src, ref trgt) => { + var title = player.title; + var artist = player.artist; + trgt.set_string(@"$artist - $title"); + return true; + }); + + var id = player.notify["cover-art"].connect(() => { + var art = player.cover_art; + Astal.widget_set_css(cover, @"background-image: url('$art')"); + }); + + cover.destroy.connect(() => player.disconnect(id)); + add(cover); + add(label); + } +} + +class SysTray : Gtk.Box { + HashTable items = new HashTable(str_hash, str_equal); + AstalTray.Tray tray = AstalTray.get_default(); + + public SysTray() { + Astal.widget_set_class_names(this, { "SysTray" }); + tray.item_added.connect(add_item); + tray.item_removed.connect(remove_item); + } + + void add_item(string id) { + if (items.contains(id)) + return; + + var item = tray.get_item(id); + var btn = new Gtk.MenuButton() { use_popover = false, visible = true }; + var icon = new Astal.Icon() { visible = true }; + + item.bind_property("tooltip-markup", btn, "tooltip-markup", BindingFlags.SYNC_CREATE); + item.bind_property("gicon", icon, "gicon", BindingFlags.SYNC_CREATE); + item.bind_property("menu-model", btn, "menu-model", BindingFlags.SYNC_CREATE); + btn.insert_action_group("dbusmenu", item.action_group); + item.notify["action-group"].connect(() => { + btn.insert_action_group("dbusmenu", item.action_group); + }); + + btn.add(icon); + add(btn); + items.set(id, btn); + } + + void remove_item(string id) { + if (items.contains(id)) { + items.remove(id); + } + } +} + +class Wifi : Astal.Icon { + public Wifi() { + Astal.widget_set_class_names(this, {"Wifi"}); + var wifi = AstalNetwork.get_default().wifi; + // var wifi = AstalNetwork.get_default().get_wifi(); + if (wifi != null) { + wifi.bind_property("ssid", this, "tooltip-text", BindingFlags.SYNC_CREATE); + wifi.bind_property("icon-name", this, "icon", BindingFlags.SYNC_CREATE); + } + } +} + +class AudioSlider : Gtk.Box { + Astal.Icon icon = new Astal.Icon(); + Astal.Slider slider = new Astal.Slider() { hexpand = true }; + + public AudioSlider() { + add(icon); + add(slider); + Astal.widget_set_class_names(this, {"AudioSlider"}); + Astal.widget_set_css(this, "min-width: 140px"); + + var speaker = AstalWp.get_default().audio.default_speaker; + speaker.bind_property("volume-icon", icon, "icon", BindingFlags.SYNC_CREATE); + speaker.bind_property("volume", slider, "value", BindingFlags.SYNC_CREATE); + slider.dragged.connect(() => speaker.volume = slider.value); + } +} + +class Battery : Gtk.Box { + Astal.Icon icon = new Astal.Icon(); + Astal.Label label = new Astal.Label(); + + public Battery() { + add(icon); + add(label); + Astal.widget_set_class_names(this, {"Battery"}); + + var bat = AstalBattery.get_default(); + bat.bind_property("is-present", this, "visible", BindingFlags.SYNC_CREATE); + bat.bind_property("battery-icon-name", icon, "icon", BindingFlags.SYNC_CREATE); + bat.bind_property("percentage", label, "label", BindingFlags.SYNC_CREATE, (_, src, ref trgt) => { + var p = Math.floor(src.get_double() * 100); + trgt.set_string(@"$p%"); + return true; + }); + } +} + +class Time : Astal.Label { + string format; + AstalIO.Time interval; + + void sync() { + label = new DateTime.now_local().format(format); + } + + public Time(string format = "%H:%M - %A %e.") { + this.format = format; + interval = AstalIO.Time.interval(1000, null); + interval.now.connect(sync); + destroy.connect(interval.cancel); + Astal.widget_set_class_names(this, {"Time"}); + } +} + +class Left : Gtk.Box { + public Left() { + Object(hexpand: true, halign: Gtk.Align.START); + add(new Workspaces()); + add(new FocusedClient()); + } +} + +class Center : Gtk.Box { + public Center() { + add(new Media()); + } +} + +class Right : Gtk.Box { + public Right() { + Object(hexpand: true, halign: Gtk.Align.END); + add(new SysTray()); + add(new Wifi()); + add(new AudioSlider()); + add(new Battery()); + add(new Time()); + } +} + +class Bar : Astal.Window { + public Bar(Gdk.Monitor monitor) { + Object( + anchor: Astal.WindowAnchor.TOP + | Astal.WindowAnchor.LEFT + | Astal.WindowAnchor.RIGHT, + exclusivity: Astal.Exclusivity.EXCLUSIVE, + gdkmonitor: monitor + ); + + Astal.widget_set_class_names(this, {"Bar"}); + + add(new Astal.CenterBox() { + start_widget = new Left(), + center_widget = new Center(), + end_widget = new Right(), + }); + + show_all(); + } +} + From 54ecb45922424a6f3b2a9f769b232af715ea271c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 1 Jul 2025 14:55:10 +1000 Subject: [PATCH 016/197] added support for c, nim, and sage --- homes/modules/editor/helix.nix | 9 +++++++++ hosts/lolcathost/default.nix | 10 +++++++++- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/homes/modules/editor/helix.nix b/homes/modules/editor/helix.nix index 52c629a..555ec75 100755 --- a/homes/modules/editor/helix.nix +++ b/homes/modules/editor/helix.nix @@ -129,6 +129,11 @@ auto-format = false; # my python is beautiful ^_^ rulers = [80]; } + { + name = "c"; + formatter.command = "${pkgs.clang-tools}/bin/clang-format"; + language-servers = ["clangd"]; + } ]; language-server = { @@ -138,6 +143,10 @@ nixd = { command = "${pkgs.nixd}/bin/nixd"; }; + # clangd for C + clangd = { + command = "${pkgs.clang-tools}/bin/clangd"; + }; }; }; }; diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index bfcc31a..95118e0 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -215,8 +215,16 @@ in { # dependencies for my sddm theme: pkgs.libsForQt5.qt5.qtgraphicaleffects - python311 # I use 3.11 since it's in a pretty stable state now + python312 # I use 3.12 since it's in a pretty stable state now + python314 # also 3.14 for latest features poetry # python dependency management and packaging + clang-tools + + nim-2_2 + nimble + # nimlangserver # FUCK THIS LSP, ITS AWFUL WITH HELIX + + sageWithDoc # SageMath + HTML Documentation # DEBUG: using neofetch temporarily to see if my system upgrades properly neofetch From 5cd5ca4987de580d096f7417d5b48544bc101dbf Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 6 Jul 2025 19:18:14 +1000 Subject: [PATCH 017/197] Added like 3 new userspace packages --- hosts/lolcathost/default.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 95118e0..e9805da 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -210,6 +210,7 @@ in { ani-cli wl-clipboard # clipboard for wayland pavucontrol + qbittorrent # torrenting (callPackage ../sddm-theme-corners.nix {}).sddm-theme-corners # dependencies for my sddm theme: @@ -260,11 +261,13 @@ in { powertop gcc gnumake + imagemagick # Unix Commands wget tree unzip + unrar-free # Man Pages man-pages man-pages-posix From f98b3fd945f90040649dde8491e1ee1f944acf34 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 7 Jul 2025 00:40:45 +1000 Subject: [PATCH 018/197] Removed old comments from home declaration --- homes/me/default.nix | 116 +----------------------------------------- homes/modules/obs.nix | 16 ++++++ 2 files changed, 17 insertions(+), 115 deletions(-) create mode 100755 homes/modules/obs.nix diff --git a/homes/me/default.nix b/homes/me/default.nix index fb19f72..5eb2d90 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -6,6 +6,7 @@ pkgs, ... }: { + # TODO: unset this nixpkgs = { config.allowUnfree = true; }; @@ -29,29 +30,11 @@ ../modules/ags ]; - /* - programs.spicetify = - let - spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system}; - in - { - enable = true; - enabledExtensions = with spicePkgs.extensions; [ - adblock - hidePodcasts - shuffle # shuffle+ (special characters are sanitized out of extension names) - ]; - theme = spicePkgs.themes.catppuccin; - colorScheme = "mocha"; - }; - */ - home = { username = "me"; homeDirectory = "/home/me"; shellAliases = { - rip = "rg"; # ripgrep brip = "batgrep"; # bat + ripgrep man = "batman"; # bat + man }; @@ -79,15 +62,12 @@ # TODO: use a variable to mirror this cursor size # with the `home.pointerCurser.size` cursorTheme = { - # dont set the theme (use system default instead) - # only set size to match the system package = pkgs.bibata-cursors; name = "Bibata-Modern-Ice"; size = 16; }; }; - # TODO: this lowkey doesnt work... (maybe the name "Dracula" is wrong?) qt = { enable = true; platformTheme.name = "gtk2"; @@ -98,16 +78,6 @@ # these are both required for home-manager to work home-manager.enable = true; - # DEBUG: testing if my xdg-desktop-portal-hyprland is working or not - obs-studio = { - enable = false; - plugins = with pkgs.obs-studio-plugins; [ - wlrobs - obs-backgroundremoval - obs-pipewire-audio-capture - ]; - }; - # set ssh profiles # (all we need is hyrule, everything else is through wishlist) # NOTE: (IMPORTANT) this DOES NOT start the ssh-agent @@ -153,93 +123,9 @@ }; }; }; - - /* - hyprpanel = { - enable = true; - # automatically restart when config changes - systemd.enable = true; # TODO: change to false - # add `exec-once hyprpanel` to hyprland config - hyprland.enable = true; - - # fix the overwrite issue with hyprpanel on NixOS - overwrite.enable = true; - - # import a theme from './themes/*.json' - # theme = ""; - - # override the final config - #override = {}; - - # config the bar layouts for monitors - layout = { - "bar.layouts" = { - "0" = { - left = ["dashboard" "workspaces"]; - middle = ["media"]; - right = ["volume" "systray" "notifications"]; - }; - }; - }; - - # settings = { - # bar.launcher.autoDetectIcon = true; - # bar.workspaces.show_icons = true; - # - # menus.clock = { - # time = { - # military = true; - # hideSeconds = true; - # }; - # weather.unit = "metric"; - # }; - # - # menus.dashboard.directories.enabled = false; - # menus.dashboard.stats.enable_gpu = true; - # - # theme.bar.transparent = true; - # - # theme.font = { - # name = "CaskaydiaCove NF"; - # size = "16px"; - # }; - # }; - }; - */ - - # I want to use fish as my login shell but it always - # goes terrible cause it isn't POSIX compliant, so - # instead Bash is my login and it will just exec fish - #bash = { - # interactiveShellInit = '' - # if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]] - # then - # shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION="" - # exec ${pkgs.fish}/bin/fish $LOGIN_OPTION - # fi - # ''; - #}; - - /* - spicetify = - let - spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system}; - in - { - enable = true; - enabledExtensions = with spicePkgs.extensions; [ - adblock - hidePodcasts - #shuffle - ]; - theme = spicePkgs.themes.catppuccin; - colorScheme = "mocha"; - }; - */ }; # enable OpenSSH private key agent - services.ssh-agent.enable = true; # the ssh-agent won't set this for itself... systemd.user.sessionVariables.SSH_AUTH_SOCK = "$XDG_RUNTIME_DIR/ssh-agent"; diff --git a/homes/modules/obs.nix b/homes/modules/obs.nix new file mode 100755 index 0000000..37db38f --- /dev/null +++ b/homes/modules/obs.nix @@ -0,0 +1,16 @@ +{ + config, + pkgs, + ... +}: { + programs = { + obs-studio = { + enable = true; + plugins = with pkgs.obs-studio-plugins; [ + wlrobs + obs-backgroundremoval + obs-pipewire-audio-capture + ]; + }; + }; +} From cd56f7af9377a962813d449fb86b688c03dba558 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 7 Jul 2025 00:41:15 +1000 Subject: [PATCH 019/197] Removed host "imbored" --- hosts/imbored/default.nix | 87 --------------------------------------- 1 file changed, 87 deletions(-) delete mode 100755 hosts/imbored/default.nix diff --git a/hosts/imbored/default.nix b/hosts/imbored/default.nix deleted file mode 100755 index c5df73c..0000000 --- a/hosts/imbored/default.nix +++ /dev/null @@ -1,87 +0,0 @@ -{ - pkgs, - inputs, - lib, - ... -}: let - home-manager = builtins.fetchTarball { - url = "https://github.com/nix-community/home-manager/archive/master.tar.gz"; - sha256 = "19w63qccz78v0spx03911z98w1bvlxvd07hb0ma14a4vdzi4ninj"; - }; -in { - # TODO: - # - add github:charmbracelet/soft-serve - # - add forgejo - - imports = [ - ../modules/server/nginx.nix - ../modules/server/ssh.nix - ../modules/server/fail2ban.nix - ]; - - system.stateVersion = "24.05"; - nix.settings.experimental-features = [ - "nix-command" - "flakes" - ]; - - time.timeZone = "Australia/Brisbane"; - - i18n.defaultLocale = "en_US.UTF-8"; - console = { - font = "Lat2-Terminus16"; - keyMap = "us"; - }; - - boot.loader = { - # TODO - }; - - networking = { - hostName = "imbored"; - networkmanager.enable = true; - firewall.allowedTCPPorts = [ - 22 # sshd - ]; - }; - - users = { - defaultUserShell = pkgs.bash; - - users = { - # primary user - dev = { - isNormalUser = true; - extraGroups = ["wheel"]; - shell = pkgs.bash; - packages = with pkgs; [ - ]; - }; - - # user for friends to ssh into - friends = { - isNormalUser = true; - shell = pkgs.bash; - packages = with pkgs; [ - ]; - }; - }; - }; - - #home-manager = { - # users = { - # dev = import ../../homes/dev; - # friends = import ../../homes/friends; - # }; - #}; - - environment.SystemPackages = with pkgs; [ - btop - ]; - - programs = { - bash = { - completion.enable = true; - }; - }; -} From 45ad6da23c1faa6b88e9ca6cbe0e31a3f442dbdf Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 7 Jul 2025 17:19:21 +1000 Subject: [PATCH 020/197] VC setup hook now runs during initrd init phase --- hosts/lolcathost/default.nix | 28 ++++++++++++++++++++++++---- hosts/myputer/default.nix | 3 +-- 2 files changed, 25 insertions(+), 6 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index e9805da..b788661 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -59,12 +59,32 @@ in { # Select internationalisation properties. i18n.defaultLocale = "en_US.UTF-8"; + # Enable initrd hook for virtual console customisation + # aka cool colours when bootting yay!! console = { - font = "Lat2-Terminus16"; + enable = true; + earlySetup = true; # initrd pre hook keyMap = "us"; - #packages = with pkgs; [ - # nerdfonts - #]; + font = "Lat2-Terminus16"; + # ANSI 24-bit color definitions (theme: dracula) + colors = [ + "21222c" + "ff5555" + "50fa7b" + "f1fa8c" + "bd93f9" + "ff79c6" + "8be9fd" + "f8f8f2" + "6272a4" + "ff6e6e" + "69ff94" + "ffffa5" + "d6acff" + "ff92df" + "a4ffff" + "ffffff" + ]; }; # ----- NETWORKING SECTION ----- diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 27b6799..a666027 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -200,7 +200,6 @@ in { doggo tldr viddy - #btop tesseract # for my work with Agribit @@ -289,7 +288,7 @@ in { ''; }; - # Thunar also users: `services.tumbler` & `services.gvfs` + # Thunar also (optionally) requires: `services.tumbler` & `services.gvfs` thunar = { enable = true; plugins = with pkgs.xfce; [ From fac296efb8c298e71f2bb23473ac041a2a88d445 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 7 Jul 2025 17:19:39 +1000 Subject: [PATCH 021/197] Added some sectools --- hosts/lolcathost/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index b788661..6eb1fa8 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -253,6 +253,13 @@ in { openvpn inetutils + # security tools + rustscan + nmap + dig + nslookup + gobuster + # fish plugins grc # colorise command outputs From 832b25183b8105e3a0f16eb136faf0a68d3eb18b Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 7 Jul 2025 17:24:49 +1000 Subject: [PATCH 022/197] Fixed duplication, bin/nslookup is already in nixpkgs.dig --- hosts/lolcathost/default.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 6eb1fa8..f6e9c4c 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -257,7 +257,6 @@ in { rustscan nmap dig - nslookup gobuster # fish plugins From 852d2232b07ba2e3f33a264b121957d73d040d32 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 7 Jul 2025 17:54:03 +1000 Subject: [PATCH 023/197] Adds Name-That-Hash by @bee-san --- hosts/lolcathost/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index f6e9c4c..6a59b06 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -258,6 +258,7 @@ in { nmap dig gobuster + nth # fish plugins grc # colorise command outputs From 78880c5af26d9919ed03f37c1b1b856c35bea2c7 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 7 Jul 2025 18:00:58 +1000 Subject: [PATCH 024/197] Adds the bin/file command (why have I never downloaded this??) --- hosts/lolcathost/default.nix | 1 + hosts/myputer/default.nix | 1 + 2 files changed, 2 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 6a59b06..05cdd83 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -291,6 +291,7 @@ in { imagemagick # Unix Commands + file wget tree unzip diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index a666027..4cd836c 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -217,6 +217,7 @@ in { gnumake # Unix Commands + file wget tree unzip From ee70819b3ffe68e53e836c24e8f8e74b586ffc73 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 7 Jul 2025 22:38:59 +1000 Subject: [PATCH 025/197] Adds Zed Attack Proxy to security tooling --- deploy | 2 ++ hosts/lolcathost/default.nix | 1 + 2 files changed, 3 insertions(+) diff --git a/deploy b/deploy index 9e2f02e..c1a88cb 100755 --- a/deploy +++ b/deploy @@ -1,6 +1,8 @@ #!/usr/bin/env bash set -e +# TODO: use `nixos-rebuild build-vm` + usage="Usage: $(basename $0) [OPTIONS] Options: diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 05cdd83..a2f4d2f 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -259,6 +259,7 @@ in { dig gobuster nth + zap # fish plugins grc # colorise command outputs From dab56acd19a99ee8c583b9c58987663aeb856d85 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 7 Jul 2025 22:39:26 +1000 Subject: [PATCH 026/197] Fix git init defaults to branch name "master" (now: "main") --- homes/modules/git.nix | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/homes/modules/git.nix b/homes/modules/git.nix index 57b1e8f..3e0cfb0 100755 --- a/homes/modules/git.nix +++ b/homes/modules/git.nix @@ -9,6 +9,18 @@ color.ui = true; core.editor = "hx"; github.user = "emileclarkb"; + + init = { + defaultBranch = "main"; + }; + url = { + "https://github.com/" = { + insteadOf = [ + "gh:" + "github:" + ]; + }; + }; }; userName = "Emile Clark-Boman"; From 5988687e757dd3c65c853bd1b80ad5f4328f58ce Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 10 Jul 2025 21:51:07 +1000 Subject: [PATCH 027/197] Adds bluetooth support to laptop --- hosts/lolcathost/default.nix | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index a2f4d2f..0df5a17 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -111,7 +111,6 @@ in { }; # Enable sound - #hardware.pulseaudio.enable = false; pipewire = { enable = true; wireplumber.enable = true; @@ -228,6 +227,7 @@ in { helvum easyeffects ani-cli + bluetui wl-clipboard # clipboard for wayland pavucontrol qbittorrent # torrenting @@ -273,6 +273,7 @@ in { eza ripgrep viddy # modern `watch` command + thefuck # TODO: once upgraded past Nix-24.07 this line won't be necessary (I think) # helix will support nixd by default @@ -291,13 +292,12 @@ in { gnumake imagemagick - # Unix Commands + # "Standard" Unix Commands file wget tree unzip unrar-free - # Man Pages man-pages man-pages-posix ]; @@ -400,6 +400,11 @@ in { # driSupport = true; # driSupport32Bit = true; # } + + bluetooth = { + enable = true; + powerOnBoot = true; + }; }; # DO NOT MODIFY From 142dad8f688494bd92c9d02b473418dff46cbee6 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 10 Jul 2025 21:57:46 +1000 Subject: [PATCH 028/197] Computer now has VC modified by initrd --- hosts/myputer/default.nix | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 4cd836c..ad2cec1 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -54,9 +54,32 @@ in { # Select internationalisation properties. i18n.defaultLocale = "en_US.UTF-8"; + # Enable initrd hook for virtual console customisation + # aka cool colours when bootting yay!! console = { - font = "Lat2-Terminus16"; + enable = true; + earlySetup = true; # initrd pre hook keyMap = "us"; + font = "Lat2-Terminus16"; + # ANSI 24-bit color definitions (theme: dracula) + colors = [ + "21222c" + "ff5555" + "50fa7b" + "f1fa8c" + "bd93f9" + "ff79c6" + "8be9fd" + "f8f8f2" + "6272a4" + "ff6e6e" + "69ff94" + "ffffa5" + "d6acff" + "ff92df" + "a4ffff" + "ffffff" + ]; }; # ----- NETWORKING SECTION ----- From 4b03d162c7affe0dc4a6a1b9acf9bc27c76161e6 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 10 Jul 2025 23:47:59 +1000 Subject: [PATCH 029/197] Added bluetooth support to PC --- hosts/myputer/default.nix | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index ad2cec1..4313abb 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -7,7 +7,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz"; - sha256 = "1dga3vsd60v9mfyhwgbil13mrchw5crbpgh4zjw9fghv1vyk89vq"; + sha256 = "1mwq9mzyw1al03z4q2ifbp6d0f0sx9f128xxazwrm62z0rcgv4na"; }; in { imports = [ @@ -200,6 +200,7 @@ in { easyeffects pavucontrol ani-cli + bluetui wl-clipboard # clipboard for wayland hyprpicker @@ -384,6 +385,11 @@ in { # Enable OpenGL hardware = { graphics.enable = true; + + bluetooth = { + enable = true; + powerOnBoot = true; + }; }; # DO NOT MODIFY From abed1dec09837639a94b139fa1699ab2ec56204a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 10 Jul 2025 23:48:11 +1000 Subject: [PATCH 030/197] Added Steam and a couple cool games to the PC --- hosts/myputer/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 4313abb..337501f 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -14,6 +14,8 @@ in { ./hardware-configuration.nix (import "${home-manager}/nixos") inputs.spicetify-nix.nixosModules.default + + ../modules/steam.nix ]; programs.spicetify = let @@ -252,6 +254,11 @@ in { # Cryptography openssl libargon2 + + # Games + mindustry-wayland + dwarf-fortress + nethack ]; # DEBUG: configuring xdg portal here instead? From 71176846d648cfaff9a11ba366f8deba2677820f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 12 Jul 2025 16:58:29 +1000 Subject: [PATCH 031/197] Adds mindustry, dwarf-fortress, and minecraft --- hosts/lolcathost/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 0df5a17..a9616a3 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -300,6 +300,11 @@ in { unrar-free man-pages man-pages-posix + + # Games + mindustry + dwarf-fortress + prismlauncher # minecraft ]; # Enable the use of certain programs From 6ccfdadeb5370d70eae20b2d78093c42ad18133a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:19:15 +1000 Subject: [PATCH 032/197] Progress nixpkgs to 25.05 Update nerdfont naming convention accordingly --- flake.lock | 8 ++++---- flake.nix | 3 +-- hosts/lolcathost/default.nix | 34 +++++++++++++++++++--------------- hosts/myputer/default.nix | 2 +- 4 files changed, 25 insertions(+), 22 deletions(-) diff --git a/flake.lock b/flake.lock index 9e28c75..72a6d80 100755 --- a/flake.lock +++ b/flake.lock @@ -592,16 +592,16 @@ }, "nixpkgs_8": { "locked": { - "lastModified": 1739357830, - "narHash": "sha256-9xim3nJJUFbVbJCz48UP4fGRStVW5nv4VdbimbKxJ3I=", + "lastModified": 1752620740, + "narHash": "sha256-f3pO+9lg66mV7IMmmIqG4PL3223TYMlnlw+pnpelbss=", "owner": "nixos", "repo": "nixpkgs", - "rev": "0ff09db9d034a04acd4e8908820ba0b410d7a33a", + "rev": "32a4e87942101f1c9f9865e04dc3ddb175f5f32e", "type": "github" }, "original": { "owner": "nixos", - "ref": "nixos-24.11", + "ref": "nixos-25.05", "repo": "nixpkgs", "type": "github" } diff --git a/flake.nix b/flake.nix index e31b8ac..85323f7 100755 --- a/flake.nix +++ b/flake.nix @@ -2,8 +2,7 @@ description = "Emile's Nix Dotfiles"; inputs = { - # nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05"; - nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11"; + nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05"; #home-manager = { # url = "github:nix-community/home-manager"; diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index a9616a3..2f99758 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -4,8 +4,8 @@ ... }: let home-manager = builtins.fetchTarball { - url = "https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz"; - sha256 = "0gjfa3bv0m0kymxqla9iih11gjb6czyj942v34pyc7xy4qsx898k"; + url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; + sha256 = "0z94i2ig7wcm63fp1wkpp6r4458g2bj3r7ijlfapxihqybpgvng5"; }; in { imports = [ @@ -351,20 +351,24 @@ in { # ----- FONTS ----- fonts = { enableDefaultPackages = true; # no clue what this line does tbh - packages = with pkgs; [ - #(nerdfonts.override { - # fonts = [ - # "Cousine" - # "Iosevka" - # "JetBrainsMono" - # ]; - # }) - nerdfonts - geist-font # for my hyprlock theme + packages = with pkgs; + [ + #(nerdfonts.override { + # fonts = [ + # "Cousine" + # "Iosevka" + # "JetBrainsMono" + # ]; + # }) + # nerdfonts + geist-font # for my hyprlock theme - # texlive maintains a noto-emoji flake - texlivePackages.noto-emoji - ]; + # texlive maintains a noto-emoji flake + texlivePackages.noto-emoji + ] + ++ builtins.filter lib.attrsets.isDerivation ( + builtins.attrValues pkgs.nerd-fonts + ); # TODO: change my default fonts fontconfig = { diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 337501f..59e350c 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -7,7 +7,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz"; - sha256 = "1mwq9mzyw1al03z4q2ifbp6d0f0sx9f128xxazwrm62z0rcgv4na"; + sha256 = "0z94i2ig7wcm63fp1wkpp6r4458g2bj3r7ijlfapxihqybpgvng5"; }; in { imports = [ From 58065c0478e170fc63389a8d32f46e8efa5c4e79 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:19:39 +1000 Subject: [PATCH 033/197] Added helper script for analyzing simple errors --- huhh.sh | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100755 huhh.sh diff --git a/huhh.sh b/huhh.sh new file mode 100755 index 0000000..5dbcc81 --- /dev/null +++ b/huhh.sh @@ -0,0 +1,18 @@ +#!/usr/bin/env bash + +EXPR_MSG="evaluating derivation" +PROP_MSG="of derivation" + +LOC=$1 +if [ -z $1 ]; then + exec {1}<>"$LOC" +fi + +ERROR_LINE=$(<$LOC grep -nF "error:" \ + | tail -n1 \ + | awk '{print substr($1,1,length($1)-1)}' ) +<$LOC sed -n "$ERROR_LINE,\$p" + +echo "[*] Reason:" +<$LOC grep "evaluating attribute '.*' of derivation" \ + | awk '{ print substr($NF, 2, length($NF)-2), substr($5, 2, length($5)-2)}' From 0762e2fba6c6e9a8b020d99aab52489e2847a6bd Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:20:20 +1000 Subject: [PATCH 034/197] Added GUIDE markdown file --- GUIDE | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 GUIDE diff --git a/GUIDE b/GUIDE new file mode 100644 index 0000000..90a70b8 --- /dev/null +++ b/GUIDE @@ -0,0 +1,18 @@ +### Migrate to a Newer Version of Nixpkgs +```bash +# Determine the channel name you're using +nix-channel --list +nix-channel --remove +nix-channel --add # ie https://nixos.org/channels/nixos-25.05 +nix-channel --update + +# Now upgrade system profile (log to file in case of failure) +nixos-rebuild boot --upgrade | tee rebuild.log +``` + +### Finding New Things to Do +`man 5 configuration.nix` is incredibly useful + similar info can be found at https://mynixos.com/options + +### For your curiosity +1. https://wiki.nixos.org/wiki/Firejail From 1b09aac8fc636a3a47f1b39bc83b5ea53fd2799d Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:22:24 +1000 Subject: [PATCH 035/197] deploy helper script now pipes to ./rebuild.log --- deploy | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/deploy b/deploy index c1a88cb..a69a484 100755 --- a/deploy +++ b/deploy @@ -20,13 +20,18 @@ collect_garbage () { rebuild_flake () { # make sure all changes are visible to nixos git add . --verbose + local FLAGS= if [ "$1" = "reinstall-bootloader" ]; then - sudo nixos-rebuild switch --flake . --install-bootloader + FLAGS="$FLAGS --install-bootloader" + # sudo nixos-rebuild switch --flake . --install-bootloader # STC_DISPLAY_ALL_UNITS=1 (verbose, show output of all units) - else - sudo nixos-rebuild switch --flake . - #nixos-rebuild build --flake .# --cores 8 -j 1 fi + + # LOG="$(mktemp /tmp/rebuild-XXXXXXXX)" + LOG="./rebuild.log" + echo "[*] Deployment stdout(&1) directed to $LOG" + sudo nixos-rebuild switch --flake . "$FLAGS" & > >(tee $LOG) + #nixos-rebuild build --flake .# --cores 8 -j 1 } deploy_hive () { From a5631ee6f99a58afaf0fb7f3cb7c3734199b4a94 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:24:33 +1000 Subject: [PATCH 036/197] Use nixpkgs.config.allowUnfreePredicate +removed unused apps --- flake.lock | 167 ++--------------------------------- flake.nix | 26 +----- homes/me/default.nix | 3 +- hosts/lolcathost/default.nix | 47 +++++----- hosts/myputer/default.nix | 6 -- 5 files changed, 37 insertions(+), 212 deletions(-) diff --git a/flake.lock b/flake.lock index 72a6d80..c06c8b0 100755 --- a/flake.lock +++ b/flake.lock @@ -19,25 +19,6 @@ "type": "github" } }, - "ags_2": { - "inputs": { - "nixpkgs": "nixpkgs_5", - "systems": "systems_3" - }, - "locked": { - "lastModified": 1728326430, - "narHash": "sha256-tV1ABHuA1HItMdCTuNdA8fMB+qw7LpjvI945VwMSABI=", - "owner": "Aylur", - "repo": "ags", - "rev": "60180a184cfb32b61a1d871c058b31a3b9b0743d", - "type": "github" - }, - "original": { - "owner": "Aylur", - "repo": "ags", - "type": "github" - } - }, "aquamarine": { "inputs": { "hyprutils": [ @@ -127,20 +108,6 @@ } }, "flake-compat_3": { - "locked": { - "lastModified": 1696426674, - "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", - "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", - "revCount": 57, - "type": "tarball", - "url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.0.1/018afb31-abd1-7bff-a5e4-cff7e18efb7a/source.tar.gz" - }, - "original": { - "type": "tarball", - "url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz" - } - }, - "flake-compat_4": { "flake": false, "locked": { "lastModified": 1696426674, @@ -156,7 +123,7 @@ "type": "github" } }, - "flake-compat_5": { + "flake-compat_4": { "flake": false, "locked": { "lastModified": 1696426674, @@ -337,25 +304,6 @@ "type": "github" } }, - "hyprpanel": { - "inputs": { - "ags": "ags_2", - "nixpkgs": "nixpkgs_6" - }, - "locked": { - "lastModified": 1731270736, - "narHash": "sha256-N0unlLf/7BqkrYx3BO9svv1+oLzKpArgiqLzkmNpD3Q=", - "owner": "Jas-SinghFSU", - "repo": "HyprPanel", - "rev": "a7855baf13c6abdd0b0e988e4390112cd7deda67", - "type": "github" - }, - "original": { - "owner": "Jas-SinghFSU", - "repo": "HyprPanel", - "type": "github" - } - }, "hyprutils": { "inputs": { "nixpkgs": [ @@ -406,22 +354,6 @@ "type": "github" } }, - "nix-flatpak": { - "locked": { - "lastModified": 1711997201, - "narHash": "sha256-J71xzQlVYsjagA4AsVwRazhBh2rZrPpKvxTgs6UzL7c=", - "owner": "gmodena", - "repo": "nix-flatpak", - "rev": "b76fa31346db7fc958a9898f3c594696ca71c4fd", - "type": "github" - }, - "original": { - "owner": "gmodena", - "ref": "v0.4.1", - "repo": "nix-flatpak", - "type": "github" - } - }, "nix-github-actions": { "inputs": { "nixpkgs": [ @@ -443,25 +375,6 @@ "type": "github" } }, - "nixcord": { - "inputs": { - "flake-compat": "flake-compat_3", - "nixpkgs": "nixpkgs_7" - }, - "locked": { - "lastModified": 1730720546, - "narHash": "sha256-5147A6X0MH6u/YDxLe+Nnva3oxfLQanC716LarG/uoo=", - "owner": "kaylorben", - "repo": "nixcord", - "rev": "e3e27c77316f7526b1a846778ae9c759c9377611", - "type": "github" - }, - "original": { - "owner": "kaylorben", - "repo": "nixcord", - "type": "github" - } - }, "nixpkgs": { "locked": { "lastModified": 1725634671, @@ -543,54 +456,6 @@ } }, "nixpkgs_5": { - "locked": { - "lastModified": 1725634671, - "narHash": "sha256-v3rIhsJBOMLR8e/RNWxr828tB+WywYIoajrZKFM+0Gg=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "574d1eac1c200690e27b8eb4e24887f8df7ac27c", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_6": { - "locked": { - "lastModified": 1739866667, - "narHash": "sha256-EO1ygNKZlsAC9avfcwHkKGMsmipUk1Uc0TbrEZpkn64=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "73cf49b8ad837ade2de76f87eb53fc85ed5d4680", - "type": "github" - }, - "original": { - "owner": "nixos", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_7": { - "locked": { - "lastModified": 1730768919, - "narHash": "sha256-8AKquNnnSaJRXZxc5YmF/WfmxiHX6MMZZasRP6RRQkE=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "a04d33c0c3f1a59a2c1cb0c6e34cd24500e5a1dc", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_8": { "locked": { "lastModified": 1752620740, "narHash": "sha256-f3pO+9lg66mV7IMmmIqG4PL3223TYMlnlw+pnpelbss=", @@ -606,7 +471,7 @@ "type": "github" } }, - "nixpkgs_9": { + "nixpkgs_6": { "locked": { "lastModified": 1730200266, "narHash": "sha256-l253w0XMT8nWHGXuXqyiIC/bMvh1VRszGXgdpQlfhvU=", @@ -652,17 +517,14 @@ "colmena": "colmena", "grub2-themes": "grub2-themes", "hyprland": "hyprland", - "hyprpanel": "hyprpanel", - "nix-flatpak": "nix-flatpak", - "nixcord": "nixcord", - "nixpkgs": "nixpkgs_8", + "nixpkgs": "nixpkgs_5", "spicetify-nix": "spicetify-nix", "swww": "swww" } }, "spicetify-nix": { "inputs": { - "flake-compat": "flake-compat_4", + "flake-compat": "flake-compat_3", "nixpkgs": [ "nixpkgs" ] @@ -699,8 +561,8 @@ }, "swww": { "inputs": { - "flake-compat": "flake-compat_5", - "nixpkgs": "nixpkgs_9", + "flake-compat": "flake-compat_4", + "nixpkgs": "nixpkgs_6", "utils": "utils" }, "locked": { @@ -748,21 +610,6 @@ } }, "systems_3": { - "locked": { - "lastModified": 1689347949, - "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", - "owner": "nix-systems", - "repo": "default-linux", - "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default-linux", - "type": "github" - } - }, - "systems_4": { "locked": { "lastModified": 1681028828, "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", @@ -779,7 +626,7 @@ }, "utils": { "inputs": { - "systems": "systems_4" + "systems": "systems_3" }, "locked": { "lastModified": 1726560853, diff --git a/flake.nix b/flake.nix index 85323f7..3a8be4e 100755 --- a/flake.nix +++ b/flake.nix @@ -14,26 +14,15 @@ inputs.nixpkgs.follows = "nixpkgs"; }; - nixcord.url = "github:kaylorben/nixcord"; - grub2-themes.url = "github:vinceliuice/grub2-themes"; # is this necessary? (aren't I enabling it in `configuration.nix` anyways?) hyprland.url = "github:hyprwm/Hyprland"; - hyprpanel = { - url = "github:Jas-SinghFSU/HyprPanel"; - #inputs.nixpkgs.follows = "nixpkgs"; - }; - swww.url = "github:LGFae/swww"; - # TODO: declarative flatpak management - nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=v0.4.1"; - ags.url = "github:Aylur/ags"; - # colmena.url = "github:zhaofengli/colmena"; colmena.url = "github:zhaofengli/colmena/?rev=47b6414d800c8471e98ca072bc0835345741a56a"; }; @@ -43,8 +32,6 @@ #home-manager, hyprland, grub2-themes, - nixcord, - hyprpanel, colmena, ... } @ inputs: let @@ -53,11 +40,8 @@ pkgs = import nixpkgs { inherit system; config = { - allowUnfree = true; + allowUnfree = false; # sanity check }; - overlays = [ - inputs.hyprpanel.overlay - ]; }; # TODO: come back to this its really cool @@ -75,7 +59,7 @@ # i be on my puter fr myputer = nixpkgs.lib.nixosSystem { # nix passes these to every single module - specialArgs = {inherit inputs pkgs;}; + specialArgs = {inherit inputs;}; modules = [ ./hosts/myputer @@ -85,7 +69,7 @@ # my laptop 0w0 lolcathost = nixpkgs.lib.nixosSystem { - specialArgs = {inherit inputs pkgs;}; + specialArgs = {inherit inputs;}; modules = [ ./hosts/lolcathost @@ -97,7 +81,6 @@ # remote deployment to my servers!! colmenaHive = colmena.lib.makeHive { meta = { - # set nixpkgs global nixpkgs = pkgs; # set nixpkgs per server nodeNixpkgs = { @@ -106,9 +89,6 @@ config.allowUnfree = false; }; }; - - # we can use `specialArgs.inputs` to inject wishlist into hyrule's module - #specialArgs.inputs = with inputs; {inherit wishlist;}; }; # meine vps diff --git a/homes/me/default.nix b/homes/me/default.nix index 5eb2d90..ce18969 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -16,13 +16,12 @@ ../modules/bat.nix ../modules/fish.nix ../modules/editor/helix.nix - ../modules/editor/vscodium.nix + # ../modules/editor/vscodium.nix ../modules/btop.nix ../modules/term/ghostty.nix ../modules/term/rio.nix ../modules/firefox.nix - ../modules/nixcord.nix #../modules/hypr/hypridle.nix ../modules/hypr/hyprlock.nix diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 2f99758..b5f3780 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -11,7 +11,7 @@ in { imports = [ ./hardware-configuration.nix (import "${home-manager}/nixos") - inputs.spicetify-nix.nixosModules.default + # inputs.spicetify-nix.nixosModules.default ../modules/steam.nix ../modules/obsidian.nix @@ -21,18 +21,32 @@ in { ../modules/chameleonultragui.nix ]; - programs.spicetify = let - spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system}; - in { - enable = true; - enabledExtensions = with spicePkgs.extensions; [ - adblock - hidePodcasts - shuffle # shuffle+ (special characters are sanitized out of extension names) + nixpkgs.config.allowUnfreePredicate = let + whitelist = map lib.getName [ + pkgs.jetbrains.rider + pkgs.obsidian + pkgs.gitkraken + pkgs.steam + pkgs.steamcmd + pkgs.steam-unwrapped + pkgs.spotify + pkgs.dwarf-fortress ]; - #theme = spicePkgs.themes.catppuccin; - #colorScheme = "mocha"; - }; + in + pkg: builtins.elem (lib.getName pkg) whitelist; + + # programs.spicetify = let + # spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system}; + # in { + # enable = true; + # enabledExtensions = with spicePkgs.extensions; [ + # adblock + # hidePodcasts + # shuffle # shuffle+ (special characters are sanitized out of extension names) + # ]; + # #theme = spicePkgs.themes.catppuccin; + # #colorScheme = "mocha"; + # }; boot.loader = { efi = { @@ -159,13 +173,6 @@ in { nitch starfetch - hyprpanel - - # flatpak requires gnome-software - # for graphical applications - flatpak - gnome-software - colmena-latest jetbrains.rider @@ -206,8 +213,6 @@ in { #extraSpecialArgs = {inherit inputs pkgs;}; sharedModules = [ inputs.ags.homeManagerModules.default - inputs.nixcord.homeManagerModules.nixcord - #{nixpkgs.overlays = [inputs.hyprpanel.overlay];} ]; }; diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 59e350c..1143a0d 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -153,10 +153,6 @@ in { nitch starfetch - # flatpak requires gnome-software - flatpak - gnome-software - colmena-latest gitkraken @@ -179,9 +175,7 @@ in { home-manager = { users.me = import ../../homes/me; sharedModules = [ - inputs.nixcord.homeManagerModules.nixcord inputs.ags.homeManagerModules.default - {nixpkgs.overlays = [inputs.hyprpanel.overlay];} ]; }; From 6824eff694b95eac2df126f65c085745cd4f774a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:24:56 +1000 Subject: [PATCH 037/197] Update AngryOxide rev hash --- hosts/packages/angryoxide/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/packages/angryoxide/default.nix b/hosts/packages/angryoxide/default.nix index 8111339..7610848 100644 --- a/hosts/packages/angryoxide/default.nix +++ b/hosts/packages/angryoxide/default.nix @@ -75,7 +75,7 @@ in pname = angryoxide-pname; version = angryoxide-version; src = angryoxide-src; - cargoHash = "sha256-Dxo1iLxl+wn2qAZh3+bf2n00MPE2LlG5boB6iJC/CDA="; + cargoHash = "sha256-mry4l0a7DZOWkrChU40OVRCBjKwI39cyZtvEBA5tro0="; meta = { description = "802.11 Attack Tool"; From 84f0364befeb02b7bff438e478d3cbd6e1b2538b Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:25:19 +1000 Subject: [PATCH 038/197] Add signal desktop --- hosts/lolcathost/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index b5f3780..128436c 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -1,4 +1,5 @@ { + lib, pkgs, inputs, ... @@ -236,6 +237,7 @@ in { wl-clipboard # clipboard for wayland pavucontrol qbittorrent # torrenting + signal-desktop (callPackage ../sddm-theme-corners.nix {}).sddm-theme-corners # dependencies for my sddm theme: From 334845da97e27bc23d148038bf3c0b6367c58958 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:26:04 +1000 Subject: [PATCH 039/197] Fixed Nim version number hardcoded --- hosts/lolcathost/default.nix | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 128436c..017d534 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -248,9 +248,7 @@ in { poetry # python dependency management and packaging clang-tools - nim-2_2 - nimble - # nimlangserver # FUCK THIS LSP, ITS AWFUL WITH HELIX + nim sageWithDoc # SageMath + HTML Documentation From 856f4243934ae73806bcf523e19e6fab2b98675a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:26:15 +1000 Subject: [PATCH 040/197] Added yazi and lazygit --- hosts/lolcathost/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 017d534..0a07a53 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -276,6 +276,8 @@ in { tldr # btop eza + yazi + lazygit ripgrep viddy # modern `watch` command thefuck From e70e804c34fa311efe80e5d74313b6c0a2b65b89 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 19 Jul 2025 23:26:46 +1000 Subject: [PATCH 041/197] Ignore rebuild logs --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 6f2994e..31f728a 100755 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ ISSUES/ secrets/ result +rebuild*.log From 06c25186b7a71dde1f75cc93979ce12799512404 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 21 Jul 2025 01:18:29 +1000 Subject: [PATCH 042/197] Added zsh dotfile configuration to me --- homes/me/default.nix | 18 +++++++++++++++++- hosts/lolcathost/default.nix | 5 +---- 2 files changed, 18 insertions(+), 5 deletions(-) diff --git a/homes/me/default.nix b/homes/me/default.nix index ce18969..10e070d 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -20,7 +20,7 @@ ../modules/btop.nix ../modules/term/ghostty.nix - ../modules/term/rio.nix + # ../modules/term/rio.nix ../modules/firefox.nix #../modules/hypr/hypridle.nix @@ -77,6 +77,22 @@ # these are both required for home-manager to work home-manager.enable = true; + zsh = { + enable = true; + enableCompletion = true; + autosuggestion.enable = true; + syntaxHighlighting.enable = true; + + history = { + size = 10000; + ignoreAllDups = true; + path = "$HOME/.zsh_history"; + ignorePatterns = [ + "rm *" + ]; + }; + }; + # set ssh profiles # (all we need is hyrule, everything else is through wishlist) # NOTE: (IMPORTANT) this DOES NOT start the ssh-agent diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 0a07a53..082f13b 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -24,7 +24,6 @@ in { nixpkgs.config.allowUnfreePredicate = let whitelist = map lib.getName [ - pkgs.jetbrains.rider pkgs.obsidian pkgs.gitkraken pkgs.steam @@ -176,13 +175,12 @@ in { colmena-latest - jetbrains.rider gitkraken ]; }; # user for my professional jobs and stuff - ae = { + aez = { isNormalUser = true; extraGroups = ["wheel"]; shell = pkgs.bash; #pkgs.fish @@ -324,7 +322,6 @@ in { xwayland.enable = true; }; - zsh.enable = true; fish.enable = true; nix-ld.enable = true; From 2d59248e1c62042b84198d485243238727691a71 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 21 Jul 2025 01:18:51 +1000 Subject: [PATCH 043/197] Fixed deploy script incorrect pipe to `tee` --- deploy | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/deploy b/deploy index a69a484..04705bd 100755 --- a/deploy +++ b/deploy @@ -22,7 +22,7 @@ rebuild_flake () { git add . --verbose local FLAGS= if [ "$1" = "reinstall-bootloader" ]; then - FLAGS="$FLAGS --install-bootloader" + FLAGS="--install-bootloader" # sudo nixos-rebuild switch --flake . --install-bootloader # STC_DISPLAY_ALL_UNITS=1 (verbose, show output of all units) fi @@ -30,7 +30,7 @@ rebuild_flake () { # LOG="$(mktemp /tmp/rebuild-XXXXXXXX)" LOG="./rebuild.log" echo "[*] Deployment stdout(&1) directed to $LOG" - sudo nixos-rebuild switch --flake . "$FLAGS" & > >(tee $LOG) + sudo nixos-rebuild switch --flake . "$FLAGS" 2>&1 | tee $LOG #nixos-rebuild build --flake .# --cores 8 -j 1 } From 8e2335c88667dfaffc375190e7de989331926d57 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 21 Jul 2025 23:34:07 +1000 Subject: [PATCH 044/197] Added GnuPG to lolcathost configuration --- hosts/lolcathost/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 082f13b..ab931e1 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -305,6 +305,7 @@ in { unrar-free man-pages man-pages-posix + gnupg # Games mindustry From f99f6e8c946def8615e8a56aca3a704ef1e9ee97 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 21 Jul 2025 23:34:47 +1000 Subject: [PATCH 045/197] Fixed deploy script bad expansion --- deploy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deploy b/deploy index 04705bd..10f33bb 100755 --- a/deploy +++ b/deploy @@ -30,7 +30,7 @@ rebuild_flake () { # LOG="$(mktemp /tmp/rebuild-XXXXXXXX)" LOG="./rebuild.log" echo "[*] Deployment stdout(&1) directed to $LOG" - sudo nixos-rebuild switch --flake . "$FLAGS" 2>&1 | tee $LOG + sudo nixos-rebuild switch --flake . $FLAGS 2>&1 | tee "$LOG" #nixos-rebuild build --flake .# --cores 8 -j 1 } From 7e55a46db7b1c6faf496e2a1e8b098350645983b Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:26:37 +1000 Subject: [PATCH 046/197] Added hyrule specific TODO items --- TODO | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/TODO b/TODO index 46f6bdf..b3c42f3 100644 --- a/TODO +++ b/TODO @@ -9,6 +9,11 @@ Create a command palette accessible with MOD+P (MOD => Windows Key) Boring stuff (ie work and uni should go on a separate user account) +### LATEST +1. Clean hosts/hyrule/default.nix +2. Rename user "ae" to "cry" or "vps" +3. Add 404 page to nginx on hyrule + INSPIRATION: 1. https://github.com/sabrehagen/desktop-environment From a0a97c9f42897db628737a214710f819e05eb741 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:28:36 +1000 Subject: [PATCH 047/197] Remove unused users from lolcathost --- hosts/lolcathost/default.nix | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index ab931e1..a90cfbd 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -179,24 +179,6 @@ in { ]; }; - # user for my professional jobs and stuff - aez = { - isNormalUser = true; - extraGroups = ["wheel"]; - shell = pkgs.bash; #pkgs.fish - packages = with pkgs; [ - ]; - }; - - # # This is the user account for servers - # dev = { - # isNormalUser = true; - # extraGroups = ["wheel"]; - # shell = pkgs.bash; #pkgs.zsh - # packages = with pkgs; [ - # ]; - # }; - # user for friends to ssh into friends = { isNormalUser = true; From fd2857742fc9d1f57c1d477616d5b62e8d6b60ba Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:29:04 +1000 Subject: [PATCH 048/197] Clean homes/ae/default.nix --- homes/ae/default.nix | 34 ---------------------------------- 1 file changed, 34 deletions(-) diff --git a/homes/ae/default.nix b/homes/ae/default.nix index b92f739..8e0e0fe 100644 --- a/homes/ae/default.nix +++ b/homes/ae/default.nix @@ -10,47 +10,13 @@ config.allowUnfree = false; }; - imports = [ - ]; - home = { username = "ae"; homeDirectory = "/home/ae"; }; - programs = { - }; - # Nicely reload system units when changing configs systemd.user.startServices = "sd-switch"; - # ssh = { - # enable = true; - # forwardAgent = true; - # addKeysToAgent = "yes"; - - # matchBlocks = { - # hyrule = { - # hostname = "imbored.dev"; - # user = "ae"; - # port = 22; - # identityFile = "/home/ae/.ssh/id_hyrule"; - # }; - # }; - # }; - - # SERVICE: webfishing (example for wishlist) - #systemd.user.services.webfishing = { - # Unit.Description = "I be out here webfishing frfr"; - - # Install.WantedBy = ["default.target"]; - - # Service = { - # Type = "exec"; - # ExecStart = "echo $HOME; cat $HOME/.ssh/config"; - # Restart = "always"; - # }; - #}; - home.stateVersion = "24.11"; # DO NOT MODIFY } From a23c48b1382dbdeab4586fe440d781d8288f935c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:29:23 +1000 Subject: [PATCH 049/197] Remove unnecessary comments from homes/me/default.nix --- homes/me/default.nix | 6 ------ 1 file changed, 6 deletions(-) diff --git a/homes/me/default.nix b/homes/me/default.nix index 10e070d..170bc6d 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -6,11 +6,6 @@ pkgs, ... }: { - # TODO: unset this - nixpkgs = { - config.allowUnfree = true; - }; - imports = [ ../modules/git.nix ../modules/bat.nix @@ -94,7 +89,6 @@ }; # set ssh profiles - # (all we need is hyrule, everything else is through wishlist) # NOTE: (IMPORTANT) this DOES NOT start the ssh-agent # for that you need to use `services.ssh-agent.enable` ssh = { From a4741a235779d4f194d5353c85db91745922fb54 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:29:49 +1000 Subject: [PATCH 050/197] Progress hyrule to home-manager 25.05 --- hosts/hyrule/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 1a1dafd..76b8d68 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -5,8 +5,8 @@ ... }: let home-manager = builtins.fetchTarball { - url = "https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz"; - sha256 = "0c07xj74vsj37d3a8f98i9rhhhr99ckwlp45n40f0qkmigm3pk8s"; + url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; + sha256 = "1kk5qzfb87mkgy6vzm7x8z8akxr3k8k7839yjdy48z034pvidhsr"; }; in { imports = [ From 9863e6a726d970fa8081823977501031741edde5 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:30:58 +1000 Subject: [PATCH 051/197] Remove unnecessary comments for hyrule --- hosts/hyrule/default.nix | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 76b8d68..5f14a2a 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -18,11 +18,6 @@ in { #../modules/server/fail2ban.nix ]; - # override wishlist with the new cool one! - #pkgs.config.packageOverrides = { - # wishlist = inputs.wishlist.packages.x86_64-linux.wishlist; - #}; - nix.settings = { # make wheel group trusted users allows my "ae" user # to import packages not signed by a trusted key @@ -47,16 +42,6 @@ in { targetHost = "imbored.dev"; targetUser = "ae"; targetPort = 22; - # the following line is unnecessary if using an ssh agent - #sshOptions = ["-i /home/me/.ssh/id_hyrule"]; - #keys = { - # "imbored.dev" = { - # # text, keyCommand, or keyFile must be set - # # text = ""; - # #keyCommand = [ "" ]; - # keyFile = "/home/me/.ssh/id_hyrule"; - # }; - #}; buildOnTarget = false; # build locally then deploy }; @@ -88,7 +73,6 @@ in { }; }; - # grant passwordless sudo to wheel group security.sudo.wheelNeedsPassword = false; users = { @@ -471,17 +455,5 @@ in { }; }; - #systemd.services.wishlist = { - # description = "Single entrypoint for multiple SSH endpoints"; - # wantedBy = ["multi-user.target"]; - # - # serviceConfig = { - # DynamicUser = "yes"; - # ExecStart = "${pkgs.wishlist}/bin/wishlist serve --config /home/$USER/.ssh/config"; - # Restart = "always"; - # RestartSec = "2s"; - # }; - #}; - system.stateVersion = "24.11"; # DO NOT MODIFY } From 759ad1c5b53cfe978405b35bcc5623b77ccb8969 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:32:28 +1000 Subject: [PATCH 052/197] Remove unnecessary permissions from ae@hyrule --- hosts/hyrule/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 5f14a2a..e8fcd7a 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -82,7 +82,7 @@ in { # primary user ae = { isNormalUser = true; - extraGroups = ["wheel" "networkmanager" "docker"]; + extraGroups = ["wheel"]; shell = pkgs.bash; home = "/home/ae"; # TEMP: remove and replace with home-manager packages = with pkgs; [ From 30f3b04fb05414035399fd629802bac859391ec9 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:38:33 +1000 Subject: [PATCH 053/197] Remove user friends@hyrule --- hosts/hyrule/default.nix | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index e8fcd7a..6fc1993 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -102,15 +102,6 @@ in { wishlist ]; }; - - # user for friends to ssh into - friends = { - isNormalUser = true; - shell = pkgs.bash; - home = "/home/friends"; # TEMP: remove and replace with home-manager - packages = with pkgs; [ - ]; - }; }; }; @@ -196,9 +187,9 @@ in { enable = true; ports = [22]; settings = { - PasswordAuthentication = true; + PasswordAuthentication = false; PermitRootLogin = "no"; - AllowUsers = ["ae" "subspace"]; # allow all users by default + AllowUsers = ["ae" "subspace"]; # DO NOT ALLOW ALL UseDns = true; X11Forwarding = false; }; From 2cbf2f83a49754486ddf4992d739061eaf278154 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:40:32 +1000 Subject: [PATCH 054/197] Subspace uses nixpkgs.wishlist not my fork --- hosts/hyrule/default.nix | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 6fc1993..3cc73c2 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -12,7 +12,6 @@ in { imports = [ ./hardware-configuration.nix (import "${home-manager}/nixos") - #../../flakes/wishlist/wishlist.nix #../modules/server/nginx.nix #../modules/server/ssh.nix #../modules/server/fail2ban.nix @@ -89,12 +88,8 @@ in { ]; }; - subspace = let - # override - wishlistBash = - pkgs.bash.override { - }; - in { + # TODO: reduce security implications of subspace + subspace = { isNormalUser = true; shell = pkgs.bash; home = "/home/subspace"; From db0b1c388340fb13d630e473f346fcf7b0c808ba Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:41:54 +1000 Subject: [PATCH 055/197] Permit sudo via pam_ssh_agent_auth module --- hosts/hyrule/default.nix | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 3cc73c2..85dad4f 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -83,8 +83,8 @@ in { isNormalUser = true; extraGroups = ["wheel"]; shell = pkgs.bash; - home = "/home/ae"; # TEMP: remove and replace with home-manager - packages = with pkgs; [ + openssh.authorizedKeys.keys = [ + "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCsUZY45rgezi+8iROdcR5vPeacJ2fbMjlDijfUrH9hRX2FzCsg/4e3aFKhi2seZMmyTfbstxmDrrH8paUS5TibFgLFBGNngaF3CTjg85i5pm25Hr4IVo31oziBnTWaG6j3buYKtz5e1qSPzXywinJR+5+FCUJU7Fxa+EWTZcOX4wYgArSj4q73rZmvk5N0X44Mudt4nvpD2chvxygsdTzD6ph92qCuaJ/AbfmOoC7b/xvOaOVydUfgDLpHi9VZbd3akvvKxRfW6ZklldgXEzPXKMuastN0mwcBxvIb5G1Vkj8jtSVtKPc5psZ9/NWA5l38xH4qZ6z7eib6thtEMdtcKmTZEEWDADjqTea5Gj61c1n18cr6f3Tff+0bn/cxsl4Y0esi+aDeuCXYiIYNmeKBx0ttDNIxpk4J5Fdh6Xs+AZif5lnJErtu8TPy2aC0bc9wehTjMyvilTHfyerOD1ZJXhN2XwRVDGN7t7leAJZISJlPjqTDcw3Vfvzte/5JqS+FR+hbpG4uz2ix8kUa20u5YF2oSdGl8+zsdozVsdQm10Iv9WSXBV7t4m+oyodgtfzydBpmXq7aBXudCiEKw+7TC7F+1a4YFrVrCNXKFgKUpd1MiVLl7DIbzm5U9MD2BB3Fy7BPCzr3tW6/ExOhhpBWY+HnzVGQfkNr7dRcqfipKw== ae@imbored.dev" ]; }; @@ -107,7 +107,6 @@ in { ae = import ../../homes/ae; subspace = import ../../homes/subspace; }; - sharedModules = []; }; services = { @@ -412,11 +411,17 @@ in { }; }; }; - # accept Lets Encrypt's security policy (for nginx) - security.acme = { - acceptTerms = true; - # TODO: change this to me@imbored.dev - defaults.email = "eclarkboman@gmail.com"; + security = { + # accept Lets Encrypt's security policy (for nginx) + acme = { + acceptTerms = true; + # TODO: change this to me@imbored.dev + defaults.email = "eclarkboman@gmail.com"; + }; + + # allow SSH keys for passwordless auth + # TODO: DO NOT USE THIS (create my own alternative to colmena) + pam.services.sudo.sshAgentAuth = true; }; environment.systemPackages = with pkgs; [ From 9f6bf432bcc757e0aad36f9cb593068d71659502 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:44:16 +1000 Subject: [PATCH 056/197] Major change to hyrule.nginx config Permit nginx recommended settings for gzip, zstd, tls nginx proxy, and optimisations --- hosts/hyrule/default.nix | 99 +++++++++++++++++++--------------------- 1 file changed, 48 insertions(+), 51 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 85dad4f..118c754 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -116,64 +116,61 @@ in { # and change forgejo to use 127.0.0.2:22 (use port 22, ONLY change loopback address) nginx = { enable = true; - # in wake of CVE-2022-3602/CVE-2022-3786 package = pkgs.nginxStable.override {openssl = pkgs.libressl;}; - #virtualHosts."imbored.dev".locations."/" = { - virtualHosts = { - "imbored.dev" = { - # "http:imbored.dev" = { - default = true; - # serverName = "imbored.dev"; - # listenAddresses = ["imbored.dev"]; + recommendedGzipSettings = true; + recommendedZstdSettings = true; + recommendedOptimisation = true; + recommendedProxySettings = true; + recommendedTlsSettings = true; + + # streamConfig = '' + # server { + # listen 127.0.0.1:53 udp reuseport; + # proxy_timeout 20s; + # proxy_pass 192.168.0.1:53535; + # } + # ''; + + virtualHosts = let + localhost = "http://127.0.0.1"; + std = { + # TODO: should I run over QUIC+HTTP3? (experimental) + # quic = true; + # http3 = true; enableACME = true; - addSSL = true; # forceSSL = true; - root = "/var/www/imbored"; - #index = "index.html"; - #root = pkgs.writeTextDir "index.html" '' - # - # - # Give me your mittens! - # - # - #''; + # kTLS = true; # offload TLS to the linux kernel }; - # "ssh:imbored.dev" = { - # serverName = "imbored.dev"; - # listen = [{ - # addr = "imbored.dev"; - # port= 22; - # }]; - # locations."/".proxyPass = "ssh://127.0.0.1:2222"; - # }; + in { + "imbored.dev" = + { + default = true; + addSSL = true; # not strictly enforced <3 + root = "/var/www/imbored"; + # extraConfig = '' + # error_page 404 /custom_404.html; + # ''; + } + // std; # Route "vault" subdomain to vaultwarden - "vault.imbored.dev" = { - enableACME = true; - forceSSL = true; - locations."/".proxyPass = "http://127.0.0.1:8222"; - }; + "vault.imbored.dev" = + { + forceSSL = true; + locations."/".proxyPass = "${localhost}:8222"; + } + // std; # Route "forge" subdomain to forgejo - "forge.imbored.dev" = { - # "https:forge.imbored.dev" = { - #serverName = "forge.imbored.dev"; - #listenAddresses = ["forge.imbored.dev"]; # NOTE: I think this is wrong - enableACME = true; # TODO: maybe use `forgejo.settings.server.ENABLE_ACME` instead? - forceSSL = true; - extraConfig = '' - client_max_body_size 512M; - ''; - locations."/".proxyPass = "http://127.0.0.1:3000"; - }; - # NOTE: would it work if I used "ssh://forge.imbored.dev" and "https://forge.imbored.dev" instead? - # "ssh:forge.imbored.dev" = { - # serverName = "forge.imbored.dev"; - # listen = [{ - # addr = "forge.imbored.dev"; - # port = 22; - # }]; - # locations."/".proxyPass = "ssh://127.0.0.2:22"; - # }; + # TODO: use `forgejo.settings.server.ENABLE_ACME` instead? + "forge.imbored.dev" = + { + forceSSL = true; + extraConfig = '' + client_max_body_size 512M; + ''; + locations."/".proxyPass = "${localhost}:3000"; + } + // std; }; }; From 15a8cb1c55c5d7178f0c3e95e57f37d5dbd6d543 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:45:42 +1000 Subject: [PATCH 057/197] forge.imbored.dev metadata reflect shift to dobutterfliescry.net --- hosts/hyrule/default.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 118c754..6807e27 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -293,9 +293,9 @@ in { }; DEFAULT = { - APP_NAME = "Emile's Forge"; - APP_SLOGIN = "Cozy"; - APP_DISPLAY_NAME_FORMAT = "{APP_NAME}: {APP_SLOGAN}"; + APP_NAME = "Do butterflies cry when they're sad?"; + APP_SLOGIN = "but cozy"; + APP_DISPLAY_NAME_FORMAT = "{APP_NAME} ::{APP_SLOGAN}::"; }; repository = { @@ -325,8 +325,8 @@ in { }; "ui.meta" = { AUTHOR = "Emile Clark-Boman - emileclarkb"; - DESCRIPTION = "This is my personal self-hosted git forge, where I keep and maintain personal projects!"; - KEYWORDS = "emileclarkb,git,forge,forgejo,self-hosted"; + DESCRIPTION = "This is my personal self-hosted git forge, where I keep and maintain personal projects! PS do butterflies cry when they're sad?"; + KEYWORDS = "emile,clark,boman,clarkboman,emileclarkb,git,forge,forgejo,self-hosted,dobutterfliescry,butterfly,butterflies"; }; markdown = { From 9f4c664250a21fb723034d05fa0ba51b44d71f0c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 24 Jul 2025 13:46:51 +1000 Subject: [PATCH 058/197] hyrule.forgejo instance now sets ENABLE_PUSH_CREATE_USER --- hosts/hyrule/default.nix | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 6807e27..dc5cfb2 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -300,6 +300,9 @@ in { repository = { DEFAULT_PRIVATE = "private"; # last, private, public + # repo/org created on push to non-existent + ENABLE_PUSH_CREATE_USER = true; + ENABLE_PUSH_CREATE_ORG = false; DEFAULT_PUSH_CREATE_PRIVATE = true; MAX_CREATION_LIMIT = -1; }; @@ -351,8 +354,7 @@ in { }; service = { - # toggle to create an admin user - DISABLE_REGISTRATION = true; + DISABLE_REGISTRATION = true; # toggle for new users #DEFAULT_USER_IS_RESTRICTED = true; # Forbid login with third-party services (ie github) ALLOW_ONLY_INTERNAL_REGISTRATION = true; From e2c8d980f86b420d4540883b470210f3520e8a82 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:07:58 +1000 Subject: [PATCH 059/197] chmod -x .gitignore (why is it executable??) --- .gitignore | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 .gitignore diff --git a/.gitignore b/.gitignore old mode 100755 new mode 100644 From c9899c797e3dc086cb1fa68bff659aa9622823aa Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:14:04 +1000 Subject: [PATCH 060/197] added script that lists store paths referencing the current nix profile --- scripts/nix-list-installed | 3 +++ 1 file changed, 3 insertions(+) create mode 100755 scripts/nix-list-installed diff --git a/scripts/nix-list-installed b/scripts/nix-list-installed new file mode 100755 index 0000000..5a253b9 --- /dev/null +++ b/scripts/nix-list-installed @@ -0,0 +1,3 @@ +#!/usr/bin/env sh +nix-store -q --references /var/run/current-system/sw \ + | cut -d'-' -f2- From e0174e669c5a609d81164eb3cf7c6dedd0c5a325 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:14:35 +1000 Subject: [PATCH 061/197] sisyphus (updated home-manager hash) --- hosts/lolcathost/default.nix | 2 +- hosts/myputer/default.nix | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index a90cfbd..599e295 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -6,7 +6,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; - sha256 = "0z94i2ig7wcm63fp1wkpp6r4458g2bj3r7ijlfapxihqybpgvng5"; + sha256 = "1kk5qzfb87mkgy6vzm7x8z8akxr3k8k7839yjdy48z034pvidhsr"; }; in { imports = [ diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 1143a0d..bd85eb5 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -7,7 +7,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz"; - sha256 = "0z94i2ig7wcm63fp1wkpp6r4458g2bj3r7ijlfapxihqybpgvng5"; + sha256 = "1kk5qzfb87mkgy6vzm7x8z8akxr3k8k7839yjdy48z034pvidhsr"; }; in { imports = [ From 9fd929ae7bb54eef9a1f49c9c127ae22a5cce1f3 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:17:51 +1000 Subject: [PATCH 062/197] add extendable script to test hyrule's critical systemd services --- scripts/testvps | 82 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) create mode 100755 scripts/testvps diff --git a/scripts/testvps b/scripts/testvps new file mode 100755 index 0000000..4382b7d --- /dev/null +++ b/scripts/testvps @@ -0,0 +1,82 @@ +#!/usr/bin/env bash +# Requires: systemctl + +set -u + +function match { + [[ "$1" =~ $2 ]] +} + +function padlen { + local MAX=0 + for KEY in "$@"; do + local LEN=${#KEY} + ((LEN > MAX)) && MAX=$LEN + done + echo $MAX +} + +function pad { + local PAD="$1" + if [ -z "$PAD" ]; then + exit 1 + fi + + for ((i=0; i/dev/null) + if [ -z "$STAT" ]; then + fmt_print "$SERVICE" "$LPAD" "NOTFOUND" + exit 1 + fi + + local STAT_LOADED=$(head -n2 <<< "$STAT" | tail -n1) + # NOTE: "active " intentionally contains right padding + local ENABLED=$(match "$STAT_LOADED" "^\s*Loaded: loaded \(.*; enabled; .*\)" && echo "enabled" || echo "disabled") + local ACTIVE=$(match "$STAT" "\s*Active: active \(running\)" && echo "active " || echo "inactive") + fmt_print "$SERVICE" "$LPAD" "$ACTIVE" "$ENABLED" +) + +function test_services { + local PAD_ALIGN=$(padlen $@) + # fmt_test_service + for SERVICE in "$@"; do + local LPAD=$((PAD_ALIGN - ${#SERVICE})) + fmt_test_service "$SERVICE" $LPAD + done +} + +test_services nginx forgejo vaultwarden From 65d6c36c3e97df1be92b5b9e86d4334e5a2c9326 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:18:15 +1000 Subject: [PATCH 063/197] add script to run command and temp open a port --- scripts/openport | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100755 scripts/openport diff --git a/scripts/openport b/scripts/openport new file mode 100755 index 0000000..dd6222f --- /dev/null +++ b/scripts/openport @@ -0,0 +1,35 @@ +#!/usr/bin/env bash +# Credit: u/boxofrox https://discourse.nixos.org/u/boxofrox +# Ref: https://discourse.nixos.org/t/how-to-temporarily-open-a-tcp-port-in-nixos/12306/3 +USAGE="[Usage] sudo withport " + +set -ueo pipefail + +open-port() { + local port=$1 + iptables -A INPUT -p tcp --dport $port -j ACCEPT +} + +close-port() { + local port=${1:-0} + iptables -D INPUT -p tcp --dport $port -j ACCEPT +} + +PORT=$1 +if [[ -z "$PORT" ]]; then + echo -e "[!] Port not given\n$USAGE" >&2 + exit 1 +fi +shift; # Drop port argument + +if [[ 0 -eq $# ]]; then + echo -e "[!] Command not given\n$USAGE" >&2 + exit 1 +fi + +open-port $PORT +# Ensure port closes if error occurs. +trap "close-port $PORT" EXIT +# Run the command as user, not root. +runuser -u $SUDO_USER -- "$@" +# Trap will close port. From 90be1ef9fb8a60f1cc3577cad97a914d72d4ae2a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:18:45 +1000 Subject: [PATCH 064/197] moved huhh script to scripts/ directory --- huhh.sh => scripts/huhh | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename huhh.sh => scripts/huhh (100%) diff --git a/huhh.sh b/scripts/huhh similarity index 100% rename from huhh.sh rename to scripts/huhh From f109744b8786371e3bf0a686ff7fc3d5b434a399 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:20:01 +1000 Subject: [PATCH 065/197] updated my personal GUIDE.md rereading this now I don't fully agree with the home perms section... oops --- GUIDE | 18 ------------------ GUIDE.md | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 51 insertions(+), 18 deletions(-) delete mode 100644 GUIDE create mode 100644 GUIDE.md diff --git a/GUIDE b/GUIDE deleted file mode 100644 index 90a70b8..0000000 --- a/GUIDE +++ /dev/null @@ -1,18 +0,0 @@ -### Migrate to a Newer Version of Nixpkgs -```bash -# Determine the channel name you're using -nix-channel --list -nix-channel --remove -nix-channel --add # ie https://nixos.org/channels/nixos-25.05 -nix-channel --update - -# Now upgrade system profile (log to file in case of failure) -nixos-rebuild boot --upgrade | tee rebuild.log -``` - -### Finding New Things to Do -`man 5 configuration.nix` is incredibly useful - similar info can be found at https://mynixos.com/options - -### For your curiosity -1. https://wiki.nixos.org/wiki/Firejail diff --git a/GUIDE.md b/GUIDE.md new file mode 100644 index 0000000..95180b6 --- /dev/null +++ b/GUIDE.md @@ -0,0 +1,51 @@ +### Migrate to a Newer Version of Nixpkgs +```bash +# Determine the channel name you're using +nix-channel --list +nix-channel --remove +nix-channel --add # ie https://nixos.org/channels/nixos-25.05 +nix-channel --update + +# Now upgrade system profile (log to file in case of failure) +nixos-rebuild boot --upgrade | tee rebuild.log +``` + + + +## Security Implications +### NixOS Default Home Permissions +```bash +# Executing from $HOME +>>> mkdir example.d && ls -l example.d +-rw-r--r-- 1 me users 1 Jul 25 10:13 example.d +>>> echo > example.f && ls -l example.f +-rw-r--r-- 1 me users 1 Jul 25 10:15 example.f + +## But these ignore facl? +>>> getfacl "$HOME" +# file: home/me +# owner: me +# group: users +user::rwx +group::--- +other::--- +``` +Many commands default to permissions that ignore the file access control listl (file ACLs). +This is not a NixOS specific issue. However this isn't ideal from a security perspective. +The simplest solution is a recursive `chmod -R 600 ~` but there are plenty of files we +intentionally want to be different. +> [!TODO] +> Solution: Make a Nix/Home-Manager package allowing for control over folder permissions. +> SOlution: Also it should warn if any files owned by $USER have a 2 + + + +## Further Reading +### Finding New Things to Do +`man 5 configuration.nix` is incredibly useful + similar info can be found at https://mynixos.com/options + +### For your curiosity +1. https://wiki.nixos.org/wiki/Firejail + + From 87c92d308b4263d9b2f13fba18d2465321411c79 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:20:46 +1000 Subject: [PATCH 066/197] make fish source a random banner do butterflies cry when they're sad? --- banner | 1 - homes/modules/fish.nix | 9 ++++++++- 2 files changed, 8 insertions(+), 2 deletions(-) delete mode 100644 banner diff --git a/banner b/banner deleted file mode 100644 index 3b051d0..0000000 --- a/banner +++ /dev/null @@ -1 +0,0 @@ -Welcome weary traveller, to my shop... diff --git a/homes/modules/fish.nix b/homes/modules/fish.nix index bcc7d77..95ad255 100755 --- a/homes/modules/fish.nix +++ b/homes/modules/fish.nix @@ -17,7 +17,14 @@ complete -f -c dotnet -a "(dotnet complete (commandline -cp))" end - set -g fish_greeting "Welcome weary traveller to my shop" + function rand_greet + set weary "Welcome weary traveller to my shop" + set sad "Do butterflies cry when they're sad?" + set greetings "$weary" "$sad" + echo -n $greetings[(random 1 (count $greetings))] + end + + set -g fish_greeting (rand_greet) ''; plugins = [ { From 48c4d226327963f0c180350b01d7ba4b692cdfec Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:21:11 +1000 Subject: [PATCH 067/197] fix deploy script's log message being ugly :( --- deploy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deploy b/deploy index 10f33bb..911d054 100755 --- a/deploy +++ b/deploy @@ -29,7 +29,7 @@ rebuild_flake () { # LOG="$(mktemp /tmp/rebuild-XXXXXXXX)" LOG="./rebuild.log" - echo "[*] Deployment stdout(&1) directed to $LOG" + echo "[*] Logging to $LOG" sudo nixos-rebuild switch --flake . $FLAGS 2>&1 | tee "$LOG" #nixos-rebuild build --flake .# --cores 8 -j 1 } From 490249583a1f51ba553cbdc739d70ab04a6eac4e Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:23:20 +1000 Subject: [PATCH 068/197] move PROBLEMLOG -> docs/PROBLEMLOG.md --- PROBLEMLOG => docs/PROBLEMLOG.md | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename PROBLEMLOG => docs/PROBLEMLOG.md (100%) diff --git a/PROBLEMLOG b/docs/PROBLEMLOG.md similarity index 100% rename from PROBLEMLOG rename to docs/PROBLEMLOG.md From 5b2a7b7d9f191ea9aa166e4921813d753a6e1dda Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:23:47 +1000 Subject: [PATCH 069/197] reorganise TODO* files --- TODO | 27 ++++++++++++++++++--------- TODO.LONG-TERM | 26 -------------------------- TODO.SPECIFIC | 4 ---- hosts/packages/chameleonultragui/TODO | 1 + 4 files changed, 19 insertions(+), 39 deletions(-) delete mode 100755 TODO.LONG-TERM delete mode 100644 TODO.SPECIFIC create mode 100644 hosts/packages/chameleonultragui/TODO diff --git a/TODO b/TODO index b3c42f3..2c1e045 100644 --- a/TODO +++ b/TODO @@ -1,19 +1,28 @@ -SOON: fix having to keep specifying new sha256 for home-manager (where I fetchTarball for it) -THEN: make my nixdots more modular, there are a LOT of packages installed only to my laptop when they should be shared! +## Next Up +0. Rename TODO -> TODO.md +1. Rename user "ae" to "cry" or "vps" +2. Add 404 page to nginx on hyrule +3. Add a user called "mirror" that stores important mirrors (inspiration: https://git.gay/mirror) +## TODO +SOON: fix having to keep specifying new sha256 for home-manager (where I fetchTarball for it) Create a command palette accessible with MOD+P (MOD => Windows Key) (ie make fullscreen, send to monitor, etc) - Boring stuff (ie work and uni should go on a separate user account) + on in some separate $HOME atleast +Is home-manager installed standalone? If so please remove that... -### LATEST -1. Clean hosts/hyrule/default.nix -2. Rename user "ae" to "cry" or "vps" -3. Add 404 page to nginx on hyrule +Rewrite the README.md file its all over the place (add more structure to the `docs` directory instead) +Add a MAC Changer module like +https://github.com/XNM1/linux-nixos-hyprland-config-dotfiles/blob/main/nixos/mac-randomize.nix -INSPIRATION: -1. https://github.com/sabrehagen/desktop-environment +Make each monitor's window styling slightly different (just for fun) + +Bind 5 workspaces per connected monitor. + Then use the command palette (discussed prior) to send to + a different workspace (ie because I currently use MOD+SHIFT+n + but if n>=10 then it doesnt work! hence we need a command palette!) diff --git a/TODO.LONG-TERM b/TODO.LONG-TERM deleted file mode 100755 index e1acf2e..0000000 --- a/TODO.LONG-TERM +++ /dev/null @@ -1,26 +0,0 @@ -Add a MAC Changer module like -https://github.com/XNM1/linux-nixos-hyprland-config-dotfiles/blob/main/nixos/mac-randomize.nix - -Really good security oriented NixOS stuff can be found on that repo above (XNM1/linux-nixos-hyprland-config-dotfiles) - - - -Have multiple colour schemes in my system, one that's dark (good for when there's no external lighting), -and another that's lighter (but not white) for when my windows are open). - - -### Incredible Rofi Theme Collection -https://github.com/adi1090x/rofi -https://jade.fyi/blog/flakes-arent-real/ - - - -Make each monitor's window styling slightly different (just for fun) - -Bind 5 workspaces per connected monitor. - Then use the command palette (discussed prior) to send to - a different workspace (ie because I currently use MOD+SHIFT+n - but if n>=10 then it doesnt work! hence we need a command palette!) - - - diff --git a/TODO.SPECIFIC b/TODO.SPECIFIC deleted file mode 100644 index 49ae64e..0000000 --- a/TODO.SPECIFIC +++ /dev/null @@ -1,4 +0,0 @@ -- [ ] Try using `gitHashes` argument instead of patching? (on chameleonultragui package) -- [ ] Don't alias ripgrep to rip, download the rip util too (its cool) - https://github.com/nivekuil/rip - diff --git a/hosts/packages/chameleonultragui/TODO b/hosts/packages/chameleonultragui/TODO new file mode 100644 index 0000000..5b49da7 --- /dev/null +++ b/hosts/packages/chameleonultragui/TODO @@ -0,0 +1 @@ +- [ ] Try using `gitHashes` argument instead of patching? (on chameleonultragui package) From 8613df22fd6f7710001ab77bad5aca3333292936 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:29:29 +1000 Subject: [PATCH 070/197] chmod -x file.nix file.lock (why are these executable too??) --- flake.lock | 0 flake.nix | 0 2 files changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 flake.lock mode change 100755 => 100644 flake.nix diff --git a/flake.lock b/flake.lock old mode 100755 new mode 100644 diff --git a/flake.nix b/flake.nix old mode 100755 new mode 100644 From 97d6d8919c23530089ca1e5e5351ad0f512051d4 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:30:04 +1000 Subject: [PATCH 071/197] update+reorganise README.md --- README.md | 59 ++++++++++++++++++++++++------------------------------- 1 file changed, 26 insertions(+), 33 deletions(-) mode change 100755 => 100644 README.md diff --git a/README.md b/README.md old mode 100755 new mode 100644 index ce2a13b..87a9594 --- a/README.md +++ b/README.md @@ -1,11 +1,8 @@ +## My NixOS Flake ### Philosophy -I try to use Home Manager as little as possible. When I first started with NixOS I found -it distracting and confusing. NixOS already handles system wide and user packages, so having -another user level package management method was baffling. Obviously I understand now how -it can be useful (so I do use it). But where possible I will instead use the functionality -of Nix rather than Home Manager. +> [!TODO] My philosophy has kinda changed since the beginning -###### Structuring Modules +###### Repo Structure Modules are organised into groups (ie "Core"), from here a module is structured as either: 1. a single `.nix` file (ie bluetooth.nix). I do this when I won't implement an alternative 2. a directory (ie `sound`) containing a set of alternative implementations and a `default.nix` @@ -13,15 +10,14 @@ that simply imports one of the implementations. For the `sound` example I curren to default to `pipewire.nix`. I haven't made alternatives yet but the idea is that it is HIGHLY likely I do in future. - ### TODO -There are a lot of `TODO` items in this repository. To improve these dotfiles -I should run a command to find files containing "TODO" and then implement the -recommendation I left behind :) +There are a lot of commented `# TODO: ...` items in this repository. +All (most) of my commented directives can be found via this pattern: +```sh +grep -rnE '^\s*(//|#)\s*[A-Z]*:\s*.+$' --exclude-dir=.git 2>/dev/null +``` - - -##### Small Explanation of Fonts +### Random Explanation of Fonts There are four types of fonts (to my knowledge at least): 1. serif (funny squigles / small elegant strokes included) 2. sans-serif (meaning "without serifs") @@ -33,19 +29,9 @@ Fun fact: on Android, the emojis you are seeing are part of the noto-emoji font For finding a font for programming I highly recommend trying https://www.codingfont.com/ -### My config - -Font: -Iosevka nerd font set as default/prefered font -Terminal uses IosevkaTerm nerd font - -Home-Manager: -I just to use home-manager standalone and not as a NixOS module, thus allowing -my dotfiles to also work on non-NixOS systems. - - - -### Explaining my Vision with r/unixporn posts +### Links +#### Inspiration +##### Explaining my Vision with r/unixporn posts I want the side panel from https://www.reddit.com/r/unixporn/comments/12wpvyf/hyprland_eww_is_all_i_need/ but not the colour scheme and I'm 50/50 on the bar being on th eleft side lol. Also I love the volume bar on the right! @@ -64,22 +50,29 @@ Their window decorations and bar are great, also being able to hide everything u https://www.reddit.com/r/unixporn/comments/vkcasz/i3gaps_i_prefer_light_mode/ If their colour scheme was a little less white I'd love it but overall one of my favourites every +##### Other Inspiring Shtuff +1. https://github.com/sabrehagen/desktop-environment -### Wallpaper Sources +#### Wallpaper Sources 1. https://www.wallpaperflare.com/ 2. https://alphacoders.com especially this one person: https://alphacoders.com/users/profile/69089/robokoboto and also the lofi category: https://alphacoders.com/lofi +#### Teach Yourself Nix +1. https://github.com/XNM1/linux-nixos-hyprland-config-dotfiles) + Really good security oriented NixOS stuff +2. https://jade.fyi/blog/flakes-arent-real/ + Interesting blog post on using flakes -### Credits +#### Credits 1. https://github.com/XNM1/linux-nixos-hyprland-config-dotfiles -The simplicity of their layout is amazing, was really good to pick out small modules and learn how something works / is configured. + The simplicity of their layout is amazing, was really good to pick out small modules and learn how something works / is configured. 2. https://github.com/Misterio77/nix-starter-configs -Really great starter config for learning how parts interact and how to generally structure flakes + Really great starter config for learning how parts interact and how to generally structure flakes 3. https://nixos.wiki/wiki/Fonts -Wiki page explaining how to install fonts and nerd fonts on NixOS + Wiki page explaining how to install fonts and nerd fonts on NixOS 4. https://github.com/adi1090x/rofi -For the Rofi theme + For the Rofi theme 5. https://github.com/zDyanTB/HyprNova -For the really cool hyprlock theme + For the really cool hyprlock theme From 83b7f2650ada1f9cfab9bdb4391f9fccd14503d0 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:31:12 +1000 Subject: [PATCH 072/197] remove paswordless sudo from ae@hyrule --- hosts/hyrule/default.nix | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index dc5cfb2..04dd0ad 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -72,8 +72,6 @@ in { }; }; - security.sudo.wheelNeedsPassword = false; - users = { defaultUserShell = pkgs.bash; @@ -418,9 +416,10 @@ in { defaults.email = "eclarkboman@gmail.com"; }; + sudo.wheelNeedsPassword = true; # allow SSH keys for passwordless auth # TODO: DO NOT USE THIS (create my own alternative to colmena) - pam.services.sudo.sshAgentAuth = true; + pam.services.sudo.sshAgentAuth = true; # pam_ssh_agent_auth module }; environment.systemPackages = with pkgs; [ From 7304fa0f51ed5f3813a9e681e4d8796678d25e3d Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 26 Jul 2025 18:37:50 +1000 Subject: [PATCH 073/197] add shellshock and go also reorganise lang section --- hosts/lolcathost/default.nix | 29 ++++++++++++++++++++--------- 1 file changed, 20 insertions(+), 9 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 599e295..cfb1adb 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -2,6 +2,7 @@ lib, pkgs, inputs, + config, ... }: let home-manager = builtins.fetchTarball { @@ -223,13 +224,27 @@ in { # dependencies for my sddm theme: pkgs.libsForQt5.qt5.qtgraphicaleffects + # Shell + shellcheck + # Fish Plugins + grc # colorise command outputs + + # C Family + gcc + clang + # Rust + cargo + rustc + # Nim + nim + # Go + go + + # Python python312 # I use 3.12 since it's in a pretty stable state now python314 # also 3.14 for latest features - poetry # python dependency management and packaging - clang-tools - - nim - + poetry + # Sage sageWithDoc # SageMath + HTML Documentation # DEBUG: using neofetch temporarily to see if my system upgrades properly @@ -246,9 +261,6 @@ in { nth zap - # fish plugins - grc # colorise command outputs - httpie curlie zoxide @@ -275,7 +287,6 @@ in { # upower vim powertop - gcc gnumake imagemagick From 0a557e7195cc3904e53793aa57796a7a315c25c6 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 27 Jul 2025 22:21:30 +1000 Subject: [PATCH 074/197] add todo: can openvpn run for LXC? --- TODO | 3 +++ 1 file changed, 3 insertions(+) diff --git a/TODO b/TODO index 2c1e045..20d65c3 100644 --- a/TODO +++ b/TODO @@ -26,3 +26,6 @@ Bind 5 workspaces per connected monitor. Then use the command palette (discussed prior) to send to a different workspace (ie because I currently use MOD+SHIFT+n but if n>=10 then it doesnt work! hence we need a command palette!) + +Can I run openvpn only for a specific proccess and its children? + then ie run qbittorrent (just in case the VPN isnt private) From 531122d9b63f36c90a463ee2099d369ea123e079 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 27 Jul 2025 22:22:13 +1000 Subject: [PATCH 075/197] add base of my webdev script --- scripts/webdev | 61 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 scripts/webdev diff --git a/scripts/webdev b/scripts/webdev new file mode 100644 index 0000000..85e725c --- /dev/null +++ b/scripts/webdev @@ -0,0 +1,61 @@ +#!/usr/bin/env bash +USAGE="Usage: webdev [-q|--quiet] uri|file" + +# NOTE: These can either be set manually here or they +# NOTE: can be exported as environment variables (^-^) +# === Configuration === # +DEFAULT_BROWSER=${DEFAULT_BROWSER:-} +# ===================== # + +# WARNING: Internal use only (do not modify!) +# === Internal Environment === # +QUIET=false +# ============================ # + +# Quiet Echo - doesn't echo if QUIET is set +qecho() { + if [[ "$QUIET" == false ]]; then + echo "$@" + fi +} + +# Argument Parsing +for OPT in $@; do + case $OPT in + -q|--quiet) + QUIET=true + ;; + -*) + echo -e "[!] Unknown option \"$OPT\"\n$USAGE" >2 + exit 1 + ;; + *) + echo "[!] Unknown option \"$OPT\"\n$USAGE" >2 + exit 1 + ;; + esac +done + +# Use DEFAULT_BROWSER or check XDG default-web-browser or fail +BROWSER="" +if [ -n "$DEFAULT_BROWSER" ]; then + echo "[+] Browser manually set to $DEFAULT_BROWSER" + echo " > Skipped checking XDG default-web-browser" +else + echo "[*] Lookup XDG default-web-browser" + BROWSER=$(xdg-settings get default-web-browser 2>/dev/null) + if [ $? -eq 0 ]; then + BROWSER=${BROWSER%%.desktop} + echo "[+] Browser automatically set to $BROWSER" + else + echo "[!] Unknown browser girlypop :(" >2 + echo " > Either:" >2 + echo " > 1. export DEFAULT_BROWSER" >2 + echo " > 2. run \`xdg-settings set default-web-browser\`" >2 + exit 1 + fi +fi +echo # linebreak + + + From 8cee3dec34eeb02d3d8d03148836eceeea948977 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 27 Jul 2025 22:54:21 +1000 Subject: [PATCH 076/197] make webdev script open file or uri in browser --- scripts/webdev | 44 ++++++++++++++++++++++++++++++-------------- 1 file changed, 30 insertions(+), 14 deletions(-) mode change 100644 => 100755 scripts/webdev diff --git a/scripts/webdev b/scripts/webdev old mode 100644 new mode 100755 index 85e725c..6596def --- a/scripts/webdev +++ b/scripts/webdev @@ -10,6 +10,9 @@ DEFAULT_BROWSER=${DEFAULT_BROWSER:-} # WARNING: Internal use only (do not modify!) # === Internal Environment === # QUIET=false +BROWSER="" +LOC="" +LOC_TYPE="" # file or uri # ============================ # # Quiet Echo - doesn't echo if QUIET is set @@ -20,33 +23,41 @@ qecho() { } # Argument Parsing -for OPT in $@; do - case $OPT in +for ARG in $@; do + case $ARG in -q|--quiet) QUIET=true ;; -*) - echo -e "[!] Unknown option \"$OPT\"\n$USAGE" >2 + echo -e "[!] Unknown option \"$ARG\"\n$USAGE" >2 exit 1 ;; *) - echo "[!] Unknown option \"$OPT\"\n$USAGE" >2 - exit 1 + # first unknown (non-option) argument assumed $LOC + if [[ -n "$LOC" ]]; then + LOC="$OPT" + else + echo "[!] Unknown option \"$ARG\"\n$USAGE" >2 + exit 1 + fi ;; esac done +# ensure $LOC was set during argparse phase +if [[ -z "$LOC" ]]; then + echo -e "[!] URI or file not specified\n$USAGE" >2 +fi # Use DEFAULT_BROWSER or check XDG default-web-browser or fail -BROWSER="" -if [ -n "$DEFAULT_BROWSER" ]; then - echo "[+] Browser manually set to $DEFAULT_BROWSER" - echo " > Skipped checking XDG default-web-browser" +if [[ -n "$DEFAULT_BROWSER" ]]; then + qecho "[+] Browser manually set to $DEFAULT_BROWSER" + qecho " > Skipped checking XDG default-web-browser" else - echo "[*] Lookup XDG default-web-browser" + qecho "[*] Lookup XDG default-web-browser" BROWSER=$(xdg-settings get default-web-browser 2>/dev/null) - if [ $? -eq 0 ]; then + if [[ $? -eq 0 ]]; then BROWSER=${BROWSER%%.desktop} - echo "[+] Browser automatically set to $BROWSER" + qecho "[+] Browser automatically set to $BROWSER" else echo "[!] Unknown browser girlypop :(" >2 echo " > Either:" >2 @@ -57,5 +68,10 @@ else fi echo # linebreak - - +# Check if $LOC is a valid path +REALPATH=$(realpath "$LOC" 2>/dev/null) +if [ -f "$REALPATH"]; then + LOC="file://$LOC" # open file directly via "file" protocol +fi +# Substitutions left intentionally unquoted (allows for providing args) +command $BROWSER $LOC From 733b383a7ce6f437dabe315ce750aff19d54c164 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 27 Jul 2025 23:33:16 +1000 Subject: [PATCH 077/197] add two new fish banners (greetings) --- homes/modules/fish.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/homes/modules/fish.nix b/homes/modules/fish.nix index 95ad255..4e40d9c 100755 --- a/homes/modules/fish.nix +++ b/homes/modules/fish.nix @@ -19,8 +19,10 @@ function rand_greet set weary "Welcome weary traveller to my shop" + set alone "It's dangerous to go alone! Take this." set sad "Do butterflies cry when they're sad?" - set greetings "$weary" "$sad" + set alice "I think Alice is lost..." + set greetings "$weary" "$alone" "$sad" "$alice" echo -n $greetings[(random 1 (count $greetings))] end From 3d136d90f059ecc63d8016db09413da5b7f9f1b7 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 28 Jul 2025 22:55:44 +1000 Subject: [PATCH 078/197] fix webdev script bad redirect + add --help --- scripts/webdev | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/scripts/webdev b/scripts/webdev index 6596def..9754cdc 100755 --- a/scripts/webdev +++ b/scripts/webdev @@ -1,5 +1,5 @@ #!/usr/bin/env bash -USAGE="Usage: webdev [-q|--quiet] uri|file" +USAGE="Usage: webdev [-h|--help] [-q|--quiet] uri|file" # NOTE: These can either be set manually here or they # NOTE: can be exported as environment variables (^-^) @@ -25,11 +25,15 @@ qecho() { # Argument Parsing for ARG in $@; do case $ARG in + -h|--help) + echo "$USAGE" + exit 0 + ;; -q|--quiet) QUIET=true ;; -*) - echo -e "[!] Unknown option \"$ARG\"\n$USAGE" >2 + echo -e "[!] Unknown option \"$ARG\"\n$USAGE" >&2 exit 1 ;; *) @@ -37,7 +41,7 @@ for ARG in $@; do if [[ -n "$LOC" ]]; then LOC="$OPT" else - echo "[!] Unknown option \"$ARG\"\n$USAGE" >2 + echo "[!] Unknown option \"$ARG\"\n$USAGE" >&2 exit 1 fi ;; @@ -45,7 +49,7 @@ for ARG in $@; do done # ensure $LOC was set during argparse phase if [[ -z "$LOC" ]]; then - echo -e "[!] URI or file not specified\n$USAGE" >2 + echo -e "[!] URI or file not specified\n$USAGE" >&2 fi # Use DEFAULT_BROWSER or check XDG default-web-browser or fail @@ -59,10 +63,10 @@ else BROWSER=${BROWSER%%.desktop} qecho "[+] Browser automatically set to $BROWSER" else - echo "[!] Unknown browser girlypop :(" >2 - echo " > Either:" >2 - echo " > 1. export DEFAULT_BROWSER" >2 - echo " > 2. run \`xdg-settings set default-web-browser\`" >2 + echo "[!] Unknown browser girlypop :(" >&2 + echo " > Either:" >&2 + echo " > 1. export DEFAULT_BROWSER" >&2 + echo " > 2. run \`xdg-settings set default-web-browser\`" >&2 exit 1 fi fi From 999be39b3623ea446f546c498b3e5f3dde957c3a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 14:03:00 +1000 Subject: [PATCH 079/197] fix default devShell --- flake.nix | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/flake.nix b/flake.nix index 3a8be4e..7a23be2 100644 --- a/flake.nix +++ b/flake.nix @@ -43,15 +43,16 @@ allowUnfree = false; # sanity check }; }; - # TODO: come back to this its really cool # this is just something I'm experimenting with - PROJECT_ROOT = builtins.toString ./.; + # PROJECT_ROOT = builtins.toString ./.; in { - # `nix develop` shell devShells."x86_64-linux".default = pkgs.mkShell { - buildInputs = [ - #colmena-new + shell = "${pkgs.bash}/bin/bash"; + + packages = with pkgs; [ + # ./script/* dependencies + mkpasswd ]; }; From 2d529a46d5a4de1a8fdd8287b7d2ec4e9bf63930 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 14:05:05 +1000 Subject: [PATCH 080/197] swww use nixpkgs not flake dependency --- flake.nix | 2 -- hosts/lolcathost/default.nix | 2 +- hosts/myputer/default.nix | 2 +- 3 files changed, 2 insertions(+), 4 deletions(-) diff --git a/flake.nix b/flake.nix index 7a23be2..d449392 100644 --- a/flake.nix +++ b/flake.nix @@ -19,8 +19,6 @@ # is this necessary? (aren't I enabling it in `configuration.nix` anyways?) hyprland.url = "github:hyprwm/Hyprland"; - swww.url = "github:LGFae/swww"; - ags.url = "github:Aylur/ags"; colmena.url = "github:zhaofengli/colmena/?rev=47b6414d800c8471e98ca072bc0835345741a56a"; diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index cfb1adb..86f39e5 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -210,7 +210,7 @@ in { # ---- SYSTEM PACKAGES ----- environment.systemPackages = with pkgs; [ # User Environment - inputs.swww.packages.${pkgs.system}.swww + swww helvum easyeffects ani-cli diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index bd85eb5..0aba69e 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -191,7 +191,7 @@ in { # ---- SYSTEM PACKAGES ----- environment.systemPackages = with pkgs; [ # User Environment - inputs.swww.packages.${pkgs.system}.swww + swww helvum easyeffects pavucontrol From da63d4a2bebc9468a06f48d7c7a04a83d591d884 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 14:06:22 +1000 Subject: [PATCH 081/197] remove spicetify from repo --- flake.nix | 5 ----- hosts/lolcathost/default.nix | 15 --------------- hosts/myputer/default.nix | 14 -------------- 3 files changed, 34 deletions(-) diff --git a/flake.nix b/flake.nix index d449392..fc69002 100644 --- a/flake.nix +++ b/flake.nix @@ -9,11 +9,6 @@ # inputs.nixpkgs.follows = "nixpkgs"; #}; - spicetify-nix = { - url = "github:Gerg-L/spicetify-nix"; - inputs.nixpkgs.follows = "nixpkgs"; - }; - grub2-themes.url = "github:vinceliuice/grub2-themes"; # is this necessary? (aren't I enabling it in `configuration.nix` anyways?) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 86f39e5..e3a67eb 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -13,7 +13,6 @@ in { imports = [ ./hardware-configuration.nix (import "${home-manager}/nixos") - # inputs.spicetify-nix.nixosModules.default ../modules/steam.nix ../modules/obsidian.nix @@ -30,25 +29,11 @@ in { pkgs.steam pkgs.steamcmd pkgs.steam-unwrapped - pkgs.spotify pkgs.dwarf-fortress ]; in pkg: builtins.elem (lib.getName pkg) whitelist; - # programs.spicetify = let - # spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system}; - # in { - # enable = true; - # enabledExtensions = with spicePkgs.extensions; [ - # adblock - # hidePodcasts - # shuffle # shuffle+ (special characters are sanitized out of extension names) - # ]; - # #theme = spicePkgs.themes.catppuccin; - # #colorScheme = "mocha"; - # }; - boot.loader = { efi = { canTouchEfiVariables = true; diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 0aba69e..42f32f5 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -13,24 +13,10 @@ in { imports = [ ./hardware-configuration.nix (import "${home-manager}/nixos") - inputs.spicetify-nix.nixosModules.default ../modules/steam.nix ]; - programs.spicetify = let - spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system}; - in { - enable = true; - enabledExtensions = with spicePkgs.extensions; [ - adblock - hidePodcasts - shuffle # shuffle+ (special characters are sanitized out of extension names) - ]; - #theme = spicePkgs.themes.catppuccin; - #colorScheme = "mocha"; - }; - boot.loader.systemd-boot.enable = false; boot.loader = { efi = { From 0a231108eb91d0f2b606c93433e4178ea4a0581a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 14:09:56 +1000 Subject: [PATCH 082/197] source hyprland from nixpkgs not flake dependency also implements recommendation that hyprland.withUSWM be enabled --- flake.nix | 3 --- hosts/lolcathost/default.nix | 5 +---- hosts/myputer/default.nix | 5 +---- 3 files changed, 2 insertions(+), 11 deletions(-) diff --git a/flake.nix b/flake.nix index fc69002..b538d4a 100644 --- a/flake.nix +++ b/flake.nix @@ -11,9 +11,6 @@ grub2-themes.url = "github:vinceliuice/grub2-themes"; - # is this necessary? (aren't I enabling it in `configuration.nix` anyways?) - hyprland.url = "github:hyprwm/Hyprland"; - ags.url = "github:Aylur/ags"; colmena.url = "github:zhaofengli/colmena/?rev=47b6414d800c8471e98ca072bc0835345741a56a"; diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index e3a67eb..0fad2e7 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -291,13 +291,10 @@ in { prismlauncher # minecraft ]; - # Enable the use of certain programs programs = { hyprland = { enable = true; - #package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; - #portalPackage = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland; - + withUWSM = true; # Universal Wayland Session Manager xwayland.enable = true; }; diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 42f32f5..3bb4736 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -261,10 +261,7 @@ in { programs = { hyprland = { enable = true; - # TODO: uncomment, I did this when hyprland wasn't working - #package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; - #portalPackage = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland; - + withUWSM = true; # Universal Wayland Session Manager xwayland.enable = true; }; From 3eef80123d2f9f4314bac67aef67ac59553675b6 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 14:11:03 +1000 Subject: [PATCH 083/197] update vaultwarden signup policy --- hosts/hyrule/default.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 04dd0ad..465d4c0 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -198,7 +198,11 @@ in { # hostname to listen for DOMAIN = "https://vault.imbored.dev"; + + # signup policy SIGNUPS_ALLOWED = false; + SIGNUPS_VERIFY = true; + INVITATIONS_ALLOWED = true; }; # https://mynixos.com/nixpkgs/option/services.vaultwarden.environmentFile environmentFile = "/var/lib/vaultwarden/vaultwarden.env"; From 7c0f73beb86ca5007509aea0c4b5916bb65a783f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 14:11:27 +1000 Subject: [PATCH 084/197] rename forgejo banner to "tearforge" --- hosts/hyrule/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 465d4c0..12c96ab 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -295,7 +295,7 @@ in { }; DEFAULT = { - APP_NAME = "Do butterflies cry when they're sad?"; + APP_NAME = "tearforge"; APP_SLOGIN = "but cozy"; APP_DISPLAY_NAME_FORMAT = "{APP_NAME} ::{APP_SLOGAN}::"; }; @@ -349,7 +349,7 @@ in { # When set to “true”, the installation page is not accessible. #INSTALL_LOCK = false; - PASSWORD_HASH_ALGO = "argon2"; # ARGON2 BEST ALGO FR!! + PASSWORD_HASH_ALGO = "argon2"; # ARGON2 BEST ALGO FR!! (default: argon2$2$65536$8$50) MIN_PASSWORD_LENGTH = 12; PASSWORD_COMPLEXITY = "lower,upper,digit,spec"; PASSWORD_CHECK_PWN = true; From bad1cbbe8ca3bfd4b2c792cd57b5933edad82d4c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 14:11:56 +1000 Subject: [PATCH 085/197] add Security+Hashing sections to README.md --- README.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 87a9594..36d887e 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ ### Philosophy > [!TODO] My philosophy has kinda changed since the beginning -###### Repo Structure +### Repo Structure Modules are organised into groups (ie "Core"), from here a module is structured as either: 1. a single `.nix` file (ie bluetooth.nix). I do this when I won't implement an alternative 2. a directory (ie `sound`) containing a set of alternative implementations and a `default.nix` @@ -10,6 +10,11 @@ that simply imports one of the implementations. For the `sound` example I curren to default to `pipewire.nix`. I haven't made alternatives yet but the idea is that it is HIGHLY likely I do in future. +### Security Considerations +###### Hashing +For services where password hashing is done infrequently (ie my forgejo instance with signups disabled) +use argon2 (argon2id) with default `argon2$2$65536$8$50` (typically). Otherwise bcrypt is preferred. + ### TODO There are a lot of commented `# TODO: ...` items in this repository. All (most) of my commented directives can be found via this pattern: From 230af2eca4954d884edc01b2387dcab2d866d68c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 14:12:26 +1000 Subject: [PATCH 086/197] add template simple-nixos-mailserver config --- hosts/hyrule/mailserver.nix | 39 +++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 hosts/hyrule/mailserver.nix diff --git a/hosts/hyrule/mailserver.nix b/hosts/hyrule/mailserver.nix new file mode 100644 index 0000000..c5556f2 --- /dev/null +++ b/hosts/hyrule/mailserver.nix @@ -0,0 +1,39 @@ +{ + config, + pkgs, + ... +}: { + imports = [ + (builtins.fetchTarball { + url = "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/archive/nixos-25.05/nixos-mailserver-nixos-25.05.tar.gz"; + # release="nixos-25.05"; nix-prefetch-url "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/archive/${release}/nixos-mailserver-${release}.tar.gz" --unpack + sha256 = "0000000000000000000000000000000000000000000000000000"; + }) + ]; + + # simple-nixos-mailserver + # DOCS: https://nixos-mailserver.readthedocs.io/en/latest + mailserver = { + enable = true; + stateVersion = 3; + # Manually open the firewall instead + openFirewall = false; + virusScanning = false; # expensive memory usage + + fqdn = "mail.imbored.dev"; + domains = ["imbored.dev"]; + + # A list of all login accounts. To create the password hashes, use + # nix-shell -p mkpasswd --run 'mkpasswd -sm bcrypt' + loginAccounts = { + "me@imbored.dev" = { + hashedPasswordFile = "/a/file/containing/a/hashed/password"; + aliases = ["emile@imbored.dev"]; + }; + }; + + # Use Let's Encrypt certificates. Note that this needs to set up a stripped + # down nginx and opens port 80. + certificateScheme = "acme-nginx"; + }; +} From c6ced19dee6df7731de022965da801c1222b162b Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 16:10:53 +1000 Subject: [PATCH 087/197] remove hyprland flake input --- flake.nix | 2 -- 1 file changed, 2 deletions(-) diff --git a/flake.nix b/flake.nix index b538d4a..cb9b457 100644 --- a/flake.nix +++ b/flake.nix @@ -19,8 +19,6 @@ outputs = { self, nixpkgs, - #home-manager, - hyprland, grub2-themes, colmena, ... From f32b784ed7106f16147f7ff12d3da79542446c3a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 16:11:19 +1000 Subject: [PATCH 088/197] progress flake.lock to latest build --- flake.lock | 470 +---------------------------------------------------- 1 file changed, 1 insertion(+), 469 deletions(-) diff --git a/flake.lock b/flake.lock index c06c8b0..7f15c41 100644 --- a/flake.lock +++ b/flake.lock @@ -19,39 +19,6 @@ "type": "github" } }, - "aquamarine": { - "inputs": { - "hyprutils": [ - "hyprland", - "hyprutils" - ], - "hyprwayland-scanner": [ - "hyprland", - "hyprwayland-scanner" - ], - "nixpkgs": [ - "hyprland", - "nixpkgs" - ], - "systems": [ - "hyprland", - "systems" - ] - }, - "locked": { - "lastModified": 1730968822, - "narHash": "sha256-NocDjINsh6ismkhb0Xr6xPRksmhuB2WGf8ZmXMhxu7Y=", - "owner": "hyprwm", - "repo": "aquamarine", - "rev": "a49bc3583ff223f426cb3526fdaa4bcaa247ec14", - "type": "github" - }, - "original": { - "owner": "hyprwm", - "repo": "aquamarine", - "type": "github" - } - }, "colmena": { "inputs": { "flake-compat": "flake-compat", @@ -91,54 +58,6 @@ "type": "github" } }, - "flake-compat_2": { - "flake": false, - "locked": { - "lastModified": 1696426674, - "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-compat_3": { - "flake": false, - "locked": { - "lastModified": 1696426674, - "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-compat_4": { - "flake": false, - "locked": { - "lastModified": 1696426674, - "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, "flake-utils": { "locked": { "lastModified": 1659877975, @@ -154,28 +73,6 @@ "type": "github" } }, - "gitignore": { - "inputs": { - "nixpkgs": [ - "hyprland", - "pre-commit-hooks", - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1709087332, - "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=", - "owner": "hercules-ci", - "repo": "gitignore.nix", - "rev": "637db329424fd7e46cf4185293b9cc8c88c95394", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "repo": "gitignore.nix", - "type": "github" - } - }, "grub2-themes": { "inputs": { "nixpkgs": "nixpkgs_3" @@ -194,166 +91,6 @@ "type": "github" } }, - "hyprcursor": { - "inputs": { - "hyprlang": [ - "hyprland", - "hyprlang" - ], - "nixpkgs": [ - "hyprland", - "nixpkgs" - ], - "systems": [ - "hyprland", - "systems" - ] - }, - "locked": { - "lastModified": 1728669738, - "narHash": "sha256-EDNAU9AYcx8OupUzbTbWE1d3HYdeG0wO6Msg3iL1muk=", - "owner": "hyprwm", - "repo": "hyprcursor", - "rev": "0264e698149fcb857a66a53018157b41f8d97bb0", - "type": "github" - }, - "original": { - "owner": "hyprwm", - "repo": "hyprcursor", - "type": "github" - } - }, - "hyprland": { - "inputs": { - "aquamarine": "aquamarine", - "hyprcursor": "hyprcursor", - "hyprland-protocols": "hyprland-protocols", - "hyprlang": "hyprlang", - "hyprutils": "hyprutils", - "hyprwayland-scanner": "hyprwayland-scanner", - "nixpkgs": "nixpkgs_4", - "pre-commit-hooks": "pre-commit-hooks", - "systems": "systems_2", - "xdph": "xdph" - }, - "locked": { - "lastModified": 1730969692, - "narHash": "sha256-4Ly9zkqnRB6qLjMeddfUyd4iRLvq+RDspBWABS8DGN4=", - "owner": "hyprwm", - "repo": "Hyprland", - "rev": "e58e97b0a38b8ccc87a4304c9e4e2b37c9966875", - "type": "github" - }, - "original": { - "owner": "hyprwm", - "repo": "Hyprland", - "type": "github" - } - }, - "hyprland-protocols": { - "inputs": { - "nixpkgs": [ - "hyprland", - "nixpkgs" - ], - "systems": [ - "hyprland", - "systems" - ] - }, - "locked": { - "lastModified": 1728345020, - "narHash": "sha256-xGbkc7U/Roe0/Cv3iKlzijIaFBNguasI31ynL2IlEoM=", - "owner": "hyprwm", - "repo": "hyprland-protocols", - "rev": "a7c183800e74f337753de186522b9017a07a8cee", - "type": "github" - }, - "original": { - "owner": "hyprwm", - "repo": "hyprland-protocols", - "type": "github" - } - }, - "hyprlang": { - "inputs": { - "hyprutils": [ - "hyprland", - "hyprutils" - ], - "nixpkgs": [ - "hyprland", - "nixpkgs" - ], - "systems": [ - "hyprland", - "systems" - ] - }, - "locked": { - "lastModified": 1728168612, - "narHash": "sha256-AnB1KfiXINmuiW7BALYrKqcjCnsLZPifhb/7BsfPbns=", - "owner": "hyprwm", - "repo": "hyprlang", - "rev": "f054f2e44d6a0b74607a6bc0f52dba337a3db38e", - "type": "github" - }, - "original": { - "owner": "hyprwm", - "repo": "hyprlang", - "type": "github" - } - }, - "hyprutils": { - "inputs": { - "nixpkgs": [ - "hyprland", - "nixpkgs" - ], - "systems": [ - "hyprland", - "systems" - ] - }, - "locked": { - "lastModified": 1730968903, - "narHash": "sha256-zFvzLXcSm0Ia4XI1SE4FQ9KE63hlGrRWhLtwMolWuR8=", - "owner": "hyprwm", - "repo": "hyprutils", - "rev": "3ce0cde8709cdacbfba471f8e828433b58a561e9", - "type": "github" - }, - "original": { - "owner": "hyprwm", - "repo": "hyprutils", - "type": "github" - } - }, - "hyprwayland-scanner": { - "inputs": { - "nixpkgs": [ - "hyprland", - "nixpkgs" - ], - "systems": [ - "hyprland", - "systems" - ] - }, - "locked": { - "lastModified": 1726874836, - "narHash": "sha256-VKR0sf0PSNCB0wPHVKSAn41mCNVCnegWmgkrneKDhHM=", - "owner": "hyprwm", - "repo": "hyprwayland-scanner", - "rev": "500c81a9e1a76760371049a8d99e008ea77aa59e", - "type": "github" - }, - "original": { - "owner": "hyprwm", - "repo": "hyprwayland-scanner", - "type": "github" - } - }, "nix-github-actions": { "inputs": { "nixpkgs": [ @@ -391,22 +128,6 @@ "type": "github" } }, - "nixpkgs-stable": { - "locked": { - "lastModified": 1730741070, - "narHash": "sha256-edm8WG19kWozJ/GqyYx2VjW99EdhjKwbY3ZwdlPAAlo=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "d063c1dd113c91ab27959ba540c0d9753409edf3", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-24.05", - "repo": "nixpkgs", - "type": "github" - } - }, "nixpkgs_2": { "locked": { "lastModified": 1734119587, @@ -440,22 +161,6 @@ } }, "nixpkgs_4": { - "locked": { - "lastModified": 1730785428, - "narHash": "sha256-Zwl8YgTVJTEum+L+0zVAWvXAGbWAuXHax3KzuejaDyo=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "4aa36568d413aca0ea84a1684d2d46f55dbabad7", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_5": { "locked": { "lastModified": 1752620740, "narHash": "sha256-f3pO+9lg66mV7IMmmIqG4PL3223TYMlnlw+pnpelbss=", @@ -471,76 +176,12 @@ "type": "github" } }, - "nixpkgs_6": { - "locked": { - "lastModified": 1730200266, - "narHash": "sha256-l253w0XMT8nWHGXuXqyiIC/bMvh1VRszGXgdpQlfhvU=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "807e9154dcb16384b1b765ebe9cd2bba2ac287fd", - "type": "github" - }, - "original": { - "owner": "nixos", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "pre-commit-hooks": { - "inputs": { - "flake-compat": "flake-compat_2", - "gitignore": "gitignore", - "nixpkgs": [ - "hyprland", - "nixpkgs" - ], - "nixpkgs-stable": "nixpkgs-stable" - }, - "locked": { - "lastModified": 1730814269, - "narHash": "sha256-fWPHyhYE6xvMI1eGY3pwBTq85wcy1YXqdzTZF+06nOg=", - "owner": "cachix", - "repo": "git-hooks.nix", - "rev": "d70155fdc00df4628446352fc58adc640cd705c2", - "type": "github" - }, - "original": { - "owner": "cachix", - "repo": "git-hooks.nix", - "type": "github" - } - }, "root": { "inputs": { "ags": "ags", "colmena": "colmena", "grub2-themes": "grub2-themes", - "hyprland": "hyprland", - "nixpkgs": "nixpkgs_5", - "spicetify-nix": "spicetify-nix", - "swww": "swww" - } - }, - "spicetify-nix": { - "inputs": { - "flake-compat": "flake-compat_3", - "nixpkgs": [ - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1730780158, - "narHash": "sha256-ZJkCFn4PL49rINz7xrjlBqw9nF8wWJE7fSVqbHlCWSA=", - "owner": "Gerg-L", - "repo": "spicetify-nix", - "rev": "2791c6662002731d3dfc00312307aef547e1c8be", - "type": "github" - }, - "original": { - "owner": "Gerg-L", - "repo": "spicetify-nix", - "type": "github" + "nixpkgs": "nixpkgs_4" } }, "stable": { @@ -559,26 +200,6 @@ "type": "github" } }, - "swww": { - "inputs": { - "flake-compat": "flake-compat_4", - "nixpkgs": "nixpkgs_6", - "utils": "utils" - }, - "locked": { - "lastModified": 1730424990, - "narHash": "sha256-+8YUJsNzvgAeZYLfbHYfYlad/iS+6Eec/LWzL1ZIGfY=", - "owner": "LGFae", - "repo": "swww", - "rev": "0db3f4eb192f1c9bf914efcc1d2aba809da5d78a", - "type": "github" - }, - "original": { - "owner": "LGFae", - "repo": "swww", - "type": "github" - } - }, "systems": { "locked": { "lastModified": 1689347949, @@ -593,95 +214,6 @@ "repo": "default-linux", "type": "github" } - }, - "systems_2": { - "locked": { - "lastModified": 1689347949, - "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", - "owner": "nix-systems", - "repo": "default-linux", - "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default-linux", - "type": "github" - } - }, - "systems_3": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } - }, - "utils": { - "inputs": { - "systems": "systems_3" - }, - "locked": { - "lastModified": 1726560853, - "narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "c1dfcf08411b08f6b8615f7d8971a2bfa81d5e8a", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "xdph": { - "inputs": { - "hyprland-protocols": [ - "hyprland", - "hyprland-protocols" - ], - "hyprlang": [ - "hyprland", - "hyprlang" - ], - "hyprutils": [ - "hyprland", - "hyprutils" - ], - "hyprwayland-scanner": [ - "hyprland", - "hyprwayland-scanner" - ], - "nixpkgs": [ - "hyprland", - "nixpkgs" - ], - "systems": [ - "hyprland", - "systems" - ] - }, - "locked": { - "lastModified": 1730743262, - "narHash": "sha256-iTLqj3lU8kFehPm5tXpctzkD274t/k1nwSSq3qCWXeg=", - "owner": "hyprwm", - "repo": "xdg-desktop-portal-hyprland", - "rev": "09b23cef06fe248e61cec8862c04b9bcb62f4b6d", - "type": "github" - }, - "original": { - "owner": "hyprwm", - "repo": "xdg-desktop-portal-hyprland", - "type": "github" - } } }, "root": "root", From 8661d198b22d2554db65976e9162c7109398f501 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 16:14:00 +1000 Subject: [PATCH 089/197] fix sudo not accessible via pam ssh module (hyrule) --- hosts/hyrule/default.nix | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 12c96ab..a21a5ac 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -41,6 +41,9 @@ in { targetHost = "imbored.dev"; targetUser = "ae"; targetPort = 22; + sshOptions = [ + "-A" # forward ssh-agent + ]; buildOnTarget = false; # build locally then deploy }; @@ -420,10 +423,16 @@ in { defaults.email = "eclarkboman@gmail.com"; }; - sudo.wheelNeedsPassword = true; + sudo = { + enable = true; + wheelNeedsPassword = true; + }; # allow SSH keys for passwordless auth # TODO: DO NOT USE THIS (create my own alternative to colmena) - pam.services.sudo.sshAgentAuth = true; # pam_ssh_agent_auth module + pam = { + enableSSHAgentAuth = true; + services.sudo.sshAgentAuth = true; # pam_ssh_agent_auth module + }; }; environment.systemPackages = with pkgs; [ From fe2a8f6837eb8f39f335b7d1f16b41383597602c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 29 Jul 2025 16:16:14 +1000 Subject: [PATCH 090/197] disable ssh.forwardAgent and addKeysToAgent as defaults --- homes/me/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/homes/me/default.nix b/homes/me/default.nix index 170bc6d..3ef0dda 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -93,8 +93,8 @@ # for that you need to use `services.ssh-agent.enable` ssh = { enable = true; - forwardAgent = true; - addKeysToAgent = "yes"; # always add keys to ssh-agent + forwardAgent = false; + addKeysToAgent = "no"; matchBlocks = { hyrule = { From d0cc0504fa5e8cfe69a6359c573ff71db21c17a5 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 1 Aug 2025 12:32:20 +1000 Subject: [PATCH 091/197] fixed myputer still on home-manager 24.11 channel --- hosts/myputer/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 3bb4736..5e172a9 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -6,7 +6,7 @@ ... }: let home-manager = builtins.fetchTarball { - url = "https://github.com/nix-community/home-manager/archive/release-24.11.tar.gz"; + url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; sha256 = "1kk5qzfb87mkgy6vzm7x8z8akxr3k8k7839yjdy48z034pvidhsr"; }; in { From af31d0273c45ca8c08091b27d49780868d6418aa Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 1 Aug 2025 12:32:52 +1000 Subject: [PATCH 092/197] clean /default.nix comments --- hosts/lolcathost/default.nix | 19 +++++++++---------- hosts/myputer/default.nix | 18 +++++++++--------- 2 files changed, 18 insertions(+), 19 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 0fad2e7..4f82c58 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -88,14 +88,12 @@ in { }; # ----- NETWORKING SECTION ----- - networking.hostName = "lolcathost"; - networking.networkmanager.enable = true; + networking = { + hostName = "lolcathost"; + networkmanager.enable = true; - # Open ports in the firewall. - #networking.firewall.allowedTCPPorts = [ ... ]; - # networking.firewall.allowedUDPPorts = [ ... ]; - # Or disable the firewall altogether. - networking.firewall.enable = false; + firewall.enable = false; + }; # ----- SERVICES ----- services = { @@ -104,13 +102,14 @@ in { # sddm relies on pkgs.libsForQt5.qt5.qtgraphicaleffects sddm = { enable = true; - wayland.enable = true; # enable experimental sddm support for wayland + wayland.enable = true; # experimental theme = "corners"; }; defaultSession = "hyprland"; }; - # Enable sound + # Multimedia Framework + # With backwards compatability for alsa/pulseaudio/jack pipewire = { enable = true; wireplumber.enable = true; @@ -121,7 +120,7 @@ in { jack.enable = true; }; - # Enable touchpad support + # Touchpad support libinput.enable = true; tumbler.enable = true; # Thunar image thumbnail support diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 5e172a9..1c94b9c 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -71,28 +71,28 @@ in { }; # ----- NETWORKING SECTION ----- - networking.hostName = "myputer"; - networking.networkmanager.enable = true; # Easiest to use and most distros use this by default. + networking = { + hostName = "myputer"; + networkmanager.enable = true; - # Open ports in the firewall. - # networking.firewall.allowedTCPPorts = [ ... ]; - # networking.firewall.allowedUDPPorts = [ ... ]; - # Or disable the firewall altogether. - networking.firewall.enable = true; + firewall.enable = true; + }; # ----- SERVICES ----- services = { # Set display manager (login screen) displayManager = { + # sddm relies on pkgs.libsForQt5.qt5.qtgraphicaleffects sddm = { enable = true; - wayland.enable = true; # enable experimental sddm support for wayland + wayland.enable = true; # experimental theme = "corners"; }; defaultSession = "hyprland"; }; - # Enable sound + # Multimedia Framework + # With backwards compatability for alsa/pulseaudio/jack pipewire = { enable = true; wireplumber.enable = true; From 20bdc7b50cf5d6c0a83664296eaa33d14f4285f7 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 1 Aug 2025 12:45:28 +1000 Subject: [PATCH 093/197] clean /default.nix (part 2) --- hosts/lolcathost/default.nix | 9 +++------ hosts/myputer/default.nix | 33 +++++++++++++++++++++++---------- 2 files changed, 26 insertions(+), 16 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 4f82c58..a2bb4e4 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -41,7 +41,6 @@ in { }; grub = { efiSupport = true; - #efiInstallAsRemovable = true; # in case canTouchEfiVariables doesn't work on this system device = "nodev"; useOSProber = false; }; @@ -50,15 +49,13 @@ in { enable = true; theme = "whitesur"; # stylish, vimix, or whitesur footer = true; - customResolution = "1920x1080"; # Optional: Set a custom resolution + customResolution = "1920x1080"; }; }; - # Set your time zone. time.timeZone = "Australia/Brisbane"; + i18n.defaultLocale = "en_US.UTF-8"; # internationalisation - # Select internationalisation properties. - i18n.defaultLocale = "en_US.UTF-8"; # Enable initrd hook for virtual console customisation # aka cool colours when bootting yay!! console = { @@ -87,7 +84,7 @@ in { ]; }; - # ----- NETWORKING SECTION ----- + # ----- NETWORKING ----- networking = { hostName = "lolcathost"; networkmanager.enable = true; diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 1c94b9c..29ec932 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -1,8 +1,8 @@ { + lib, pkgs, inputs, - lib, - wishlist, + config, ... }: let home-manager = builtins.fetchTarball { @@ -15,20 +15,35 @@ in { (import "${home-manager}/nixos") ../modules/steam.nix + ../modules/obsidian.nix + + ../modules/flipperzero.nix + ../modules/chameleonultragui.nix ]; - boot.loader.systemd-boot.enable = false; + nixpkgs.config.allowUnfreePredicate = let + whitelist = map lib.getName [ + pkgs.obsidian + pkgs.gitkraken + pkgs.steam + pkgs.steamcmd + pkgs.steam-unwrapped + pkgs.dwarf-fortress + ]; + in + pkg: builtins.elem (lib.getName pkg) whitelist; + boot.loader = { efi = { canTouchEfiVariables = true; - efiSysMountPoint = "/boot/efi"; #/boot/efi + efiSysMountPoint = "/boot/efi"; }; grub = { efiSupport = true; - #efiInstallAsRemovable = true; # in case canTouchEfiVariables doesn't work on this system device = "nodev"; - #useOSProber = true; + # useOSProber = true; }; + # GitHub: vinceliuice/grub2-themes grub2-theme = { enable = true; theme = "whitesur"; # stylish, vimix, or whitesur @@ -37,11 +52,9 @@ in { }; }; - # Set your time zone. time.timeZone = "Australia/Brisbane"; + i18n.defaultLocale = "en_US.UTF-8"; # internationalisation - # Select internationalisation properties. - i18n.defaultLocale = "en_US.UTF-8"; # Enable initrd hook for virtual console customisation # aka cool colours when bootting yay!! console = { @@ -70,7 +83,7 @@ in { ]; }; - # ----- NETWORKING SECTION ----- + # ----- NETWORKING ----- networking = { hostName = "myputer"; networkmanager.enable = true; From e4bfdad61bf87d7877b86b33732c4001061271d1 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 1 Aug 2025 13:17:12 +1000 Subject: [PATCH 094/197] clean /default.nix (part 3) --- hosts/lolcathost/default.nix | 58 +++++++-------- hosts/myputer/default.nix | 132 +++++++++++++++++++++-------------- 2 files changed, 105 insertions(+), 85 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index a2bb4e4..94f1f1d 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -22,6 +22,11 @@ in { ../modules/chameleonultragui.nix ]; + nix.settings.experimental-features = [ + "nix-command" + "flakes" + ]; + nixpkgs.config.allowUnfreePredicate = let whitelist = map lib.getName [ pkgs.obsidian @@ -125,12 +130,10 @@ in { }; security.rtkit.enable = true; # I *think* this is for pipewire - # allow wheel group to use passwordless sudo + # ------- USERS ------- users = { - # using fish as the login shell tends - # to go very poorly because it isn't - # POSIX compliant, so we'll just use - # simple Bash then :) + # Using fish as the login shell tends to go very poorly because it isn't + # POSIX compliant, so we default the login shell to Bash instead :) defaultUserShell = pkgs.bash; users = { @@ -138,7 +141,7 @@ in { me = { isNormalUser = true; extraGroups = ["wheel" "netdev" "docker"]; - shell = pkgs.bash; #pkgs.fish + shell = pkgs.bash; packages = let # TODO: can I just do this: https://nix.dev/manual/nix/2.18/command-ref/new-cli/nix3-flake#url-like-syntax # instead to use colmena's flake.nix by specifying a rev hash in the flake input? @@ -165,8 +168,6 @@ in { friends = { isNormalUser = true; shell = pkgs.fish; - packages = with pkgs; [ - ]; }; }; }; @@ -179,7 +180,7 @@ in { ]; }; - # set environment variables + # ---- ENVIRONMENT VARIABLES ---- environment.sessionVariables = { # folder names with capitalisation look awful! XDG_DOWNLOAD_DIR = "$HOME/downloads"; @@ -194,10 +195,10 @@ in { swww helvum easyeffects + pavucontrol ani-cli bluetui wl-clipboard # clipboard for wayland - pavucontrol qbittorrent # torrenting signal-desktop @@ -206,10 +207,14 @@ in { pkgs.libsForQt5.qt5.qtgraphicaleffects # Shell + bash + zsh + fish shellcheck - # Fish Plugins grc # colorise command outputs + # Make + gnumake # C Family gcc clang @@ -228,9 +233,6 @@ in { # Sage sageWithDoc # SageMath + HTML Documentation - # DEBUG: using neofetch temporarily to see if my system upgrades properly - neofetch - openvpn inetutils @@ -263,12 +265,12 @@ in { # Pretty necessary git git-filter-repo + nix-prefetch-git brightnessctl acpi # upower vim powertop - gnumake imagemagick # "Standard" Unix Commands @@ -279,7 +281,11 @@ in { unrar-free man-pages man-pages-posix + + # Cryptography gnupg + openssl + libargon2 # Games mindustry @@ -294,6 +300,7 @@ in { xwayland.enable = true; }; + zsh.enable = true; fish.enable = true; nix-ld.enable = true; @@ -322,6 +329,9 @@ in { thunar-media-tags-plugin # change metadata for media files ]; }; + + # mozilla's email client + thunderbird.enable = true; }; # ----- FONTS ----- @@ -357,26 +367,8 @@ in { }; }; - # Enable the new CLI commands and the flakes as experimental features - nix.settings.experimental-features = [ - "nix-command" - "flakes" - ]; - virtualisation.docker.enable = true; - # Some programs need SUID wrappers, can be configured further or are - # started in user sessions. - # programs.mtr.enable = true; - # programs.gnupg.agent = { - # enable = true; - # enableSSHSupport = true; - # }; - - # Enable the OpenSSH daemon. - # services.openssh.enable = true; - - # Enable OpenGL hardware = { graphics.enable = true; diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 29ec932..4e54077 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -7,7 +7,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; - sha256 = "1kk5qzfb87mkgy6vzm7x8z8akxr3k8k7839yjdy48z034pvidhsr"; + sha256 = "026rvynmzmpigax9f8gy9z67lsl6dhzv2p6s8wz4w06v3gjvspm1"; }; in { imports = [ @@ -21,6 +21,11 @@ in { ../modules/chameleonultragui.nix ]; + nix.settings.experimental-features = [ + "nix-command" + "flakes" + ]; + nixpkgs.config.allowUnfreePredicate = let whitelist = map lib.getName [ pkgs.obsidian @@ -48,7 +53,8 @@ in { enable = true; theme = "whitesur"; # stylish, vimix, or whitesur footer = true; - customResolution = "1920x1080"; + # TODO: switch my cables to switch default grub display + customResolution = "3840x2160"; }; }; @@ -121,21 +127,19 @@ in { }; security.rtkit.enable = true; # I *think* this is for pipewire - # allow wheel group to use passwordless sudo + # ------- USERS ------- security.sudo.wheelNeedsPassword = false; users = { - # using fish as the login shell tends - # to go very poorly because it isn't - # POSIX compliant, so we'll just use - # simple Bash then :) + # Using fish as the login shell tends to go very poorly because it isn't + # POSIX compliant, so we default the login shell to Bash instead :) defaultUserShell = pkgs.bash; users = { # just me fr (personal account) me = { isNormalUser = true; - extraGroups = ["wheel" "docker"]; - shell = pkgs.bash; #pkgs.fish + extraGroups = ["wheel" "netdev" "docker"]; + shell = pkgs.bash; packages = let # TODO: can I just do this: https://nix.dev/manual/nix/2.18/command-ref/new-cli/nix3-flake#url-like-syntax # instead to use colmena's flake.nix by specifying a rev hash in the flake input? @@ -164,9 +168,7 @@ in { ae = { isNormalUser = true; extraGroups = ["wheel"]; - shell = pkgs.bash; #pkgs.fish - packages = with pkgs; [ - ]; + shell = pkgs.bash; }; }; }; @@ -178,7 +180,7 @@ in { ]; }; - # set environment variables + # ---- ENVIRONMENT VARIABLES ---- environment.sessionVariables = { # folder names with capitalisation look awful! XDG_DOWNLOAD_DIR = "$HOME/downloads"; @@ -198,60 +200,97 @@ in { bluetui wl-clipboard # clipboard for wayland hyprpicker + qbittorrent + signal-desktop - #(callPackage ../sddm-theme-corners.nix {}).sddm-theme-corners + (callPackage ../sddm-theme-corners.nix {}).sddm-theme-corners # dependencies for my sddm theme: pkgs.libsForQt5.qt5.qtgraphicaleffects - python311 # I use 3.11 since it's in a pretty stable state now - poetry # python dependency management and packaging - - nixd # lsp for nix - - neofetch # TODO: remove (installed to debug something) - - # fish plugins + # Shell + bash + zsh + fish + shellcheck grc # colorise command outputs + # Make + gnumake + # C Family + gcc + clang + # Rust + cargo + rustc + # Nim + nim + # Go + go + + # Python + python312 # I use 3.12 since it's in a pretty stable state now + python314 # also 3.14 for latest features + poetry + # Sage + sageWithDoc # SageMath + HTML Documentation + + openvpn + inetutils + + # security tools + rustscan + nmap + dig + gobuster + nth + zap + httpie curlie zoxide doggo tldr - viddy + # btop + eza + yazi + lazygit + ripgrep + viddy # modern `watch` command + thefuck tesseract # for my work with Agribit - # TODO: remove this and host my nix flake on github instead - #wishlist + # TODO: once upgraded past Nix-24.07 this line won't be necessary (I think) + # helix will support nixd by default + # SOURCE: https://github.com/nix-community/nixd/blob/main/nixd/docs/editor-setup.md#Helix + # nixd # lsp for nix # DEBUG # Pretty necessary git git-filter-repo + nix-prefetch-git brightnessctl acpi vim - nix-prefetch-git - gcc - gnumake + powertop + imagemagick - # Unix Commands + # "Standard" Unix Commands file wget tree unzip - # Man Pages + unrar-free man-pages man-pages-posix # Cryptography + gnupg openssl libargon2 # Games - mindustry-wayland - dwarf-fortress - nethack + prismlauncher # minecraft ]; # DEBUG: configuring xdg portal here instead? @@ -270,7 +309,6 @@ in { # ]; #}; - # Enable the use of certain programs programs = { hyprland = { enable = true; @@ -281,6 +319,8 @@ in { zsh.enable = true; fish.enable = true; + nix-ld.enable = true; + neovim = { enable = true; defaultEditor = true; @@ -360,29 +400,17 @@ in { }; }; - # Enable the new CLI commands and the flakes as experimental features - nix.settings.experimental-features = [ - "nix-command" - "flakes" - ]; - virtualisation.docker.enable = true; - # Some programs need SUID wrappers, can be configured further or are - # started in user sessions. - # programs.mtr.enable = true; - #programs.gnupg.agent = { - # enable = true; - # enableSSHSupport = true; - #}; - - # Enable the OpenSSH daemon. - # services.openssh.enable = true; - - # Enable OpenGL hardware = { graphics.enable = true; + # opengl = { + # enable = true; + # driSupport = true; + # driSupport32Bit = true; + # } + bluetooth = { enable = true; powerOnBoot = true; From 9896d98154c27fc48fac3c12dda4c0bc1358a52f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 1 Aug 2025 13:25:42 +1000 Subject: [PATCH 095/197] fixed myputer using nerdfonts not nerd-fonts --- hosts/lolcathost/default.nix | 3 +-- hosts/myputer/default.nix | 41 ++++++++++++++++++------------------ 2 files changed, 22 insertions(+), 22 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 94f1f1d..39e448e 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -346,9 +346,8 @@ in { # "JetBrainsMono" # ]; # }) - # nerdfonts - geist-font # for my hyprlock theme + geist-font # for my hyprlock theme # texlive maintains a noto-emoji flake texlivePackages.noto-emoji ] diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 4e54077..a8a4061 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -367,27 +367,28 @@ in { # ----- FONTS ----- fonts = { enableDefaultPackages = true; # no clue what this line does tbh - packages = with pkgs; [ - /* - (nerdfonts.override { - fonts = [ - "Cousine" # its already i guess - "Iosevka" # nah nah - "IosevkaTerm" # big nah - "CascadiaCode" # potential - "FiraCode" # potential - "JetBrainsMono" # for my rofi theme - "Hasklig" - "Hack" - ]; - }) - */ - nerdfonts - geist-font # for my hyprlock theme + packages = with pkgs; + [ + # (nerdfonts.override { + # fonts = [ + # "Cousine" # its ok i guess + # "Iosevka" # nah nah + # "IosevkaTerm" # big nah + # "CascadiaCode" # potential + # "FiraCode" # potential + # "JetBrainsMono" # for my rofi theme + # "Hasklig" + # "Hack" + # ]; + # }) - # texlive maintains a noto-emoji flake - texlivePackages.noto-emoji - ]; + geist-font # for my hyprlock theme + # texlive maintains a noto-emoji flake + texlivePackages.noto-emoji + ] + ++ builtins.filter lib.attrsets.isDerivation ( + builtins.attrValues pkgs.nerd-fonts + ); # TODO: change my default fonts fontconfig = { From b5dab67f08d0c2afbbd38a0170cf2fb0cdfaca6f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 1 Aug 2025 13:35:24 +1000 Subject: [PATCH 096/197] auto stash before checking out "forge/main" --- hosts/hyrule/default.nix | 2 ++ hosts/hyrule/mailserver.nix | 14 ++++++-------- hosts/lolcathost/default.nix | 10 +++++++++- hosts/sddm-theme-corners.nix | 6 +++--- 4 files changed, 20 insertions(+), 12 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index a21a5ac..e68d0d3 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -12,6 +12,8 @@ in { imports = [ ./hardware-configuration.nix (import "${home-manager}/nixos") + + ./mailserver.nix # TEMP: location #../modules/server/nginx.nix #../modules/server/ssh.nix #../modules/server/fail2ban.nix diff --git a/hosts/hyrule/mailserver.nix b/hosts/hyrule/mailserver.nix index c5556f2..49274f2 100644 --- a/hosts/hyrule/mailserver.nix +++ b/hosts/hyrule/mailserver.nix @@ -6,8 +6,7 @@ imports = [ (builtins.fetchTarball { url = "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/archive/nixos-25.05/nixos-mailserver-nixos-25.05.tar.gz"; - # release="nixos-25.05"; nix-prefetch-url "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/archive/${release}/nixos-mailserver-${release}.tar.gz" --unpack - sha256 = "0000000000000000000000000000000000000000000000000000"; + sha256 = "0jpp086m839dz6xh6kw5r8iq0cm4nd691zixzy6z11c4z2vf8v85"; }) ]; @@ -15,7 +14,7 @@ # DOCS: https://nixos-mailserver.readthedocs.io/en/latest mailserver = { enable = true; - stateVersion = 3; + # stateVersion = 3; # Manually open the firewall instead openFirewall = false; virusScanning = false; # expensive memory usage @@ -23,17 +22,16 @@ fqdn = "mail.imbored.dev"; domains = ["imbored.dev"]; - # A list of all login accounts. To create the password hashes, use - # nix-shell -p mkpasswd --run 'mkpasswd -sm bcrypt' + # NOTE: generate hashes with `mkpasswd -sm bcrypt` loginAccounts = { "me@imbored.dev" = { - hashedPasswordFile = "/a/file/containing/a/hashed/password"; aliases = ["emile@imbored.dev"]; + hashedPasswordFile = let + CWD = builtins.getEnv "PWD"; + in "${CWD}/secrets/passwd/me"; }; }; - # Use Let's Encrypt certificates. Note that this needs to set up a stripped - # down nginx and opens port 80. certificateScheme = "acme-nginx"; }; } diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 39e448e..2317275 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -107,7 +107,13 @@ in { wayland.enable = true; # experimental theme = "corners"; }; - defaultSession = "hyprland"; + defaultSession = + "hyprland" + + ( + if config.programs.hyprland.withUWSM == true + then "-uwsm" + else null + ); }; # Multimedia Framework @@ -233,6 +239,8 @@ in { # Sage sageWithDoc # SageMath + HTML Documentation + qemu # Fellice Bellard's Quick Emulator + openvpn inetutils diff --git a/hosts/sddm-theme-corners.nix b/hosts/sddm-theme-corners.nix index ccc93f0..e9a755f 100755 --- a/hosts/sddm-theme-corners.nix +++ b/hosts/sddm-theme-corners.nix @@ -1,8 +1,8 @@ {pkgs}: { - sddm-theme-corners = pkgs.stdenv.mkDerivation rec { + sddm-theme-corners = pkgs.stdenv.mkDerivation { name = "sddm-theme-corners"; - #version = "1.0"; - #dontBuild = true; + version = "1.0.0"; + installPhase = '' mkdir -p $out/share/sddm/themes cp -ar $src/corners $out/share/sddm/themes/ From 7d4e0f35591e3ffd3c945296bff24c29830363e8 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 1 Aug 2025 13:36:56 +1000 Subject: [PATCH 097/197] fixed myputer not using UWSM with hyprland --- hosts/myputer/default.nix | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index a8a4061..c34cfb9 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -107,7 +107,13 @@ in { wayland.enable = true; # experimental theme = "corners"; }; - defaultSession = "hyprland"; + defaultSession = + "hyprland" + + ( + if config.programs.hyprland.withUWSM == true + then "-uwsm" + else null + ); }; # Multimedia Framework From b303ffb3cc83dc27fae490136f1966faa055e53f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 1 Aug 2025 13:39:02 +1000 Subject: [PATCH 098/197] fixed qemu not installed to myputer --- hosts/lolcathost/default.nix | 4 ++-- hosts/myputer/default.nix | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 2317275..e6d03fd 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -219,6 +219,8 @@ in { shellcheck grc # colorise command outputs + # Systems Emulation + qemu # Fellice Bellard's Quick Emulator # Make gnumake # C Family @@ -239,8 +241,6 @@ in { # Sage sageWithDoc # SageMath + HTML Documentation - qemu # Fellice Bellard's Quick Emulator - openvpn inetutils diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index c34cfb9..486c59d 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -220,6 +220,8 @@ in { shellcheck grc # colorise command outputs + # Systems Emulation + qemu # Fellice Bellard's Quick Emulator # Make gnumake # C Family From fe8db21616569963c117aaf9b5173d9ed3348312 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 12:46:19 +1000 Subject: [PATCH 099/197] add swww interface script --- scripts/set-wallpaper | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 scripts/set-wallpaper diff --git a/scripts/set-wallpaper b/scripts/set-wallpaper new file mode 100755 index 0000000..2f6b928 --- /dev/null +++ b/scripts/set-wallpaper @@ -0,0 +1,17 @@ +#!/usr/bin/env bash + +# THIS PROGRAM RELIES SOLELY ON `SWWW` + +transition=$1 +wallpaper_path=$2 + +if [[ "$transition" == "wipe" ]]; then + swww img --transition-type wipe --transition-angle 30 --transition-step 90 --transition-fps 60 $wallpaper_path +elif [[ "$transition" == "preview" ]]; then + swww img --transition-type wipe --transition-angle 45 --transition-step 90 --transition-bezier .27,.98,.78,0 --transition-fps 60 $wallpaper_path +elif [[ "$transition" == "circle" ]]; then + swww img --transition-type grow --transition-pos "$(hyprctl cursorpos)" --transition-duration 3 --transition-fps 60 --invert-y $wallpaper_path +else + echo "[!] Unknown transition type \"$transition\"" + exit 1 +fi From 30d49efe57223c581d1cd147f4164bf8fdd93df5 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 17:45:24 +1000 Subject: [PATCH 100/197] add introduction section to GUIDE.md --- GUIDE.md | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/GUIDE.md b/GUIDE.md index 95180b6..7666492 100644 --- a/GUIDE.md +++ b/GUIDE.md @@ -1,3 +1,61 @@ +# The Nix Documentation Situation +The Nix documentation situation is notorious bad. It's difficult to find +a concise answer with detailed justification/explanation. And most people +(myself included) tend resort to the [ArchWiki](https://wiki.archlinux.org). +> [!NOTE] +> The [Nix documentation team](https://nixos.org/community/teams/documentation) has an incredibly difficult job. + +Unlike the *centralised* [ArchWiki](https://wiki.archlinux.org), the Nix ecosystem +is incredibly large: +1. **Nix** (the package manager) +2. **Nix/NixLang** (the programming language) +3. **Nixpkgs** (the package repository) +4. **NixOS** (the linux distribution) +5. **Home-Manager** (user environment management) +6. **NUR** (Nix User Repository, like the AUR but Nix!) +7. *and **many** more...* + +Often each project has its own website, wiki, styling, etc. There is tonnes +of information available online but its so hard to find it. + +**Notable organisations:** +1. NixOS Foundation (*official organisation that maintains Nix/Nixpkgs/NixOS*) +2. Nix Community (*unofficial community providing infrastructure/hosting/visibility for projects*) + +## About Me +I love and hate Nix simultaneously. + +Originally *(circa 2023)* I used Windows 10/11 exclusively for programming. +But this is tedious and my friend started mentioning Arch Linux. So with their +help I formatted a spare SSD and began my journey. + +But I **REALLY** like computers... I have servers, routers, 3 computers +actively powered in my bedroom, and *I believe* 8 laptops *currently* in my posession. + +Documenting **every** change I make to a system and spending a week +setting up a device I don't really care about isn't sustainable. +And then *(circa October 2024)* I learnt about NixOS... And now life is "easy". +But learning Nix/NixLang/Nixpkgs/NixOS/Home-Manager/blah-blah-blah was exhausting. +So now I'll try to simplify this learning curve for other newbies **<3** + + +## Nix/NixOS How To +### NixOS Documentation +Using "the" NixOS wiki is surprisingly confusing (at least it was for me). +Why? Because there are multiple and you probably won't realise the difference. + +**Main Wikis:** +> These are visually and structurally identical... And are both community run. +> But they're content does differ. [nixos.wiki] was created +> because ""[wiki.nixos.org] was too limiting with regards to wiki features". +1. [https://wiki.nixos.org] (the **official** NixOS wiki) +2. [https://nixos.wiki] (the **unofficial** user's wiki, community run) + + +**Other Resources:** +> [!TODO] + + ### Migrate to a Newer Version of Nixpkgs ```bash # Determine the channel name you're using From 174061f66277fdc880dc79de5a9e204410f72412 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 22:21:02 +1000 Subject: [PATCH 101/197] add hyprland config file while porting to nix lang --- config.temp/hyprland.conf | 371 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 371 insertions(+) create mode 100755 config.temp/hyprland.conf diff --git a/config.temp/hyprland.conf b/config.temp/hyprland.conf new file mode 100755 index 0000000..864b184 --- /dev/null +++ b/config.temp/hyprland.conf @@ -0,0 +1,371 @@ +# All hyprland configuration variables are listed (even niche ones) +# to save you the hassle. Reference: https://wiki.hypr.land/Configuring/Variables/ +# +# You can split this configuration into multiple files +# Create your files separately and then link them to this file like this: +# source = ~/.config/hypr/myColors.conf + + +################ +### MONITORS ### +################ + +# Programming: +monitor=eDP-1, highres@highrr, auto, 1.0 +# Comfy: +#monitor=eDP-1, highres@highrr, auto, 1.5 + + +################### +### MY PROGRAMS ### +################### + +# See https://wiki.hyprland.org/Configuring/Keywords/ + +# Set programs that you use +$terminal = ghostty #rio +$fileManager = thunar +#$menu = wofi --show drun +$menu = ags -t "applauncher" +$colorpicker = hyprpicker | head -c 7 | wl-copy + +################# +### AUTOSTART ### +################# + +# Autostart necessary processes (like notifications daemons, status bars, etc.) +# Or execute your favorite apps at launch like this: + +# exec-once = $terminal +# exec-once = nm-applet & +# exec-once = waybar & hyprpaper & firefox +exec-once = swww-daemon & +# TODO: or do I do `swww init` or `swww restore`? + +# █▀▀ █▄░█ █░█   █░█ ▄▀█ █▀█ +# ██▄ █░▀█ ▀▄▀   ▀▄▀ █▀█ █▀▄ + +# See https://wiki.hyprland.org/Configuring/Environment-variables/ + +#env = HYPRCURSOR_THEME,Bibata-Modern-Ice +env = HYPRCURSOR_SIZE,16 +#env = XCURSOR_THEME,Bibata-Modern-Ice +env = XCURSOR_SIZE,16 + +env = QT_QPA_PLATFORM,wayland +env = QT_QPA_PLATFORMTHEME,qt5ct +env = XDG_MENU_PREFIX,arch- + +# TODO: make this variable (not dependent on helix) in my flake +env = EDITOR,hx +env = TERMINAL,rio + + + + +# DEBUG: attempting to get screensharing working... (please god help me) +# REFERENCE: https://github.com/hyprwm/xdg-desktop-portal-hyprland/issues/251#issuecomment-2345631820 +env = XDG_CURRENT_DESKTOP,Hyprland +exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP +#exec-once = dbus-update-activation-environment --systemd --all +#exec-once = systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP + + + +# .__. .___ __..___. . . .___ .___. ._. __ __. +# [__] [__ (__ | |__| [__ | | / ` (__ +# | | [___ .__) | | | [___ | _|_ \__. .__) + +# Refer to https://wiki.hyprland.org/Configuring/Variables/ + +# https://wiki.hyprland.org/Configuring/Variables/#general +general { + gaps_in = 12 # margin between windows + gaps_out = 25 # margin from windows to monitor edge + gaps_workspaces = 0 # margin between workspaces (stacks with gaps_out) + # float_gaps = 0 # gaps_out but for floating windows + + border_size = 4 + + # https://wiki.hyprland.org/Configuring/Variables/#variable-types for info about colors + col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg + col.inactive_border = rgba(00000000) + + # Set to true enable resizing windows by clicking and dragging on borders and gaps + resize_on_border = true + + # Please see https://wiki.hyprland.org/Configuring/Tearing/ before you turn this on + allow_tearing = false + + layout = dwindle + + snap { + enabled = false + window_gap = 10 + monitor_gap = 10 + border_overlap = false + # respect_gaps = false + } +} + +# https://wiki.hyprland.org/Configuring/Variables/#decoration +decoration { + rounding = 20 + rounding_power = 4.0 # Lp norm + border_part_of_window = true # consider border as part of its window + screen_shader = # path to custom GLSL fragment shader + + # Window Transparency + active_opacity = 1.0 + inactive_opacity = 0.95 + fullscreen_opacity = 1.0 # fullscreened windows + # Inactive Window Dimming + dim_inactive = false + dim_strength = 0.5 + dim_special = 0.2 + dim_around = 0.4 + + # https://wiki.hyprland.org/Configuring/Variables/#blur + blur { + enabled = true + new_optimizations = true + xray = false # floating windows xray through tiling windows + ignore_opacity = true + + # Blur Parameters + size = 8 + passes = 1 + noise = 0.0117 # default + contrast = 0.8916 # default + brightness = 0.8172 # default + vibrancy = 0.1696 # default + vibrancy_darkness = 0.0 # default + + # Blurring For Specific Window Types + special = false # blur special windows + popups = false # blur popups + popups_ignorealpha = 0.2 + input_methods = false + input_methods_ignorealpha = 0.2 + } + + shadow { + enabled = true + ignore_window = true # only render at edges (not behind) + + range = 3 + render_power = 1 # falloff rate + sharp = false # aka infinite shadow.render_power + offset = 0 0 # vec2 + scale = 1.0 + + color = rgba(00000000) + color_inactive = rgba(000000ff) # defaults to shadow.color if unset + } +} + +# https://wiki.hyprland.org/Configuring/Variables/#animations +animations { + enabled = yes, please :) + + # Animation Declaration Format: + # "animation = NAME, ENABLE, SPEED, BEZIER [,STYLE]" + # SPEED: in ds (where 1ds = 100ms) + + # Default animations, see https://wiki.hyprland.org/Configuring/Animations/ for more + + bezier = easeOutQuint,0.23,1,0.32,1 + bezier = easeInOutCubic,0.65,0.05,0.36,1 + bezier = linear,0,0,1,1 + bezier = almostLinear,0.5,0.5,0.75,1.0 + bezier = quick,0.15,0,0.1,1 + + animation = global, 1, 10, default + animation = border, 1, 5.39, easeOutQuint + + #animation = windows, 1, 4.79, easeOutQuint + #animation = windowsIn, 1, 4.1, easeOutQuint, popin 87% + animation = windowsIn, 1, 4, linear, slide bottom + # animation = windowsOut, 1, 1.49, linear, popin 87% + animation = windowsOut, 1, 10, linear, popin + + animation = fadeIn, 1, 1.73, almostLinear + animation = fadeOut, 1, 1.46, almostLinear + animation = fade, 1, 3.03, quick + + animation = layers, 1, 3.81, easeOutQuint + animation = layersIn, 1, 4, easeOutQuint, fade + animation = layersOut, 1, 1.5, linear, fade + + animation = fadeLayersIn, 1, 1.79, almostLinear + animation = fadeLayersOut, 1, 1.39, almostLinear + + animation = workspaces, 1, 1.94, almostLinear, fade + animation = workspacesIn, 1, 1.21, almostLinear, fade + animation = workspacesOut, 1, 1.94, almostLinear, fade +} + +# Ref https://wiki.hyprland.org/Configuring/Workspace-Rules/ +# "Smart gaps" / "No gaps when only" +# uncomment all if you wish to use that. +# workspace = w[t1], gapsout:0, gapsin:0 +# workspace = w[tg1], gapsout:0, gapsin:0 +# workspace = f[1], gapsout:0, gapsin:0 +# windowrulev2 = bordersize 0, floating:0, onworkspace:w[t1] +# windowrulev2 = rounding 0, floating:0, onworkspace:w[t1] +# windowrulev2 = bordersize 0, floating:0, onworkspace:w[tg1] +# windowrulev2 = rounding 0, floating:0, onworkspace:w[tg1] +# windowrulev2 = bordersize 0, floating:0, onworkspace:f[1] +# windowrulev2 = rounding 0, floating:0, onworkspace:f[1] + +# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more +dwindle { + pseudotile = true # Master switch for pseudotiling. Enabling is bound to MOD + P in the keybinds section below + preserve_split = true # You probably want this +} + +# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more +master { + new_status = master +} + +# https://wiki.hyprland.org/Configuring/Variables/#misc +misc { + #force_default_wallpaper = -1 # Set to 0 or 1 to disable the anime mascot wallpapers + disable_hyprland_logo = true # If true disables the random hyprland logo / anime girl background. :( + disable_splash_rendering = true +} + + +############# +### INPUT ### +############# + +# https://wiki.hyprland.org/Configuring/Variables/#input +input { + kb_layout = us + kb_variant = + kb_model = + kb_options = + kb_rules = + + follow_mouse = 1 + + sensitivity = 0 # -1.0 - 1.0, 0 means no modification. + + touchpad { + natural_scroll = false + } +} + +# https://wiki.hyprland.org/Configuring/Variables/#gestures +gestures { + workspace_swipe = true +} + +# Example per-device config +# See https://wiki.hyprland.org/Configuring/Keywords/#per-device-input-configs for more +#device { +# name = epic-mouse-v1 +# sensitivity = -0.5 +#} + + +################### +### KEYBINDINGS ### +################### + +# See https://wiki.hyprland.org/Configuring/Keywords/ +$MOD = SUPER # Sets "Windows" key as main modifier + +# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more +bind = $MOD, RETURN, exec, $terminal +bind = $MOD, E, exec, $fileManager +bind = $MOD, R, exec, $menu +bind = $MOD, H, exec, $colorpicker + +bind = $MOD, F, fullscreen +bind = $MOD, V, togglefloating, +bind = $MOD, P, pseudo, # dwindle +bind = $MOD, J, togglesplit, # dwindle + +bind = $MOD, C, killactive, +#bind = $MOD, M, exit, + +# Move focus with MOD + arrow keys +bind = $MOD, left, movefocus, l +bind = $MOD, right, movefocus, r +bind = $MOD, up, movefocus, u +bind = $MOD, down, movefocus, d + +# Switch workspaces with MOD + [0-9] +bind = $MOD, 1, workspace, 1 +bind = $MOD, 2, workspace, 2 +bind = $MOD, 3, workspace, 3 +bind = $MOD, 4, workspace, 4 +bind = $MOD, 5, workspace, 5 +bind = $MOD, 6, workspace, 6 +bind = $MOD, 7, workspace, 7 +bind = $MOD, 8, workspace, 8 +bind = $MOD, 9, workspace, 9 +bind = $MOD, 0, workspace, 10 + +# Move active window to a workspace with MOD + SHIFT + [0-9] +bind = $MOD SHIFT, 1, movetoworkspace, 1 +bind = $MOD SHIFT, 2, movetoworkspace, 2 +bind = $MOD SHIFT, 3, movetoworkspace, 3 +bind = $MOD SHIFT, 4, movetoworkspace, 4 +bind = $MOD SHIFT, 5, movetoworkspace, 5 +bind = $MOD SHIFT, 6, movetoworkspace, 6 +bind = $MOD SHIFT, 7, movetoworkspace, 7 +bind = $MOD SHIFT, 8, movetoworkspace, 8 +bind = $MOD SHIFT, 9, movetoworkspace, 9 +bind = $MOD SHIFT, 0, movetoworkspace, 10 + +# Example special workspace (scratchpad) +bind = $MOD, S, togglespecialworkspace, magic +bind = $MOD SHIFT, S, movetoworkspace, special:magic + +# Scroll through existing workspaces with MOD + scroll +bind = $MOD, mouse_up, workspace, e-1 +bind = $MOD, mouse_down, workspace, e+1 +# Or with the keyboard +bind = $MOD SHIFT, left, workspace, e-1 +bind = $MOD SHIFT, right, workspace, e+1 + +# Move/resize windows with MOD + LMB/RMB and dragging +bindm = $MOD, mouse:272, movewindow +bindm = $MOD, mouse:273, resizewindow + +# Laptop multimedia keys for volume and LCD brightness +bindel = ,XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+ +bindel = ,XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%- +bindel = ,XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle +bindel = ,XF86AudioMicMute, exec, wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle +bindel = ,XF86MonBrightnessUp, exec, brightnessctl s 10%+ +bindel = ,XF86MonBrightnessDown, exec, brightnessctl s 10%- + +# Requires playerctl +bindl = , XF86AudioNext, exec, playerctl next +bindl = , XF86AudioPause, exec, playerctl play-pause +bindl = , XF86AudioPlay, exec, playerctl play-pause +bindl = , XF86AudioPrev, exec, playerctl previous + +############################## +### WINDOWS AND WORKSPACES ### +############################## + +# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more +# See https://wiki.hyprland.org/Configuring/Workspace-Rules/ for workspace rules + +# Example windowrule v1 +# windowrule = float, ^(kitty)$ + +# Example windowrule v2 +# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$ + +# Ignore maximize requests from apps. You'll probably like this. +windowrulev2 = suppressevent maximize, class:.* + +# Fix some dragging issues with XWayland +windowrulev2 = nofocus,class:^$,title:^$,xwayland:1,floating:1,fullscreen:0,pinned:0 From c0dda89f8340f71aaed4992748fe6cbf86c0d51f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 22:22:19 +1000 Subject: [PATCH 102/197] add input method todo item --- TODO | 2 ++ 1 file changed, 2 insertions(+) diff --git a/TODO b/TODO index 20d65c3..bb8e65c 100644 --- a/TODO +++ b/TODO @@ -22,6 +22,8 @@ https://github.com/XNM1/linux-nixos-hyprland-config-dotfiles/blob/main/nixos/mac Make each monitor's window styling slightly different (just for fun) +Research "input methods" ie https://wiki.archlinux.org/title/Input_method + Bind 5 workspaces per connected monitor. Then use the command palette (discussed prior) to send to a different workspace (ie because I currently use MOD+SHIFT+n From 6e3221a4107daa438a9d8c17540e857d043ef0d9 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 22:45:40 +1000 Subject: [PATCH 103/197] vps now has better command colouring --- homes/ae/default.nix | 6 ++++++ homes/modules/fish.nix | 1 + 2 files changed, 7 insertions(+) diff --git a/homes/ae/default.nix b/homes/ae/default.nix index 8e0e0fe..3c33619 100644 --- a/homes/ae/default.nix +++ b/homes/ae/default.nix @@ -10,6 +10,12 @@ config.allowUnfree = false; }; + imports = [ + ../modules/fish.nix + ../modules/bat.nix + ../modules/btop.nix + ]; + home = { username = "ae"; homeDirectory = "/home/ae"; diff --git a/homes/modules/fish.nix b/homes/modules/fish.nix index 4e40d9c..eaca566 100755 --- a/homes/modules/fish.nix +++ b/homes/modules/fish.nix @@ -8,6 +8,7 @@ morphBashToFish = lib.mkEnableOption "morphBashToFish"; }; + # TODO: make the greeting controllable (ie so my VPS can be different) config = { programs.fish = { enable = true; From d59c11a4142a5c5198098d6a41f585119523e9e4 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 23:39:48 +1000 Subject: [PATCH 104/197] add vanilla minecraft-server to hyrule --- hosts/hyrule/default.nix | 1 + hosts/hyrule/minecraft-server.nix | 59 +++++++++++++++++++++++++++++++ 2 files changed, 60 insertions(+) create mode 100644 hosts/hyrule/minecraft-server.nix diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index e68d0d3..64d69d7 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -73,6 +73,7 @@ in { # 3306 (INTERNAL) forgejo sqlite3 database 5000 # debug (for my job) # 8222 (INTERNAL) vaultwarden + 45000 # minecaft server ]; }; }; diff --git a/hosts/hyrule/minecraft-server.nix b/hosts/hyrule/minecraft-server.nix new file mode 100644 index 0000000..24917cb --- /dev/null +++ b/hosts/hyrule/minecraft-server.nix @@ -0,0 +1,59 @@ +{pkgs, ...}: { + services.minecraft-server = { + enable = true; + eula = true; + + openFirewall = false; # do this manually instead + declarative = true; + + whitelist = { + "SECRET1" = ""; + "SECRET2" = ""; + }; + + # REF: https://minecraft.wiki/w/Server.properties#Java_Edition + serverProperties = { + # server-ip = "" # listen on all addresses if unset + server-port = 45000; # connection port + query.port = 45000; # share game info/advertising information + user-native-transport = true; # Linux packet RX/TX optimizations + + # Users Connections + enforce-secure-profile = true; + online-mode = true; # don't allow unlicensed minecraft accounts to join + prevent-proxy-connections = false; + rate-limit = 0; + + # Server Functionality + enable-status = true; # where the server appears as "online" + hide-online-players = false; + log-ips = true; + pause-when-empty-seconds = 60; # pause server when no player online for x seconds + view-distance = 10; # range: 3-32 + simulation-distance = 10; # range: 3-32 + + # Players + motd = "M&M's Cozycraft Realm <3"; + max-players = 2; + white-list = true; + idle-player-timeout = 0; # never kick idle players + + # Gameplay + gamemode = "survival"; + force-gamemode = true; + difficulty = "normal"; + hardcore = false; + pvp = true; + allow-cheats = true; + + # World + level-name = "M&M's Cozycraft"; # world name + # level-seed = "" # random seed if unset + level-type = "minecraft:normal"; # world generation preset + generate-structures = true; + spawn-monsters = true; + spawn-protection = 0; + }; + jvmOpts = "-Xms2046M -Xmx2046M -XX:+UseG1GC -XX:+CMSIncrementalPacing -XX:+CMSClassUnloadingEnabled -XX:ParallelGCThreads=2 -XX:MinHeapFreeRatio=5 -XX:MaxHeapFreeRatio=10"; + }; +} From d2d27a7cf94cab74ebf085126d67e4e18a2dc52c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 23:44:01 +1000 Subject: [PATCH 105/197] progress hyrule home-manager hash to latest --- hosts/hyrule/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 64d69d7..4145e5d 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -6,7 +6,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; - sha256 = "1kk5qzfb87mkgy6vzm7x8z8akxr3k8k7839yjdy48z034pvidhsr"; + sha256 = "026rvynmzmpigax9f8gy9z67lsl6dhzv2p6s8wz4w06v3gjvspm1"; }; in { imports = [ From ea63bc85ad012ee675aa4e831b076462607fb10d Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 23:54:50 +1000 Subject: [PATCH 106/197] fix mc-server serverPropertiers."query.port" expands to query.port --- hosts/hyrule/minecraft-server.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/hyrule/minecraft-server.nix b/hosts/hyrule/minecraft-server.nix index 24917cb..1b3e3d5 100644 --- a/hosts/hyrule/minecraft-server.nix +++ b/hosts/hyrule/minecraft-server.nix @@ -15,7 +15,7 @@ serverProperties = { # server-ip = "" # listen on all addresses if unset server-port = 45000; # connection port - query.port = 45000; # share game info/advertising information + "query.port" = 45000; # share game info/advertising information user-native-transport = true; # Linux packet RX/TX optimizations # Users Connections From 6d4c43dcbe9dffa3794c660103f251a7ab3e6466 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 23:55:12 +1000 Subject: [PATCH 107/197] fix minecraft-server not imported to hyrule config --- hosts/hyrule/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 4145e5d..7239914 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -14,6 +14,7 @@ in { (import "${home-manager}/nixos") ./mailserver.nix # TEMP: location + ./minecraft-server.nix # TEMP: location #../modules/server/nginx.nix #../modules/server/ssh.nix #../modules/server/fail2ban.nix From de67846d56ddef7e185afc6bed5ece5550134326 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 2 Aug 2025 23:55:43 +1000 Subject: [PATCH 108/197] fix hyrule minecraft-server not whitelisted in unfree predicate --- hosts/hyrule/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 7239914..e902119 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -31,6 +31,13 @@ in { ]; }; + nixpkgs.config.allowUnfreePredicate = let + whitelist = map lib.getName [ + pkgs.minecraft-server + ]; + in + pkg: builtins.elem (lib.getName pkg) whitelist; + time.timeZone = "Australia/Brisbane"; i18n.defaultLocale = "en_US.UTF-8"; From c5207a5406c5560640d58f62a656e3a5b5c16896 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 3 Aug 2025 00:48:52 +1000 Subject: [PATCH 109/197] MAJOR: add nixpkgs-unstable WARNING: currently sets allowUnfree since idk how to use allowUnfreePredicate for alternative channels --- flake.lock | 19 ++++++++++++++++++- flake.nix | 11 +++++++++++ 2 files changed, 29 insertions(+), 1 deletion(-) diff --git a/flake.lock b/flake.lock index 7f15c41..4785725 100644 --- a/flake.lock +++ b/flake.lock @@ -128,6 +128,22 @@ "type": "github" } }, + "nixpkgs-unstable": { + "locked": { + "lastModified": 1753939845, + "narHash": "sha256-K2ViRJfdVGE8tpJejs8Qpvvejks1+A4GQej/lBk5y7I=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "94def634a20494ee057c76998843c015909d6311", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, "nixpkgs_2": { "locked": { "lastModified": 1734119587, @@ -181,7 +197,8 @@ "ags": "ags", "colmena": "colmena", "grub2-themes": "grub2-themes", - "nixpkgs": "nixpkgs_4" + "nixpkgs": "nixpkgs_4", + "nixpkgs-unstable": "nixpkgs-unstable" } }, "stable": { diff --git a/flake.nix b/flake.nix index cb9b457..c7c435b 100644 --- a/flake.nix +++ b/flake.nix @@ -3,6 +3,7 @@ inputs = { nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05"; + nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable"; #home-manager = { # url = "github:nix-community/home-manager"; @@ -19,6 +20,7 @@ outputs = { self, nixpkgs, + nixpkgs-unstable, grub2-themes, colmena, ... @@ -31,6 +33,13 @@ allowUnfree = false; # sanity check }; }; + + pkgs-unstable = import nixpkgs-unstable { + inherit system; + config = { + allowUnfree = true; # TODO: bandaid solution... (for minecraft-server) + }; + }; # TODO: come back to this its really cool # this is just something I'm experimenting with # PROJECT_ROOT = builtins.toString ./.; @@ -71,6 +80,8 @@ colmenaHive = colmena.lib.makeHive { meta = { nixpkgs = pkgs; + specialArgs = {inherit pkgs-unstable;}; + # set nixpkgs per server nodeNixpkgs = { hyrule = import nixpkgs { From 828203ffe801abfec80be24035a44d6f23a4eb0c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 3 Aug 2025 00:50:55 +1000 Subject: [PATCH 110/197] switch minecraft-server to nixpkgs-unstable for 1.21.8 nixpkgs is currently at 1.21.5 only --- hosts/hyrule/default.nix | 15 +++++++++------ hosts/hyrule/minecraft-server.nix | 10 ++++++++-- 2 files changed, 17 insertions(+), 8 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index e902119..6ac57a5 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -1,5 +1,6 @@ { pkgs, + pkgs-unstable, inputs, lib, ... @@ -31,12 +32,14 @@ in { ]; }; - nixpkgs.config.allowUnfreePredicate = let - whitelist = map lib.getName [ - pkgs.minecraft-server - ]; - in - pkg: builtins.elem (lib.getName pkg) whitelist; + # nixpkgs.config.allowUnfreePredicate = let + # whitelist = map lib.getName [ + # "minecraft-server" + # pkgs.minecraft-server + # pkgs-unstable.minecraft-server + # ]; + # in + # pkg: builtins.elem (lib.getName pkg) whitelist; time.timeZone = "Australia/Brisbane"; diff --git a/hosts/hyrule/minecraft-server.nix b/hosts/hyrule/minecraft-server.nix index 1b3e3d5..48237d8 100644 --- a/hosts/hyrule/minecraft-server.nix +++ b/hosts/hyrule/minecraft-server.nix @@ -1,10 +1,16 @@ -{pkgs, ...}: { +{ + pkgs, + pkgs-unstable, + ... +}: { services.minecraft-server = { enable = true; + package = pkgs-unstable.minecraft-server; # use latest version only! + declarative = true; + eula = true; openFirewall = false; # do this manually instead - declarative = true; whitelist = { "SECRET1" = ""; From 72d68585bc559c3315828723f581c589f9648114 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 3 Aug 2025 00:52:11 +1000 Subject: [PATCH 111/197] fix minecraft-server unable to bind to socket unset server-ip was too general --- hosts/hyrule/minecraft-server.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/hyrule/minecraft-server.nix b/hosts/hyrule/minecraft-server.nix index 48237d8..117fed3 100644 --- a/hosts/hyrule/minecraft-server.nix +++ b/hosts/hyrule/minecraft-server.nix @@ -19,7 +19,7 @@ # REF: https://minecraft.wiki/w/Server.properties#Java_Edition serverProperties = { - # server-ip = "" # listen on all addresses if unset + server-ip = "195.114.14.69"; # listen on all addresses if unset server-port = 45000; # connection port "query.port" = 45000; # share game info/advertising information user-native-transport = true; # Linux packet RX/TX optimizations From 874852ca073ccc59e85e5a23ae555fe49b441c1c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 3 Aug 2025 00:53:38 +1000 Subject: [PATCH 112/197] fix minecraft-server G1GC garbage collector given invalid args why does wiki.nixos.org recommend +CMSIncrementalPacing and +CMSClassUnloadingEnabled for G1GC?? --- hosts/hyrule/minecraft-server.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/hyrule/minecraft-server.nix b/hosts/hyrule/minecraft-server.nix index 117fed3..43a4efd 100644 --- a/hosts/hyrule/minecraft-server.nix +++ b/hosts/hyrule/minecraft-server.nix @@ -60,6 +60,6 @@ spawn-monsters = true; spawn-protection = 0; }; - jvmOpts = "-Xms2046M -Xmx2046M -XX:+UseG1GC -XX:+CMSIncrementalPacing -XX:+CMSClassUnloadingEnabled -XX:ParallelGCThreads=2 -XX:MinHeapFreeRatio=5 -XX:MaxHeapFreeRatio=10"; + jvmOpts = "-Xms2046M -Xmx2046M -XX:+UseG1GC -XX:ParallelGCThreads=2 -XX:MinHeapFreeRatio=5 -XX:MaxHeapFreeRatio=10"; }; } From 0eeb94b65c57980c6c688f0c4355b79981596227 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 7 Aug 2025 10:45:00 +1000 Subject: [PATCH 113/197] re-add nimble to lang pkgs --- hosts/lolcathost/default.nix | 1 + hosts/myputer/default.nix | 1 + 2 files changed, 2 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index e6d03fd..c8479f5 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -231,6 +231,7 @@ in { rustc # Nim nim + nimble # Go go diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 486c59d..369fc20 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -232,6 +232,7 @@ in { rustc # Nim nim + nimble # Go go From ee7e38e7bacae4d21a50b968fa1c05031a9aa3e5 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 8 Aug 2025 11:28:11 +1000 Subject: [PATCH 114/197] add git aliases --- homes/modules/git.nix | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/homes/modules/git.nix b/homes/modules/git.nix index 3e0cfb0..82d0f1e 100755 --- a/homes/modules/git.nix +++ b/homes/modules/git.nix @@ -5,6 +5,19 @@ }: { programs.git = { enable = true; + lfs.enable = true; + + userName = "Emile Clark-Boman"; + userEmail = "eclarkboman@gmail.com"; + + aliases = { + s = "status"; + d = "diff"; + l = "log"; + c = "commit"; + p = "push"; + }; + extraConfig = { color.ui = true; core.editor = "hx"; @@ -22,8 +35,5 @@ }; }; }; - - userName = "Emile Clark-Boman"; - userEmail = "eclarkboman@gmail.com"; }; } From 0129fe2b9740db4a37a1fad0daa49d4b3645edb3 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 8 Aug 2025 14:08:50 +1000 Subject: [PATCH 115/197] renamed TODO -> +.md --- TODO => TODO.md | 1 - 1 file changed, 1 deletion(-) rename TODO => TODO.md (98%) diff --git a/TODO b/TODO.md similarity index 98% rename from TODO rename to TODO.md index bb8e65c..6b9f235 100644 --- a/TODO +++ b/TODO.md @@ -1,5 +1,4 @@ ## Next Up -0. Rename TODO -> TODO.md 1. Rename user "ae" to "cry" or "vps" 2. Add 404 page to nginx on hyrule 3. Add a user called "mirror" that stores important mirrors (inspiration: https://git.gay/mirror) From d3a642fafbea6285533db3d734879fecc3e0872d Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 8 Aug 2025 20:13:51 +1000 Subject: [PATCH 116/197] add "box" script for managing temp directories --- scripts/box | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100755 scripts/box diff --git a/scripts/box b/scripts/box new file mode 100755 index 0000000..7f69cb0 --- /dev/null +++ b/scripts/box @@ -0,0 +1,44 @@ +#!/usr/bin/env bash +USAGE="Usage: box [--enter]" + +# ===== Configuration ===== # +DATA_DIR="$HOME/.data/box" +# ========================= # + +function setup { + mkdir -p "$DATA_DIR" &>/dev/null +} + +function box { + mktemp -d + # TODO: use a custom name instead +} + +set -euo pipefail + +ENTER=false +for arg in $@; do + case "$arg" in + -e|--enter) + ENTER=true + shift + ;; + -h|--help) + echo "$USAGE" + ;; + -*) + echo "[!] Unknown opt \"$arg\"" >&2 + ;; + *) + echo "[!] Unknown arg \"$arg\"" >&2 + ;; + esac +done + +setup + +BOX=$(box) + +if [[ "$ENTER" == true ]]; then + cd "$BOX" +fi From d68132b8fb4fc76cab1e86a6c9c929e2e1889c48 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 8 Aug 2025 20:14:52 +1000 Subject: [PATCH 117/197] make fish dotfiles more verbose + add gitignore function to generate .gitignore files --- homes/modules/fish.nix | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/homes/modules/fish.nix b/homes/modules/fish.nix index eaca566..8fdcc4b 100755 --- a/homes/modules/fish.nix +++ b/homes/modules/fish.nix @@ -12,6 +12,14 @@ config = { programs.fish = { enable = true; + generateCompletions = true; + + vendor = { + config.enable = true; + functions.enable = true; + completions.enable = true; + }; + interactiveShellInit = '' # add dotnet completions if it exists (ie we're in a virtual environment) if type -q dotnet @@ -27,8 +35,13 @@ echo -n $greetings[(random 1 (count $greetings))] end + function gitignore -a type + curl -sL "https://www.gitignore.io/api/$type" + end + set -g fish_greeting (rand_greet) ''; + plugins = [ { name = "grc"; From 7ab29bfe07261abc7c9b05c868303577489e01f2 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 8 Aug 2025 20:15:44 +1000 Subject: [PATCH 118/197] add custom huggingface_hub packages (learning from hf-cli's authentication workflow) --- hosts/packages/huggingface_hub/flake.nix | 35 +++++++++++ hosts/packages/huggingface_hub/hf-xet.nix | 56 +++++++++++++++++ .../huggingface_hub/huggingface_hub.nix | 62 +++++++++++++++++++ 3 files changed, 153 insertions(+) create mode 100644 hosts/packages/huggingface_hub/flake.nix create mode 100644 hosts/packages/huggingface_hub/hf-xet.nix create mode 100644 hosts/packages/huggingface_hub/huggingface_hub.nix diff --git a/hosts/packages/huggingface_hub/flake.nix b/hosts/packages/huggingface_hub/flake.nix new file mode 100644 index 0000000..37814d9 --- /dev/null +++ b/hosts/packages/huggingface_hub/flake.nix @@ -0,0 +1,35 @@ +# Template: https://nixos-and-flakes.thiscute.world/development/intro +{ + description = "Humanity's Last Exam - Devshell"; + + inputs = { + nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05"; + }; + + outputs = {nixpkgs, ...}: let + system = "x86_64-linux"; + pkgs = import nixpkgs { + inherit system; + }; + python = pkgs.python312.override { + self = python; + packageOverrides = pyfinal: pyprev: { + huggingface-hub = pyfinal.callPackage ./huggingface_hub.nix {}; + hf-xet = pyfinal.callPackage ./hf-xet.nix {}; + }; + }; + in { + devShells."${system}".default = pkgs.mkShell { + packages = [ + (python.withPackages (pypkgs: [ + pypkgs.huggingface-hub + ])) + ]; + + shell = "${pkgs.bash}/bin/bash"; + shellHook = '' + alias hf=huggingface-cli + ''; + }; + }; +} diff --git a/hosts/packages/huggingface_hub/hf-xet.nix b/hosts/packages/huggingface_hub/hf-xet.nix new file mode 100644 index 0000000..0f4c631 --- /dev/null +++ b/hosts/packages/huggingface_hub/hf-xet.nix @@ -0,0 +1,56 @@ +{ + lib, + buildPythonPackage, + fetchFromGitHub, + pkg-config, + rustPlatform, + openssl, +}: +buildPythonPackage rec { + pname = "hf-xet"; + version = "1.1.5"; + pyproject = true; + + src = fetchFromGitHub { + owner = "huggingface"; + repo = "xet-core"; + tag = "v${version}"; + hash = "sha256-udjZcXTH+Mc4Gvj6bSPv1xi4MyXrLeCYav+7CzKWyhY="; + }; + + sourceRoot = "${src.name}/hf_xet"; + + cargoDeps = rustPlatform.fetchCargoVendor { + inherit + pname + version + src + sourceRoot + ; + hash = "sha256-PTzYubJHFvhq6T3314R4aqBAJlwehOqF7SbpLu4Jo6E="; + }; + + nativeBuildInputs = [ + pkg-config + rustPlatform.cargoSetupHook + rustPlatform.maturinBuildHook + ]; + + buildInputs = [ + openssl + ]; + + env.OPENSSL_NO_VENDOR = 1; + + pythonImportsCheck = ["hf_xet"]; + + # No tests (yet?) + doCheck = false; + + meta = { + description = "Xet client tech, used in huggingface_hub"; + homepage = "https://github.com/huggingface/xet-core/tree/main/hf_xet"; + changelog = "https://github.com/huggingface/xet-core/releases/tag/v${version}"; + license = lib.licenses.asl20; + }; +} diff --git a/hosts/packages/huggingface_hub/huggingface_hub.nix b/hosts/packages/huggingface_hub/huggingface_hub.nix new file mode 100644 index 0000000..02b03b7 --- /dev/null +++ b/hosts/packages/huggingface_hub/huggingface_hub.nix @@ -0,0 +1,62 @@ +/* +* WARNING: Just use `pkgs.python312Packages.huggingface-hub` (or change python version) +* WARNING: I didn't realise it existed when I packaged this. +* +* Nix Resources: +* 1. https://wiki.nixos.org/wiki/Python +* 2. https://nixos.org/manual/nixpkgs/unstable/#developing-with-python +* +* Hugging Face Resources: +* 1. https://github.com/huggingface/huggingface_hub +* 2. https://huggingface.co/docs/huggingface_hub/main/en/guides/cli +*/ +{ + lib, + buildPythonPackage, + fetchPypi, + # build time dependencies + setuptools, + # runtime dependencies + filelock, + fsspec, + hf-xet, + pyyaml, + requests, + tqdm, + typing-extensions, +}: +buildPythonPackage rec { + pname = "huggingface_hub"; + version = "0.34.3"; + + src = fetchPypi { + inherit pname version; + hash = "sha256-1YEw/VqnQISAaBR1SRwKvX6DVEIIL7w+9NRbbDn4OFM="; + }; + + pyproject = true; + doCheck = false; # skip unit testing + pythonImportsCheck = ["huggingface_hub"]; + + # buildtime dependencies + build-system = [ + setuptools + ]; + # runtime dependencies + dependencies = [ + filelock + fsspec + hf-xet + pyyaml + requests + tqdm + typing-extensions + ]; + + meta = rec { + description = "The official Python client for the Huggingface Hub."; + homepage = "https://github.com/huggingface/huggingface_hub"; + changelog = "${homepage}/releases/tag/v${version}"; + license = lib.licenses.asl20; # Apache License 2.0 + }; +} From 63e8a31e7fbe95355e753eaa9e95c086a9559243 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 8 Aug 2025 20:20:13 +1000 Subject: [PATCH 119/197] add fish function for file name searching --- homes/modules/fish.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/homes/modules/fish.nix b/homes/modules/fish.nix index 8fdcc4b..bf496db 100755 --- a/homes/modules/fish.nix +++ b/homes/modules/fish.nix @@ -39,6 +39,11 @@ curl -sL "https://www.gitignore.io/api/$type" end + # ripgrep on files + function rgf + rg --files | rg $args + end + set -g fish_greeting (rand_greet) ''; From 7069840beb9a5a1fea4aca3fe094137c58cf3b35 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 12 Aug 2025 21:11:08 +1000 Subject: [PATCH 120/197] add gwenview + libreoffice apps --- hosts/myputer/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 369fc20..e120f67 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -208,6 +208,8 @@ in { hyprpicker qbittorrent signal-desktop + kdePackages.gwenview # image viewer + libreoffice (callPackage ../sddm-theme-corners.nix {}).sddm-theme-corners # dependencies for my sddm theme: From 60a6b07c9dc20f93669516892bbcb27c32700762 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 12 Aug 2025 21:11:38 +1000 Subject: [PATCH 121/197] comment programs.fish.vendor.* --- homes/modules/fish.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/homes/modules/fish.nix b/homes/modules/fish.nix index bf496db..0728abc 100755 --- a/homes/modules/fish.nix +++ b/homes/modules/fish.nix @@ -14,11 +14,11 @@ enable = true; generateCompletions = true; - vendor = { - config.enable = true; - functions.enable = true; - completions.enable = true; - }; + # vendor = { + # config.enable = true; + # functions.enable = true; + # completions.enable = true; + # }; interactiveShellInit = '' # add dotnet completions if it exists (ie we're in a virtual environment) From dc12ab717b99149d19d3b7b07aa5919da51f2be2 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 14:54:59 +1000 Subject: [PATCH 122/197] remove gamescope.desktop entry, add GE Proton --- hosts/modules/steam.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/hosts/modules/steam.nix b/hosts/modules/steam.nix index 07f3ae1..5c72185 100644 --- a/hosts/modules/steam.nix +++ b/hosts/modules/steam.nix @@ -14,11 +14,15 @@ programs = { steam = { enable = true; - gamescopeSession.enable = true; + gamescopeSession.enable = false; # .desktop entry for gamescope remotePlay.openFirewall = true; dedicatedServer.openFirewall = true; localNetworkGameTransfers.openFirewall = true; + + extraCompatPackages = with pkgs; [ + proton-ge-bin + ]; }; gamemode.enable = true; From 7ecf75bef5268933a2cc05e66184e2a2a991d127 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 14:55:27 +1000 Subject: [PATCH 123/197] add hypr screenshot utility --- hosts/myputer/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index e120f67..87cd7f9 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -206,6 +206,7 @@ in { bluetui wl-clipboard # clipboard for wayland hyprpicker + hyprshot # screenshot utility qbittorrent signal-desktop kdePackages.gwenview # image viewer From 186c0c741afad6d24c03af111919145019fc7821 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 14:56:01 +1000 Subject: [PATCH 124/197] add binary debug utils --- hosts/myputer/default.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 87cd7f9..bb00197 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -223,10 +223,11 @@ in { shellcheck grc # colorise command outputs - # Systems Emulation + # Systems Programming & Compilation qemu # Fellice Bellard's Quick Emulator - # Make gnumake + strace + ltrace # C Family gcc clang From 98244e7ecfbdf9e6d0e92384e909e57abe640ce1 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 14:56:23 +1000 Subject: [PATCH 125/197] (test) openvas on myputer --- hosts/myputer/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index bb00197..af7b5c8 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -212,6 +212,11 @@ in { kdePackages.gwenview # image viewer libreoffice + # TEST: WARNING + # ospd-openvas + # openvas-scanner + # openvas-smb + (callPackage ../sddm-theme-corners.nix {}).sddm-theme-corners # dependencies for my sddm theme: pkgs.libsForQt5.qt5.qtgraphicaleffects From d077f4bfd99d2c3082661bc544b53e53443d39aa Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:00:14 +1000 Subject: [PATCH 126/197] add fontgrep script --- scripts/fontgrep | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100755 scripts/fontgrep diff --git a/scripts/fontgrep b/scripts/fontgrep new file mode 100755 index 0000000..6e06a64 --- /dev/null +++ b/scripts/fontgrep @@ -0,0 +1,12 @@ +#!/usr/bin/env bash + +function fontgrep { + fc-list \ + | grep $@ \ + | awk '{$1=""; print substr($0, 2, length($0)-1) }' \ + | grep -oE '^\s*[^,]+' \ + | sort \ + | uniq +} + +fontgrep $@ From b2e95eebd7b4aeb9d355b024bbd501234d292dd9 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:00:45 +1000 Subject: [PATCH 127/197] provide nixpkgs-unstable to system derivations --- flake.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/flake.nix b/flake.nix index c7c435b..382bca6 100644 --- a/flake.nix +++ b/flake.nix @@ -57,7 +57,7 @@ # i be on my puter fr myputer = nixpkgs.lib.nixosSystem { # nix passes these to every single module - specialArgs = {inherit inputs;}; + specialArgs = {inherit inputs pkgs-unstable;}; modules = [ ./hosts/myputer @@ -67,7 +67,7 @@ # my laptop 0w0 lolcathost = nixpkgs.lib.nixosSystem { - specialArgs = {inherit inputs;}; + specialArgs = {inherit inputs pkgs-unstable;}; modules = [ ./hosts/lolcathost From f4b4052c30edde51d495fd92eb48c37284630968 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:04:24 +1000 Subject: [PATCH 128/197] add foot terminal to lolcathost --- homes/me/default.nix | 6 +- homes/modules/term/foot.nix | 327 +++++++++++++++++++++++++++++++++++ hosts/lolcathost/default.nix | 2 +- 3 files changed, 332 insertions(+), 3 deletions(-) create mode 100644 homes/modules/term/foot.nix diff --git a/homes/me/default.nix b/homes/me/default.nix index 3ef0dda..fac7454 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -4,6 +4,7 @@ lib, config, pkgs, + pkgs-unstable, ... }: { imports = [ @@ -15,11 +16,12 @@ ../modules/btop.nix ../modules/term/ghostty.nix + ../modules/term/foot.nix # ../modules/term/rio.nix ../modules/firefox.nix - #../modules/hypr/hypridle.nix - ../modules/hypr/hyprlock.nix + #../modules/wm/hypr/hypridle.nix + ../modules/wm/hypr/hyprlock.nix ../modules/kanshi.nix ../modules/ags ]; diff --git a/homes/modules/term/foot.nix b/homes/modules/term/foot.nix new file mode 100644 index 0000000..348eefa --- /dev/null +++ b/homes/modules/term/foot.nix @@ -0,0 +1,327 @@ +{pkgs-unstable, ...}: { + programs.foot = { + enable = true; + package = pkgs-unstable.foot; + + server.enable = true; + + settings = let + none = "\"\""; + in { + main = { + term = "foot"; # set $TERM + login-shell = "no"; + title = "foot"; + locked-title = "no"; + + # font = "GeistMono Nerd Font:size=12"; + # font = "Mononoki Nerd Font Mono:size=12"; + # font = "0xProto Nerd Font Mono:size=12"; + font = "JetBrainsMonoNL Nerd Font:size=12"; + # font-bold = ""; + # font-italice = ""; + # font-bold-italice = ""; + # font-size-adjustment = 0.5; + # line-height = ...; + # letter-spacing = 0; + # horizontal-letter-offset = 0; + # vertical-letter-offset = 0; + # underline-offset = ...; + # underline-thickness = ...; + # strikeout-thickness = ...; + box-drawings-uses-font-glyphs = "no"; + dpi-aware = "no"; + gamma-correct-blending = "no"; + + initial-color-theme = "1"; + # initial-window-size-pixels = "700x500"; # pixel COLSxROWS + initial-window-size-chars = "90x26"; # char COLSxROWS + initial-window-mode = "windowed"; + pad = "32x32 center-when-maximized-and-fullscreen"; + resize-by-cells = "yes"; + resize-keep-grid = "yes"; + resize-delay-ms = "100"; + + bold-text-in-bright = "no"; + word-delimiters = ",│`|:\"'()[]{}<>"; + selection-target = "primary"; + # workers = ...; # number of logical CPUs + }; + + # environment = { + # name = "value"; + # } + + security = { + osc52 = "enabled"; + }; + + bell = { + system = "no"; + urgent = "no"; + notify = "no"; + visual = "no"; + # command = ...; + # command-focused = "no"; + }; + + desktop-notifications = { + command = "notify-send --wait --app-name \${app-id} --icon \${app-id} --category \${category} --urgency \${urgency} --expire-time \${expire-time} --hint STRING:image-path:\${icon} --hint BOOLEAN:suppress-sound:\${muted} --hint STRING:sound-name:\${sound-name} --replace-id \${replace-id} \${action-argument} --print-id -- \${title} \${body}"; + command-action-argument = "--action \${action-name=\${action-label}}"; + close = none; + inhibit-when-focused = "no"; + }; + + scrollback = { + lines = 1000; + multiplier = 1.0; + indicator-position = "relative"; + indicator-format = none; + }; + + url = { + launch = "xdg-open \${url}"; + label-letters = "sadfjklewcmpgh"; + osc8-underline = "url-mode"; + regex = "(((https?://|mailto:|ftp://|file:|ssh:|ssh://|git://|tel:|magnet:|ipfs://|ipns://|gemini://|gopher://|news:)|www\\.)([0-9a-zA-Z:/?#@!$&*+,;=.~_%^\\-]+|\\([]\\[\"0-9a-zA-Z:/?#@!$&'*+,;=.~_%^\\-]*\\)|\\[[\\(\\)\"0-9a-zA-Z:/?#@!$&'*+,;=.~_%^\\-]*\\]|\"[]\\[\\(\\)0-9a-zA-Z:/?#@!$&'*+,;=.~_%^\\-]*\"|'[]\\[\\(\\)0-9a-zA-Z:/?#@!$&*+,;=.~_%^\\-]*')+([0-9a-zA-Z/#@$&*+=~_%^\\-]|\\([]\\[\"0-9a-zA-Z:/?#@!$&'*+,;=.~_%^\\-]*\\)|\\[[\\(\\)\"0-9a-zA-Z:/?#@!$&'*+,;=.~_%^\\-]*\\]|\"[]\\[\\(\\)0-9a-zA-Z:/?#@!$&'*+,;=.~_%^\\-]*\"|'[]\\[\\(\\)0-9a-zA-Z:/?#@!$&*+,;=.~_%^\\-]*'))"; + }; + + # "regex:your-fancy-name" = { + # regex = ...; + # launch = "[path to script/application] \${match}" + # }; + # + # key-bindings = { + # regex-launch = "[your-fancy-name] Control+Shift+q"; + # regex-copy = "[your-fancy-name] Control+Alt+shift+q"; + # }; + + cursor = { + style = "block"; + blink = "no"; + # blink-rate = 500; + beam-thickness = 1.0; + # underline-thickness = ...; + }; + + mouse = { + hide-when-typing = "yes"; + alternate-scroll-mode = "yes"; + }; + + touch = { + long-press-delay = 400; + }; + + # Theme: Dracula + # REF: https://github.com/dracula/foot + colors = { + alpha = 1.0; + alpha-mode = "default"; # default/matching/all + + background = "282a36"; + foreground = "f8f8f2"; + + ## Normal/regular colors (color palette 0-7) + regular0 = "21222c"; # black + regular1 = "ff5555"; # red + regular2 = "50fa7b"; # green + regular3 = "f1fa8c"; # yellow + regular4 = "bd93f9"; # blue + regular5 = "ff79c6"; # magenta + regular6 = "8be9fd"; # cyan + regular7 = "f8f8f2"; # white + + ## Bright colors (color palette 8-15) + bright0 = "6272a4"; # bright black + bright1 = "ff6e6e"; # bright red + bright2 = "69ff94"; # bright green + bright3 = "ffffa5"; # bright yellow + bright4 = "d6acff"; # bright blue + bright5 = "ff92df"; # bright magenta + bright6 = "a4ffff"; # bright cyan + bright7 = "ffffff"; # bright white + + ## Misc colors + selection-foreground = "ffffff"; + selection-background = "44475a"; + # jump-labels= # black-on-yellow + # scrollback-indicator= # black-on-bright-blue + # search-box-no-match= # black-on-red + # search-box-match= # black-on-yellow + urls = "8be9fd"; + + flash = "7f7f00"; + flash-alpha = 0.5; + }; + + # Alternative colour palette (see `man 5 foot.ini`) + colors2 = { + alpha = 1.0; + alpha-mode = "default"; + + background = "191724"; + foreground = "e0def4"; + + regular0 = "26233a"; # black (Overlay) + regular1 = "eb6f92"; # red (Love) + regular2 = "9ccfd8"; # green (Foam) + regular3 = "f6c177"; # yellow (Gold) + regular4 = "31748f"; # blue (Pine) + regular5 = "c4a7e7"; # magenta (Iris) + regular6 = "ebbcba"; # cyan (Rose) + regular7 = "e0def4"; # white (Text) + + bright0 = "47435d"; # bright black (lighter Overlay) + bright1 = "ff98ba"; # bright red (lighter Love) + bright2 = "c5f9ff"; # bright green (lighter Foam) + bright3 = "ffeb9e"; # bright yellow (lighter Gold) + bright4 = "5b9ab7"; # bright blue (lighter Pine) + bright5 = "eed0ff"; # bright magenta (lighter Iris) + bright6 = "ffe5e3"; # bright cyan (lighter Rose) + bright7 = "fefcff"; # bright white (lighter Text) + + selection-foreground = "ffffff"; + selection-background = "393553"; + + urls = "ebbcba"; # Rose + + flash = "f6c177"; # yellow (Gold) + flash-alpha = 0.5; + + cursor = "191724 e0def4"; + }; + + # csd = { + # preferred = "server"; + # size = 26; + # font = ...; + # color = ...; # foreground color + # hide-when-maximized = "no"; + # border-width = 0; + # border-color = ...; + # button-width = 26; + # button-color = ...; # background color + # button-minimize-color = ...; + # button-maximize-color = ...; + # button-close-color = ...; + # }; + + key-bindings = { + scrollback-up-page = "Shift+Page_Up Shift+KP_Page_Up"; + # scrollback-up-half-page = "none"; + # scrollback-up-line = "none"; + scrollback-down-page = "Shift+Page_Down Shift+KP_Page_Down"; + # scrollback-down-half-page = "none"; + # scrollback-down-line = "none"; + # scrollback-home = "none"; + # scrollback-end = "none"; + + clipboard-copy = "Control+Shift+c XF86Copy"; + clipboard-paste = "Control+Shift+v XF86Paste"; + primary-paste = "Shift+Insert"; + search-start = "Control+Shift+r"; + + font-increase = "Control+plus Control+equal Control+KP_Add"; + font-decrease = "Control+minus Control+KP_Subtract"; + font-reset = "Control+0 Control+KP_0"; + + spawn-terminal = "Control+Shift+n"; + # minimize = "none"; + # maximize = "none"; + # fullscreen = "none"; + + pipe-visible = "[sh -c \"xurls | fuzzel | xargs -r firefox\"] none"; + pipe-scrollback = "[sh -c \"xurls | fuzzel | xargs -r firefox\"] none"; + pipe-selected = "[xargs -r firefox] none"; + pipe-command-output = "[wl-copy] none"; + + show-urls-launch = "Control+Shift+o"; + # show-urls-copy = "none"; + # show-urls-persistent = "none"; + + prompt-prev = "Control+Shift+z"; + prompt-next = "Control+Shift+x"; + + unicode-input = "Control+Shift+u"; + # color-theme-switch-1 = "none"; + # color-theme-switch-2 = "none"; + color-theme-toggle = "Control+Alt+p"; + + # noop = "none"; + # quit = "none"; + }; + + search-bindings = { + cancel = "Control+g Control+c Escape"; + commit = "Return KP_Enter"; + + find-prev = "Control+r"; + find-next = "Control+s"; + + cursor-left = "Left Control+b"; + cursor-left-word = "Control+Left Mod1+b"; + cursor-right = "Right Control+f"; + cursor-right-word = "Control+Right Mod1+f"; + cursor-home = "Home Control+a"; + cursor-end = "End Control+e"; + + delete-prev = "BackSpace"; + delete-prev-word = "Mod1+BackSpace Control+BackSpace"; + delete-next = "Delete"; + delete-next-word = "Mod1+d Control+Delete"; + delete-to-start = "Control+u"; + delete-to-end = "Control+k"; + + extend-char = "Shift+Right"; + extend-to-word-boundary = "Control+w Control+Shift+Right"; + extend-to-next-whitespace = "Control+Shift+w"; + extend-line-down = "Shift+Down"; + extend-backward-char = "Shift+Left"; + extend-backward-to-word-boundary = "Control+Shift+Left"; + # extend-backward-to-next-whitespace = "none"; + extend-line-up = "Shift+Up"; + + clipboard-paste = "Control+v Control+Shift+v Control+y XF86Paste"; + primary-paste = "Shift+Insert"; + + # unicode-input = "none"; + + scrollback-up-page = "Shift+Page_Up Shift+KP_Page_Up"; + # scrollback-up-half-page = "none"; + # scrollback-up-line = "none"; + scrollback-down-page = "Shift+Page_Down Shift+KP_Page_Down"; + # scrollback-down-half-page = "none"; + # scrollback-down-line = "none"; + # scrollback-home = "none"; + # scrollback-end = "none"; + }; + + url-bindings = { + cancel = "Control+g Control+c Control+d Escape"; + toggle-url-visible = "t"; + }; + + text-bindings = { + "\\x03" = "Mod4+c"; # map Super+c -> Control+c + }; + + mouse-bindings = { + scrollback-up-mouse = "BTN_WHEEL_BACK"; + scrollback-down-mouse = "BTN_WHEEL_FORWARD"; + font-increase = "Control+BTN_WHEEL_BACK"; + font-decrease = "Control+BTN_WHEEL_FORWARD"; + selection-override-modifiers = "Shift"; + primary-paste = "BTN_MIDDLE"; + select-begin = "BTN_LEFT"; + select-begin-block = "Control+BTN_LEFT"; + select-extend = "BTN_RIGHT"; + select-extend-character-wise = "Control+BTN_RIGHT"; + select-word = "BTN_LEFT-2"; + select-word-whitespace = "Control+BTN_LEFT-2"; + select-quote = "BTN_LEFT-3"; + select-row = "BTN_LEFT-4"; + }; + }; + }; +} diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index e6d03fd..b1243b9 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -180,7 +180,7 @@ in { home-manager = { users.me = import ../../homes/me; - #extraSpecialArgs = {inherit inputs pkgs;}; + extraSpecialArgs = {inherit inputs pkgs pkgs-unstable;}; sharedModules = [ inputs.ags.homeManagerModules.default ]; From af62453ef7914597a055f7d895a1bc4a821ad2ee Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:05:02 +1000 Subject: [PATCH 129/197] helix handles C source better --- homes/modules/editor/helix.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/homes/modules/editor/helix.nix b/homes/modules/editor/helix.nix index 555ec75..e7d6003 100755 --- a/homes/modules/editor/helix.nix +++ b/homes/modules/editor/helix.nix @@ -131,6 +131,8 @@ } { name = "c"; + file-types = ["c" "h"]; # use .hpp for C++ + auto-format = false; formatter.command = "${pkgs.clang-tools}/bin/clang-format"; language-servers = ["clangd"]; } From 91f1033c9e891a6425c8b0de07df22acd24f5527 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:05:32 +1000 Subject: [PATCH 130/197] move shell aliases into fish.nix --- homes/modules/fish.nix | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/homes/modules/fish.nix b/homes/modules/fish.nix index eaca566..51a40f4 100755 --- a/homes/modules/fish.nix +++ b/homes/modules/fish.nix @@ -28,7 +28,19 @@ end set -g fish_greeting (rand_greet) + + ''; + + shellAliases = { + brip = "batgrep"; # bat + ripgrep + man = "batman"; # bat + man + ls = "eza --color=auto"; + l = "eza -Alh --color=auto --icons=auto"; + ll = "eza -lh --color=auto --icons=auto"; + li = "eza --color=auto --git-ignore"; + }; + plugins = [ { name = "grc"; From d1cfd55e677aa684924df8b2e7c8949f59dea9e2 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:06:03 +1000 Subject: [PATCH 131/197] create homes/modules/wm --- homes/modules/{ => wm}/hypr/hypridle.nix | 0 homes/modules/{ => wm}/hypr/hyprland.nix | 0 homes/modules/{ => wm}/hypr/hyprlock.nix | 0 3 files changed, 0 insertions(+), 0 deletions(-) rename homes/modules/{ => wm}/hypr/hypridle.nix (100%) rename homes/modules/{ => wm}/hypr/hyprland.nix (100%) rename homes/modules/{ => wm}/hypr/hyprlock.nix (100%) diff --git a/homes/modules/hypr/hypridle.nix b/homes/modules/wm/hypr/hypridle.nix similarity index 100% rename from homes/modules/hypr/hypridle.nix rename to homes/modules/wm/hypr/hypridle.nix diff --git a/homes/modules/hypr/hyprland.nix b/homes/modules/wm/hypr/hyprland.nix similarity index 100% rename from homes/modules/hypr/hyprland.nix rename to homes/modules/wm/hypr/hyprland.nix diff --git a/homes/modules/hypr/hyprlock.nix b/homes/modules/wm/hypr/hyprlock.nix similarity index 100% rename from homes/modules/hypr/hyprlock.nix rename to homes/modules/wm/hypr/hyprlock.nix From 940a79292ecc9331577d31d31ad0beed3e3e5fe3 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:09:20 +1000 Subject: [PATCH 132/197] move hyprland config to modules/wm/hyprland.nix --- hosts/lolcathost/default.nix | 4 +++- hosts/modules/wm/hyprland.nix | 9 +++++++++ hosts/myputer/default.nix | 10 +++------- 3 files changed, 15 insertions(+), 8 deletions(-) create mode 100644 hosts/modules/wm/hyprland.nix diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index b1243b9..1cda04f 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -1,18 +1,20 @@ { lib, pkgs, + pkgs-unstable, inputs, config, ... }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; - sha256 = "1kk5qzfb87mkgy6vzm7x8z8akxr3k8k7839yjdy48z034pvidhsr"; + sha256 = "1y919cqrlmq0k44rgnacaq4zq37jj4rdh6f2swp6y2jiz28xb0iq"; }; in { imports = [ ./hardware-configuration.nix (import "${home-manager}/nixos") + ../modules/wm/hyprland.nix ../modules/steam.nix ../modules/obsidian.nix diff --git a/hosts/modules/wm/hyprland.nix b/hosts/modules/wm/hyprland.nix new file mode 100644 index 0000000..f2960ed --- /dev/null +++ b/hosts/modules/wm/hyprland.nix @@ -0,0 +1,9 @@ +{...}: { + programs = { + hyprland = { + enable = true; + withUWSM = true; # Universal Wayland Session Manager + xwayland.enable = true; + }; + }; +} diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 486c59d..1f22c62 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -14,6 +14,8 @@ in { ./hardware-configuration.nix (import "${home-manager}/nixos") + ../modules/wm/hyprland.nix + ../modules/steam.nix ../modules/obsidian.nix @@ -110,7 +112,7 @@ in { defaultSession = "hyprland" + ( - if config.programs.hyprland.withUWSM == true + if config.programs.hyprland.withUWSM then "-uwsm" else null ); @@ -318,12 +320,6 @@ in { #}; programs = { - hyprland = { - enable = true; - withUWSM = true; # Universal Wayland Session Manager - xwayland.enable = true; - }; - zsh.enable = true; fish.enable = true; From ec542cc7387195df05b0b069eb52348f3b675b9d Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:11:28 +1000 Subject: [PATCH 133/197] trial river wm --- hosts/lolcathost/default.nix | 8 ++++++++ hosts/modules/wm/river.nix | 5 +++++ 2 files changed, 13 insertions(+) create mode 100644 hosts/modules/wm/river.nix diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 1cda04f..17ed254 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -14,7 +14,9 @@ in { imports = [ ./hardware-configuration.nix (import "${home-manager}/nixos") + ../modules/wm/hyprland.nix + # ../modules/wm/river.nix ../modules/steam.nix ../modules/obsidian.nix @@ -118,6 +120,12 @@ in { ); }; + dbus = { + # NOTE: programs.uwsm.enable sets implementation to dbus-broker, + # NOTE: however this seems to break dbus + implementation = lib.mkForce "dbus"; + }; + # Multimedia Framework # With backwards compatability for alsa/pulseaudio/jack pipewire = { diff --git a/hosts/modules/wm/river.nix b/hosts/modules/wm/river.nix new file mode 100644 index 0000000..02721cc --- /dev/null +++ b/hosts/modules/wm/river.nix @@ -0,0 +1,5 @@ +{...}: { + programs = { + river.enable = true; + }; +} From 1c0ee9453281948a4f5585a5d8a72e57ea2d2089 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:12:18 +1000 Subject: [PATCH 134/197] trial crywl (personal dwl fork) --- hosts/lolcathost/default.nix | 10 +-- hosts/modules/wm/crywl.nix | 116 +++++++++++++++++++++++++++++++++++ 2 files changed, 122 insertions(+), 4 deletions(-) create mode 100644 hosts/modules/wm/crywl.nix diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 17ed254..4726f05 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -17,6 +17,7 @@ in { ../modules/wm/hyprland.nix # ../modules/wm/river.nix + ../modules/wm/crywl.nix ../modules/steam.nix ../modules/obsidian.nix @@ -208,6 +209,7 @@ in { # ---- SYSTEM PACKAGES ----- environment.systemPackages = with pkgs; [ # User Environment + # crywl swww helvum easyeffects @@ -312,13 +314,13 @@ in { ]; programs = { - hyprland = { + crywl = { enable = true; - withUWSM = true; # Universal Wayland Session Manager - xwayland.enable = true; + xwayland.enable = false; + defaultSession = false; + useUnmodifiedDWL = false; }; - zsh.enable = true; fish.enable = true; nix-ld.enable = true; diff --git a/hosts/modules/wm/crywl.nix b/hosts/modules/wm/crywl.nix new file mode 100644 index 0000000..1454af2 --- /dev/null +++ b/hosts/modules/wm/crywl.nix @@ -0,0 +1,116 @@ +{ + config, + lib, + pkgs, + ... +}: let + cfg = config.programs.crywl; +in { + options.programs.crywl = with lib; { + enable = mkEnableOption "CryWL"; + xwayland.enable = mkEnableOption "XWayland"; + defaultSession = mkEnableOption "CryWL as the default login session"; + + # currently DWL 0.7 (also beware I'll barely ever update the original DWL refs) + useUnmodifiedDWL = mkOption { + type = types.bool; + default = false; + description = "Whether to use unmodified DWL source code (latest stable release)"; + }; + }; + + config = lib.mkIf cfg.enable (let + xwaylandEnabled = cfg.xwayland.enable; + defaultSession = cfg.defaultSession; + useUnmodifiedDWL = cfg.useUnmodifiedDWL; + in { + services.displayManager = { + sessionPackages = [ + pkgs.crywl + ]; + + defaultSession = lib.mkIf defaultSession "crywl"; + }; + + environment.systemPackages = [ + pkgs.crywl + ]; + + nixpkgs.overlays = [ + (self: super: { + crywl = super.dwl.overrideAttrs (oldAttrs: rec { + pname = "crywl"; + version = "0.1-unstable"; + + src = let + dwl_0_70 = { + rev = "74e45c4014ae7048ecbb76eb6f54034b8b479480"; + hash = "sha256-7SoCITrbMrlfL4Z4hVyPpjB9RrrjLXHP9C5t1DVXBBA="; + }; + crywl_unstable = { + rev = "dc1260d3cfd14e8e5b243ec1d3d56e4b08c8c517"; + hash = "sha256-61R+xBYMzeEn93gLofcj8Y3VbJqW6g7GzCTujpAco90="; + }; + in + pkgs.fetchFromGitea ({ + domain = "forge.imbored.dev"; + owner = "emileclarkb"; + repo = pname; + } + // ( + if useUnmodifiedDWL + then dwl_0_70 + else crywl_unstable + )); + + buildInputs = with pkgs; + [ + libinput + xorg.libxcb + libxkbcommon + pixman + wayland + wayland-protocols + wlroots_0_19 + ] + ++ lib.optionals xwaylandEnabled [ + xorg.libX11 + xorg.xcbutilwm + xwayland + ]; + + makeFlags = + [ + "PKG_CONFIG=${pkgs.stdenv.cc.targetPrefix}pkg-config" + "WAYLAND_SCANNER=wayland-scanner" + "PREFIX=$(out)" + "MANDIR=$(man)/share/man" + ] + ++ lib.optionals xwaylandEnabled [ + ''XWAYLAND="-DXWAYLAND"'' + ''XLIBS="xcb xcb-icccm.pc"'' + ]; + + # Ensure `crywl.desktop` entry is registered + passthru = { + providedSessions = [pname]; + + tests.version = pkgs.testers.testVersion { + package = oldAttrs.finalPackage; + # `dwl -v` emits its version string to stderr and returns 1 + command = "crywl -v 2>&1; return 0"; + }; + }; + meta = { + homepage = "https://forge.imbored.dev/emileclarkb/crywl"; + description = "Personal fork of DWL"; + license = lib.licenses.gpl3Only; + maintainers = [lib.maintainers.emileclarkb]; + inherit (pkgs.wayland.meta) platforms; + mainProgram = "crywl"; + }; + }); + }) + ]; + }); +} From f68a8e6d1994e9a606b968dd03c763e2c702439e Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:13:08 +1000 Subject: [PATCH 135/197] add ble.sh option for bash install --- hosts/lolcathost/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 4726f05..b56b3e6 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -226,7 +226,6 @@ in { # Shell bash - zsh fish shellcheck grc # colorise command outputs @@ -329,6 +328,7 @@ in { # cause it isn't POSIX compliant, so instead Bash is my login and # will just exec fish (^-^) bash = { + blesh.enable = false; # ble.sh replacement for GNU readline completion.enable = true; interactiveShellInit = '' From 8db3e2693e1b9c2467b684b803c8289ff2a24af3 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:13:41 +1000 Subject: [PATCH 136/197] ensure Nix builds all documentation pages --- hosts/lolcathost/default.nix | 13 +++++++++++++ hosts/myputer/default.nix | 13 +++++++++++++ 2 files changed, 26 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index b56b3e6..ce8b2bb 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -386,6 +386,19 @@ in { }; }; + documentation = { + enable = true; + doc.enable = true; # install /share/doc packages + man.enable = true; # install manpages + info.enable = true; # install GNU info + dev.enable = true; # install docs intended for developers + nixos = { + enable = true; # install NixOS documentation (ie man -k nix, & nixos-help) + options.splitBuild = true; + # includeAllModules = true; + }; + }; + virtualisation.docker.enable = true; hardware = { diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 1f22c62..5e0aa83 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -405,6 +405,19 @@ in { }; }; + documentation = { + enable = true; + doc.enable = true; # install /share/doc packages + man.enable = true; # install manpages + info.enable = true; # install GNU info + dev.enable = true; # install docs intended for developers + nixos = { + enable = true; # install NixOS documentation (ie man -k nix, & nixos-help) + options.splitBuild = true; + # includeAllModules = true; + }; + }; + virtualisation.docker.enable = true; hardware = { From 0213b82a2f6ce8acc3a9c27fcd3af5cbc5ffc249 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:14:20 +1000 Subject: [PATCH 137/197] enable 32Bit graphics support --- hosts/lolcathost/default.nix | 5 ++++- hosts/myputer/default.nix | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index ce8b2bb..fb4a86f 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -402,7 +402,10 @@ in { virtualisation.docker.enable = true; hardware = { - graphics.enable = true; + graphics = { + enable = true; + enable32Bit = true; + }; # opengl = { # enable = true; diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 5e0aa83..f259889 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -421,7 +421,10 @@ in { virtualisation.docker.enable = true; hardware = { - graphics.enable = true; + graphics = { + enable = true; + enable32Bit = true; + }; # opengl = { # enable = true; From caa5bc0394bbcd15268d2b96bb7386d13a9abe09 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:15:47 +1000 Subject: [PATCH 138/197] add binutils, clang-tools --- hosts/lolcathost/default.nix | 4 +++- hosts/myputer/default.nix | 5 +++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index fb4a86f..5ba7704 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -232,11 +232,13 @@ in { # Systems Emulation qemu # Fellice Bellard's Quick Emulator - # Make + # GNU Utils gnumake + binutils # C Family gcc clang + clang-tools # Rust cargo rustc diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index f259889..404a1c8 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -217,18 +217,19 @@ in { # Shell bash - zsh fish shellcheck grc # colorise command outputs # Systems Emulation qemu # Fellice Bellard's Quick Emulator - # Make + # GNU Utils gnumake + binutils # C Family gcc clang + clang-tools # Rust cargo rustc From db0a34ebbd1d68d2fa31fa7fa4486cf476a7ca38 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 15:19:51 +1000 Subject: [PATCH 139/197] ltrace/strace for lolcathost --- hosts/lolcathost/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index ef23633..1452d6e 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -235,6 +235,8 @@ in { # GNU Utils gnumake binutils + strace + ltrace # C Family gcc clang From 99a0adb621c1b7505c0baaabec4818d2fb8bb2ab Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 23:23:10 +1000 Subject: [PATCH 140/197] add list syscalls script --- scripts/lsyscalls | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100755 scripts/lsyscalls diff --git a/scripts/lsyscalls b/scripts/lsyscalls new file mode 100755 index 0000000..5cbd744 --- /dev/null +++ b/scripts/lsyscalls @@ -0,0 +1,7 @@ +#!/usr/bin/env bash +# USAGE: lsyscalls | sort [-nk2] + +echo -e '#include '\ + | cpp -dM \ + | grep "#define __NR_.*[0-9]$" \ + | cut -d_ -f 4- From 1f35c727ed4fe1e76d5c82d4d923926e74a2dfa1 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 23:25:25 +1000 Subject: [PATCH 141/197] progress home-manager --- hosts/myputer/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 7ca8449..a8f1629 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -7,7 +7,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; - sha256 = "026rvynmzmpigax9f8gy9z67lsl6dhzv2p6s8wz4w06v3gjvspm1"; + sha256 = "1wl2plp37a8qw26h6cj3ah6rq8bd3awl2938h5cm9b8ncxn4s1k8"; }; in { imports = [ From a33e8a0147b4baf1778a000062ed7196eb3a6d1e Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 23:26:08 +1000 Subject: [PATCH 142/197] provide nixpkgs-unstable to homemanager (myputer) --- hosts/myputer/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index a8f1629..316463a 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -1,6 +1,7 @@ { lib, pkgs, + pkgs-unstable, inputs, config, ... @@ -183,6 +184,7 @@ in { home-manager = { users.me = import ../../homes/me; + extraSpecialArgs = {inherit inputs pkgs pkgs-unstable;}; sharedModules = [ inputs.ags.homeManagerModules.default ]; From 95bf9fe6adc2cc3ac85f5e7499087a1df812ddfd Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 23:26:30 +1000 Subject: [PATCH 143/197] add nasm pkg --- hosts/lolcathost/default.nix | 3 +++ hosts/myputer/default.nix | 3 +++ 2 files changed, 6 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 1452d6e..753ab1b 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -234,9 +234,12 @@ in { qemu # Fellice Bellard's Quick Emulator # GNU Utils gnumake + # Binaries binutils strace ltrace + # ASM + nasm # C Family gcc clang diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 316463a..528c87d 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -235,9 +235,12 @@ in { qemu # Fellice Bellard's Quick Emulator # GNU Utils gnumake + # Binaries binutils strace ltrace + # ASM + nasm # C Family gcc clang From eb02262ae67189936485a7310bc0f821e353cb3f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sun, 31 Aug 2025 23:27:08 +1000 Subject: [PATCH 144/197] add x86-manpages derivation (ISA manpages) --- hosts/lolcathost/default.nix | 1 + hosts/myputer/default.nix | 1 + hosts/packages/x86-manpages/default.nix | 32 +++++++++++++++++++++++++ 3 files changed, 34 insertions(+) create mode 100644 hosts/packages/x86-manpages/default.nix diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 753ab1b..be4c996 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -240,6 +240,7 @@ in { ltrace # ASM nasm + (callPackage ../packages/x86-manpages {}) # C Family gcc clang diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 528c87d..b0c8f6c 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -241,6 +241,7 @@ in { ltrace # ASM nasm + (callPackage ../packages/x86-manpages {}) # C Family gcc clang diff --git a/hosts/packages/x86-manpages/default.nix b/hosts/packages/x86-manpages/default.nix new file mode 100644 index 0000000..b687422 --- /dev/null +++ b/hosts/packages/x86-manpages/default.nix @@ -0,0 +1,32 @@ +{pkgs, ...}: +pkgs.stdenv.mkDerivation { + pname = "x86-manpages"; + version = "0.0.1"; + + src = pkgs.fetchFromGitHub { + owner = "ttmo-O"; + repo = "x86-manpages"; + + ## Recommended + # rev = "0e199a8b4d90be7eb715291c21cf41de8527beac"; + # sha256 = "0im596j0pf90npg933gkq6wpw23c47fcwv0n64qfqn5mcy92qbcb"; + rev = "94902f9c45de0efe803c32b6c3e88d6623881866"; + sha256 = "0k6nsfabzqwnhjiyw2kyg0z49nzrsxn515f6dcjh1rn7bzih5562"; + }; + + installPhase = '' + mkdir -p $out/man/man7 + + shopt -u nullglob + for m in man7/*.7; do + install -m 644 "$m" "$out/man/man7" + done + ''; + + meta = with pkgs.lib; { + description = "Manpages for x86 instructions"; + homepage = "https://github.com/ttmo-O/x86-manpages"; + license = licenses.mit; + platforms = platforms.all; + }; +} From 364efb25ead548c72746508070e5d4f5d520baf1 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 3 Sep 2025 00:24:41 +1000 Subject: [PATCH 145/197] dbus sucks i wanna cry :( --- hosts/lolcathost/default.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index be4c996..2450c55 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -121,11 +121,11 @@ in { ); }; - dbus = { - # NOTE: programs.uwsm.enable sets implementation to dbus-broker, - # NOTE: however this seems to break dbus - implementation = lib.mkForce "dbus"; - }; + # dbus = { + # # NOTE: programs.uwsm.enable sets implementation to dbus-broker, + # # NOTE: however this seems to break dbus + # implementation = lib.mkForce "dbus"; + # }; # Multimedia Framework # With backwards compatability for alsa/pulseaudio/jack From 6fbaf7fe893a53e277ebaa70dfdf43e8da687ce7 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 3 Sep 2025 00:37:55 +1000 Subject: [PATCH 146/197] add haskell support --- homes/modules/editor/helix.nix | 10 ++++++++++ hosts/lolcathost/default.nix | 3 +++ hosts/myputer/default.nix | 3 +++ 3 files changed, 16 insertions(+) diff --git a/homes/modules/editor/helix.nix b/homes/modules/editor/helix.nix index e7d6003..3c1443d 100755 --- a/homes/modules/editor/helix.nix +++ b/homes/modules/editor/helix.nix @@ -136,6 +136,12 @@ formatter.command = "${pkgs.clang-tools}/bin/clang-format"; language-servers = ["clangd"]; } + { + name = "haskell"; + auto-format = true; + formatter.command = "${pkgs.ormolu}/bin/ormolu"; + language-servers = ["haskell-language-server"]; + } ]; language-server = { @@ -149,6 +155,10 @@ clangd = { command = "${pkgs.clang-tools}/bin/clangd"; }; + + haskell-language-server = { + command = "${pkgs.haskell-language-server}/bin/haskell-language-server-wrapper"; + }; }; }; }; diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 2450c55..765118b 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -253,6 +253,9 @@ in { nimble # Go go + # Haskell + ghc + ghcid # Python python312 # I use 3.12 since it's in a pretty stable state now diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index b0c8f6c..dc525f9 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -254,6 +254,9 @@ in { nimble # Go go + # Haskell + ghc + ghcid # Python python312 # I use 3.12 since it's in a pretty stable state now From a35cedeecbaa5f12f99a4ed6d77225897aaa1378 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 3 Sep 2025 03:24:39 +1000 Subject: [PATCH 147/197] add haskell lsp + formatter --- hosts/lolcathost/default.nix | 2 ++ hosts/myputer/default.nix | 2 ++ 2 files changed, 4 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 765118b..12125e5 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -256,6 +256,8 @@ in { # Haskell ghc ghcid + haskell-language-server + ormolu # Python python312 # I use 3.12 since it's in a pretty stable state now diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index dc525f9..ea5710a 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -257,6 +257,8 @@ in { # Haskell ghc ghcid + haskell-language-server + ormolu # Python python312 # I use 3.12 since it's in a pretty stable state now From eaea98a362a2f2d54e6ce6c22a4afb4c99286370 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 3 Sep 2025 03:27:12 +1000 Subject: [PATCH 148/197] add hyprsunset (its 3am and im going blind............) --- hosts/modules/wm/hyprland.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/hosts/modules/wm/hyprland.nix b/hosts/modules/wm/hyprland.nix index f2960ed..c83caa1 100644 --- a/hosts/modules/wm/hyprland.nix +++ b/hosts/modules/wm/hyprland.nix @@ -1,4 +1,8 @@ -{...}: { +{pkgs, ...}: { + environment.defaultPackages = with pkgs; [ + hyprsunset + ]; + programs = { hyprland = { enable = true; From c94e75bb0210cd61e40186d2a9ad19c5f923a50d Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 3 Sep 2025 11:13:13 +1000 Subject: [PATCH 149/197] mark all dev outputs for install --- hosts/lolcathost/default.nix | 15 ++++++++++----- hosts/myputer/default.nix | 15 ++++++++++----- 2 files changed, 20 insertions(+), 10 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 12125e5..02bd30f 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -198,12 +198,17 @@ in { }; # ---- ENVIRONMENT VARIABLES ---- - environment.sessionVariables = { - # folder names with capitalisation look awful! - XDG_DOWNLOAD_DIR = "$HOME/downloads"; + environment = { + # always install "dev" derivation outputs + extraOutputsToInstall = ["dev"]; - # Hint Electrons apps to use Wayland - NIXOS_OZONE_WL = "1"; + sessionVariables = { + # folder names with capitalisation look awful! + XDG_DOWNLOAD_DIR = "$HOME/downloads"; + + # Hint Electrons apps to use Wayland + NIXOS_OZONE_WL = "1"; + }; }; # ---- SYSTEM PACKAGES ----- diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index ea5710a..ce1c838 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -191,12 +191,17 @@ in { }; # ---- ENVIRONMENT VARIABLES ---- - environment.sessionVariables = { - # folder names with capitalisation look awful! - XDG_DOWNLOAD_DIR = "$HOME/downloads"; + environment = { + # always install "dev" derivation outputs + extraOutputsToInstall = ["dev"]; - # Hint Electrons apps to use Wayland - NIXOS_OZONE_WL = "1"; + sessionVariables = { + # folder names with capitalisation look awful! + XDG_DOWNLOAD_DIR = "$HOME/downloads"; + + # Hint Electrons apps to use Wayland + NIXOS_OZONE_WL = "1"; + }; }; # ---- SYSTEM PACKAGES ----- From 75751e308505c5d7330fd410879b784dca356a60 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Thu, 18 Sep 2025 19:48:07 +1000 Subject: [PATCH 150/197] always install derivation "man" ouputs --- hosts/lolcathost/default.nix | 2 +- hosts/myputer/default.nix | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 02bd30f..b154d3c 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -200,7 +200,7 @@ in { # ---- ENVIRONMENT VARIABLES ---- environment = { # always install "dev" derivation outputs - extraOutputsToInstall = ["dev"]; + extraOutputsToInstall = ["dev" "man"]; sessionVariables = { # folder names with capitalisation look awful! diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index ce1c838..16df2cf 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -193,7 +193,7 @@ in { # ---- ENVIRONMENT VARIABLES ---- environment = { # always install "dev" derivation outputs - extraOutputsToInstall = ["dev"]; + extraOutputsToInstall = ["dev" "man"]; sessionVariables = { # folder names with capitalisation look awful! From cb6f98406565b7f6331ce329e5d0e6b1c450b17a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 24 Sep 2025 13:30:20 +1000 Subject: [PATCH 151/197] add pkgs.moreutils --- hosts/lolcathost/default.nix | 1 + hosts/myputer/default.nix | 1 + 2 files changed, 2 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index b154d3c..e0bfcb1 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -234,6 +234,7 @@ in { fish shellcheck grc # colorise command outputs + moreutils # Systems Emulation qemu # Fellice Bellard's Quick Emulator diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 16df2cf..2749192 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -235,6 +235,7 @@ in { fish shellcheck grc # colorise command outputs + moreutils # Systems Programming & Compilation qemu # Fellice Bellard's Quick Emulator From 81c7c25c6f90cf9d43d91d2230edb775e4edc4f7 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 26 Sep 2025 23:18:45 +1000 Subject: [PATCH 152/197] add hexyl, timg, and other --- hosts/lolcathost/default.nix | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index e0bfcb1..54efd89 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -244,6 +244,7 @@ in { binutils strace ltrace + hexyl # ASM nasm (callPackage ../packages/x86-manpages {}) @@ -265,6 +266,14 @@ in { haskell-language-server ormolu + # Nix + # TODO: once upgraded past Nix-24.07 this line won't be necessary (I think) + # helix will support nixd by default + # SOURCE: https://github.com/nix-community/nixd/blob/main/nixd/docs/editor-setup.md#Helix + nixd # lsp for nix + nix-prefetch-git + nix-index + # Python python312 # I use 3.12 since it's in a pretty stable state now python314 # also 3.14 for latest features @@ -288,23 +297,18 @@ in { zoxide doggo tldr - # btop + btop eza yazi lazygit ripgrep viddy # modern `watch` command thefuck - - # TODO: once upgraded past Nix-24.07 this line won't be necessary (I think) - # helix will support nixd by default - # SOURCE: https://github.com/nix-community/nixd/blob/main/nixd/docs/editor-setup.md#Helix - nixd # lsp for nix + timg # terminal image (sixel) viewer # Pretty necessary git git-filter-repo - nix-prefetch-git brightnessctl acpi # upower From bf22bfbcf48a0a1c5ee8b1f1b3f02bbd9e7a1865 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:18:26 +1000 Subject: [PATCH 153/197] enable NIX_SHELL_PRESERVE_PROMPT --- homes/me/default.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/homes/me/default.nix b/homes/me/default.nix index fac7454..194d568 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -35,6 +35,10 @@ man = "batman"; # bat + man }; + sessionVariables = { + NIX_SHELL_PRESERVE_PROMPT = 1; + }; + pointerCursor = { gtk.enable = true; # x11.enable = true # dont enable since im on hyprland From f9df463872f4dd0d811d7d157485393f4e21fdf2 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:20:37 +1000 Subject: [PATCH 154/197] add dotnet9 --- hosts/lolcathost/default.nix | 5 +++++ hosts/myputer/default.nix | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 54efd89..86ef3d5 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -281,6 +281,11 @@ in { # Sage sageWithDoc # SageMath + HTML Documentation + # .NET + dotnetCorePackages.dotnet_9.sdk + dotnetCorePackages.dotnet_9.aspnetcore + dotnetCorePackages.dotnet_9.runtime + openvpn inetutils diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 2749192..d51934f 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -273,6 +273,11 @@ in { # Sage sageWithDoc # SageMath + HTML Documentation + # .NET + dotnetCorePackages.dotnet_9.sdk + dotnetCorePackages.dotnet_9.aspnetcore + dotnetCorePackages.dotnet_9.runtime + openvpn inetutils From 3e1d10617908897f4af7be482f927025fc160d9f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:21:56 +1000 Subject: [PATCH 155/197] add pstree + lz4 --- hosts/lolcathost/default.nix | 2 ++ hosts/myputer/default.nix | 2 ++ 2 files changed, 4 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 86ef3d5..be8db92 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -325,8 +325,10 @@ in { file wget tree + pstree unzip unrar-free + lz4 man-pages man-pages-posix diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index d51934f..d424817 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -323,8 +323,10 @@ in { file wget tree + pstree unzip unrar-free + lz4 man-pages man-pages-posix From 120b753882a49ba484e587e91a18a858a90cd452 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:24:16 +1000 Subject: [PATCH 156/197] (attempt) fix dbus service for bluetui manually configure resolvd with CloudFlare's WARP+ DNS --- hosts/lolcathost/default.nix | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index be8db92..376140e 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -100,10 +100,30 @@ in { networkmanager.enable = true; firewall.enable = false; + + # Use CloudFlare's WARP+ 1.1.1.1 DNS service + nameservers = [ + "1.1.1.1#one.one.one.one" + "1.0.0.1#one.one.one.one" + ]; }; # ----- SERVICES ----- services = { + # systemd-resolved provides network name resolution + # to local processes via a D-Bus interface. + resolved = { + enable = true; + dnssec = "true"; + domains = ["~."]; + # Use CloudFlare's WARP+ 1.1.1.1 DNS service + fallbackDns = [ + "1.1.1.1#one.one.one.one" + "1.0.0.1#one.one.one.one" + ]; + dnsovertls = "true"; + }; + # Set display manager (login screen) displayManager = { # sddm relies on pkgs.libsForQt5.qt5.qtgraphicaleffects From 70ed4a9a38ddef2c8b6378a7457d54af2281368c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:30:18 +1000 Subject: [PATCH 157/197] add hosts/modules/bashistrans.nix --- hosts/lolcathost/default.nix | 18 ++---------------- hosts/modules/bashistrans.nix | 23 +++++++++++++++++++++++ hosts/myputer/default.nix | 2 ++ 3 files changed, 27 insertions(+), 16 deletions(-) create mode 100644 hosts/modules/bashistrans.nix diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 376140e..dbdaba0 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -15,6 +15,8 @@ in { ./hardware-configuration.nix (import "${home-manager}/nixos") + ../modules/bashistrans.nix + ../modules/wm/hyprland.nix # ../modules/wm/river.nix ../modules/wm/crywl.nix @@ -375,22 +377,6 @@ in { nix-ld.enable = true; - # I want to use fish as my login shell but it always goes terrible - # cause it isn't POSIX compliant, so instead Bash is my login and - # will just exec fish (^-^) - bash = { - blesh.enable = false; # ble.sh replacement for GNU readline - completion.enable = true; - - interactiveShellInit = '' - if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]] - then - shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION="" - exec ${pkgs.fish}/bin/fish $LOGIN_OPTION - fi - ''; - }; - # Thunar also uses: `services.tumbler` & `services.gvfs` thunar = { enable = true; diff --git a/hosts/modules/bashistrans.nix b/hosts/modules/bashistrans.nix new file mode 100644 index 0000000..d3b285c --- /dev/null +++ b/hosts/modules/bashistrans.nix @@ -0,0 +1,23 @@ +{pkgs, ...}: { + # I want to use fish as my login shell but it always goes terrible + # cause it isn't POSIX compliant, so instead Bash is my login and + # will just exec fish (^-^) + programs.bash = { + blesh.enable = false; # ble.sh replacement for GNU readline + completion.enable = true; + + interactiveShellInit = '' + # help bash transition into a beautiful fish! + if [[ -z $CRY_BASH_IS_TRANS ]] + then + if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]] + then + shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION="" + exec ${pkgs.fish}/bin/fish $LOGIN_OPTION + fi + fi + # bash is trans now! (no more transitioning required) + export CRY_BASH_IS_TRANS=true + ''; + }; +} diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index d424817..6844dcc 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -15,6 +15,8 @@ in { ./hardware-configuration.nix (import "${home-manager}/nixos") + ../modules/bashistrans.nix + ../modules/wm/hyprland.nix ../modules/steam.nix From 5c955e52322b331420371c85023a5136963c451a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:40:21 +1000 Subject: [PATCH 158/197] (attempt) package CrazyCraft void launcher for my partner lol --- hosts/myputer/default.nix | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 6844dcc..b43fa6c 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -30,6 +30,13 @@ in { "nix-command" "flakes" ]; + # nixpkgs.overlays = [ + # (self: super: { + # jdk17 = super.jdk17.override (prev: { + # enableJavaFX = true; + # }); + # }) + # ]; nixpkgs.config.allowUnfreePredicate = let whitelist = map lib.getName [ @@ -268,6 +275,18 @@ in { haskell-language-server ormolu + # Java + # jdk17 + # (jre8.overrideAttrs + # (oldAttrs: { + # enableJavaFX = true; + # })) + # (jdk8.overrideAttrs + # (oldAttrs: { + # enableJavaFX = true; + # })) + visualvm + # Python python312 # I use 3.12 since it's in a pretty stable state now python314 # also 3.14 for latest features @@ -404,6 +423,18 @@ in { # mozilla's email client thunderbird.enable = true; + + java = let + # XXX: WARNING: TEST :WARNING: XXX + # Test for CrazyCraft VoidLauncher + myjdk = pkgs.jdk17.override { + enableJavaFX = true; + # openjfx_jdk = pkgs.openjfx17.override {withWebKit = true;}; + }; + in { + enable = true; + package = myjdk; + }; }; # ----- FONTS ----- From c05db6797455b031c9bc6e8eb2a17f1d7fbf72e4 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:40:54 +1000 Subject: [PATCH 159/197] progress hyrule home-manager --- hosts/hyrule/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index 6ac57a5..e0da1d6 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -7,7 +7,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; - sha256 = "026rvynmzmpigax9f8gy9z67lsl6dhzv2p6s8wz4w06v3gjvspm1"; + sha256 = "0d41gr0c89a4y4lllzdgmbm54h9kn9fjnmavwpgw0w9xwqwnzpax"; }; in { imports = [ From a04641fc9dc6c05fe1132a2cbeae4e03f02b4eb3 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:41:20 +1000 Subject: [PATCH 160/197] (temp) disable hyrule's minecraft server --- hosts/hyrule/default.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hosts/hyrule/default.nix b/hosts/hyrule/default.nix index e0da1d6..325e467 100755 --- a/hosts/hyrule/default.nix +++ b/hosts/hyrule/default.nix @@ -14,8 +14,9 @@ in { ./hardware-configuration.nix (import "${home-manager}/nixos") - ./mailserver.nix # TEMP: location - ./minecraft-server.nix # TEMP: location + # ./mailserver.nix # TEMP: location + # ./minecraft-server.nix # TEMP: location + #../modules/server/nginx.nix #../modules/server/ssh.nix #../modules/server/fail2ban.nix From 2da00759924a82edbcaaaaa8e09cf8db57ab9da2 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:43:26 +1000 Subject: [PATCH 161/197] add radare2, gdb, perf-tools --- hosts/lolcathost/default.nix | 8 ++++++-- hosts/myputer/default.nix | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index dbdaba0..9075286 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -266,6 +266,9 @@ in { binutils strace ltrace + perf-tools # ftrace + perf + radare2 + gdb hexyl # ASM nasm @@ -273,15 +276,16 @@ in { # C Family gcc clang + clang-tools # Rust cargo rustc + # Go + go # Nim nim nimble - # Go - go # Haskell ghc ghcid diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index b43fa6c..ef640c7 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -254,6 +254,9 @@ in { binutils strace ltrace + perf-tools # ftrace + perf + radare2 + gdb # ASM nasm (callPackage ../packages/x86-manpages {}) @@ -261,14 +264,15 @@ in { gcc clang clang-tools + # Rust cargo rustc + # Go + go # Nim nim nimble - # Go - go # Haskell ghc ghcid From 2dde0450c410e2ca1a6101b8ecce1480a8043df4 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 09:43:40 +1000 Subject: [PATCH 162/197] add discord --- hosts/myputer/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index ef640c7..af9b257 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -46,6 +46,7 @@ in { pkgs.steamcmd pkgs.steam-unwrapped pkgs.dwarf-fortress + pkgs.discord ]; in pkg: builtins.elem (lib.getName pkg) whitelist; From d094fbb26fed01902193574491afbdc14a39244f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 21:19:26 +1000 Subject: [PATCH 163/197] helix now supports C# LSP --- homes/modules/editor/helix.nix | 21 +++++++++++++++++++++ hosts/myputer/default.nix | 1 + 2 files changed, 22 insertions(+) diff --git a/homes/modules/editor/helix.nix b/homes/modules/editor/helix.nix index 3c1443d..8d6e22c 100755 --- a/homes/modules/editor/helix.nix +++ b/homes/modules/editor/helix.nix @@ -142,6 +142,22 @@ formatter.command = "${pkgs.ormolu}/bin/ormolu"; language-servers = ["haskell-language-server"]; } + # { + # name = "c-sharp"; + # source = "source.cs"; + # file-types = ["cs"]; + # indent = { + # tab-width = 4; + # unit = " "; + # }; + # block-comment-tokens = { + # start = "/*"; + # end = "*/"; + # }; + # # auto-format = false; + # # formatter.command = "${pkgs.omnisharp-roslyn}/bin/OmniSharp"; + # # language-servers = ["OmniSharp"]; + # } ]; language-server = { @@ -159,6 +175,11 @@ haskell-language-server = { command = "${pkgs.haskell-language-server}/bin/haskell-language-server-wrapper"; }; + + # C# language services + OmniSharp = { + command = "${pkgs.omnisharp-roslyn}/bin/OmniSharp"; + }; }; }; }; diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index af9b257..5a866c2 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -303,6 +303,7 @@ in { dotnetCorePackages.dotnet_9.sdk dotnetCorePackages.dotnet_9.aspnetcore dotnetCorePackages.dotnet_9.runtime + omnisharp-roslyn openvpn inetutils From 8ec227aa10fc739f61a3b85c4ba0b9a03e691f23 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 21:19:37 +1000 Subject: [PATCH 164/197] add cute lil banner --- banner | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 banner diff --git a/banner b/banner new file mode 100644 index 0000000..67e1bd9 --- /dev/null +++ b/banner @@ -0,0 +1,6 @@ + .------------. + | oh my | + '------------' + ^ (\_(\ + '----- ( -.-) + o_(")(") From 328c628291d010eddebc3ff2def75ed1aaa6bc71 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 21:19:53 +1000 Subject: [PATCH 165/197] (temp) add notes on screensharing --- SCREENSHARING | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 SCREENSHARING diff --git a/SCREENSHARING b/SCREENSHARING new file mode 100644 index 0000000..d3046f6 --- /dev/null +++ b/SCREENSHARING @@ -0,0 +1,11 @@ +Excellent Resource +https://gist.github.com/brunoanc/2dea6ddf6974ba4e5d26c3139ffb7580#install-xdg-desktop-portal-and-friends + +Hyprland official page on screensharing +https://wiki.hyprland.org/Useful-Utilities/Screen-Sharing/ + + +Multiple sources seem to think that use xdg-desktop-portal-wlr works (but I can't stream individual applications) +but I suppose that's better than nothing? + +Also check out xwaylandvideobridge From 4e615703a66fa03770e9afd837fd0a2d586d2651 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Mon, 6 Oct 2025 21:21:28 +1000 Subject: [PATCH 166/197] i dont need this anymore --- flake.nix | 5 ----- 1 file changed, 5 deletions(-) diff --git a/flake.nix b/flake.nix index 382bca6..3d40a53 100644 --- a/flake.nix +++ b/flake.nix @@ -5,11 +5,6 @@ nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05"; nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable"; - #home-manager = { - # url = "github:nix-community/home-manager"; - # inputs.nixpkgs.follows = "nixpkgs"; - #}; - grub2-themes.url = "github:vinceliuice/grub2-themes"; ags.url = "github:Aylur/ags"; From d26b8af26f622bc48e74c57612491f619dd8f642 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Tue, 7 Oct 2025 12:49:56 +1000 Subject: [PATCH 167/197] add work conditional .gitconfig --- homes/modules/git.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/homes/modules/git.nix b/homes/modules/git.nix index 82d0f1e..c2578a8 100755 --- a/homes/modules/git.nix +++ b/homes/modules/git.nix @@ -35,5 +35,12 @@ }; }; }; + + includes = [ + { + path = "/home/me/agribit/.gitconfig"; + condition = "gitdir:/home/me/agribit/"; + } + ]; }; } From c46d9665a180447bfb62fc89149129465ca2854c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 8 Oct 2025 10:39:41 +1000 Subject: [PATCH 168/197] fix conditional .gitconfig --- homes/modules/git.nix | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/homes/modules/git.nix b/homes/modules/git.nix index c2578a8..fdf6afb 100755 --- a/homes/modules/git.nix +++ b/homes/modules/git.nix @@ -33,13 +33,19 @@ "github:" ]; }; + "https://gitlab.com/" = { + insteadOf = [ + "gl:" + "gitlab:" + ]; + }; }; }; includes = [ { path = "/home/me/agribit/.gitconfig"; - condition = "gitdir:/home/me/agribit/"; + condition = "gitdir:/home/me/agribit/**"; } ]; }; From 78c75ea740abd19744adb5967105d742aaaa879a Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 8 Oct 2025 10:59:14 +1000 Subject: [PATCH 169/197] add NetCoreDbg for helix --- hosts/myputer/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 5a866c2..50d3bf6 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -8,7 +8,7 @@ }: let home-manager = builtins.fetchTarball { url = "https://github.com/nix-community/home-manager/archive/release-25.05.tar.gz"; - sha256 = "1wl2plp37a8qw26h6cj3ah6rq8bd3awl2938h5cm9b8ncxn4s1k8"; + sha256 = "0q3lv288xlzxczh6lc5lcw0zj9qskvjw3pzsrgvdh8rl8ibyq75s"; }; in { imports = [ @@ -304,6 +304,7 @@ in { dotnetCorePackages.dotnet_9.aspnetcore dotnetCorePackages.dotnet_9.runtime omnisharp-roslyn + netcoredbg openvpn inetutils From f51ac822e0eb26112c7b137b081182969ff7038f Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Wed, 8 Oct 2025 11:15:21 +1000 Subject: [PATCH 170/197] enable vscodium --- homes/me/default.nix | 4 +--- homes/modules/editor/vscodium.nix | 12 ++++++++++-- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/homes/me/default.nix b/homes/me/default.nix index 194d568..86b4c0b 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -12,12 +12,10 @@ ../modules/bat.nix ../modules/fish.nix ../modules/editor/helix.nix - # ../modules/editor/vscodium.nix + ../modules/editor/vscodium.nix ../modules/btop.nix - ../modules/term/ghostty.nix ../modules/term/foot.nix - # ../modules/term/rio.nix ../modules/firefox.nix #../modules/wm/hypr/hypridle.nix diff --git a/homes/modules/editor/vscodium.nix b/homes/modules/editor/vscodium.nix index c5daf64..5309bf7 100644 --- a/homes/modules/editor/vscodium.nix +++ b/homes/modules/editor/vscodium.nix @@ -1,9 +1,17 @@ {pkgs, ...}: { + # REF: https://home-manager-options.extranix.com/?query=vscode&release=release-25.05 programs.vscode = { enable = true; package = pkgs.vscodium; - extensions = with pkgs.vscode-extensions; [ - ]; + mutableExtensionsDir = true; + + profiles.default = { + enableUpdateCheck = false; + enableExtensionUpdateCheck = false; + extensions = with pkgs.vscode-extensions; [ + dracula-theme.theme-dracula + ]; + }; }; } From a29c66e35d5a52a57682080b4a2747cf557a0554 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:44:02 +1000 Subject: [PATCH 171/197] add mako notification daemon --- config.temp/hyprland.conf | 1 + homes/me/default.nix | 1 + homes/modules/mako.nix | 54 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 56 insertions(+) create mode 100644 homes/modules/mako.nix diff --git a/config.temp/hyprland.conf b/config.temp/hyprland.conf index 864b184..7243478 100755 --- a/config.temp/hyprland.conf +++ b/config.temp/hyprland.conf @@ -40,6 +40,7 @@ $colorpicker = hyprpicker | head -c 7 | wl-copy # exec-once = nm-applet & # exec-once = waybar & hyprpaper & firefox exec-once = swww-daemon & +exec-once = mako & # TODO: or do I do `swww init` or `swww restore`? # █▀▀ █▄░█ █░█   █░█ ▄▀█ █▀█ diff --git a/homes/me/default.nix b/homes/me/default.nix index 86b4c0b..46b2de6 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -22,6 +22,7 @@ ../modules/wm/hypr/hyprlock.nix ../modules/kanshi.nix ../modules/ags + ../modules/mako.nix ]; home = { diff --git a/homes/modules/mako.nix b/homes/modules/mako.nix new file mode 100644 index 0000000..762cd96 --- /dev/null +++ b/homes/modules/mako.nix @@ -0,0 +1,54 @@ +{...}: let + dracula = rec { + background = "#282A36"; + border = cyan; + + cyan = "#8BE9FD"; + yellow = "#F1FA8C"; + red = "#FF5555"; + }; + + theme = dracula; +in { + # notification daemon for Wayland + services.mako = { + enable = true; + settings = { + actions = true; + anchor = "top-right"; + layer = "overlay"; + sort = "-time"; + + height = 100; + width = 300; + margin = 50; + background-color = theme.background; + border-color = theme.border; + border-radius = 20; + border-size = 4; + font = "monospace 10"; + + markup = true; + icons = true; + max-icon-size = 64; + + default-timeout = 5000; + ignore-timeout = false; + + "actionable=true" = { + anchor = "top-left"; + }; + + "urgency=low" = { + border-color = theme.border; + }; + "urgency=normal" = { + border-color = theme.yellow; + }; + "urgency=high" = { + default-timeout = 0; + border-color = theme.red; + }; + }; + }; +} From 8e2aad53be8b8bd11f601993a5795ca859c22a10 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:45:00 +1000 Subject: [PATCH 172/197] customise vscodium --- homes/modules/editor/vscodium.nix | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/homes/modules/editor/vscodium.nix b/homes/modules/editor/vscodium.nix index 5309bf7..ecde271 100644 --- a/homes/modules/editor/vscodium.nix +++ b/homes/modules/editor/vscodium.nix @@ -1,4 +1,8 @@ -{pkgs, ...}: { +{ + lib, + pkgs, + ... +}: { # REF: https://home-manager-options.extranix.com/?query=vscode&release=release-25.05 programs.vscode = { enable = true; @@ -9,9 +13,25 @@ profiles.default = { enableUpdateCheck = false; enableExtensionUpdateCheck = false; + # extension format: USER.PACKAGENAME extensions = with pkgs.vscode-extensions; [ + # .NET + ms-dotnettools.csharp + ms-dotnettools.csdevkit + ms-dotnettools.vscode-dotnet-runtime + # ms-dotnettools.vscode-dotnet-pack + # ms-dotnettools.dotnet-maui + + # Colors & Themes dracula-theme.theme-dracula + catppuccin.catppuccin-vsc + catppuccin.catppuccin-vsc-icons + mvllow.rose-pine ]; + + userSettings = { + "workbench.colorTheme" = "Dracula Theme"; + }; }; }; } From 1600fd2885695126d64aac7bb166ac83eeb34599 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:46:08 +1000 Subject: [PATCH 173/197] fix bashistrans (myputer) --- hosts/myputer/default.nix | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 50d3bf6..244f5eb 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -403,21 +403,6 @@ in { }; }; - # I want to use fish as my login shell but it always goes terrible - # cause it isn't POSIX compliant, so instead Bash is my login and - # will just exec fish (^-^) - bash = { - completion.enable = true; - - interactiveShellInit = '' - if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]] - then - shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION="" - exec ${pkgs.fish}/bin/fish $LOGIN_OPTION - fi - ''; - }; - # Thunar also (optionally) requires: `services.tumbler` & `services.gvfs` thunar = { enable = true; From 1d54b413477480c64ff7e980a6cf4f202dcf50f8 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:47:20 +1000 Subject: [PATCH 174/197] replace vscodium -> vscode --- homes/me/default.nix | 9 ++- homes/modules/editor/vscode.nix | 134 ++++++++++++++++++++++++++++++++ 2 files changed, 141 insertions(+), 2 deletions(-) create mode 100644 homes/modules/editor/vscode.nix diff --git a/homes/me/default.nix b/homes/me/default.nix index 46b2de6..ac87870 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -6,13 +6,13 @@ pkgs, pkgs-unstable, ... -}: { +} @ args: { imports = [ ../modules/git.nix ../modules/bat.nix ../modules/fish.nix ../modules/editor/helix.nix - ../modules/editor/vscodium.nix + (import ../modules/editor/vscode.nix args) ../modules/btop.nix ../modules/term/foot.nix @@ -25,6 +25,11 @@ ../modules/mako.nix ]; + nixpkgs.config.allowUnfreePredicate = pkg: + builtins.elem (lib.GetName pkg) [ + "vscode-extension-ms-dotnettools-csharp" + ]; + home = { username = "me"; homeDirectory = "/home/me"; diff --git a/homes/modules/editor/vscode.nix b/homes/modules/editor/vscode.nix new file mode 100644 index 0000000..f824b1c --- /dev/null +++ b/homes/modules/editor/vscode.nix @@ -0,0 +1,134 @@ +{ + config, + lib, + pkgs, + vscodium ? false, + secret-service ? "gnome-libsecret", + vscode-argv ? ".vscode/argv.json", + ... +}: { + nixpkgs.overlays = [ + ( + self: super: { + vscode-extensions = super.vscode-extensions.overrideAttrs (prev: let + mkVscMarketplaceExtension = { + publisher, + name, + version, + hash, + description ? "", + homepage ? null, + changelog ? null, + license ? null, + maintainers ? [lib.maintainers.emileclarkb], + }: + with pkgs.vscode-utils.buildVscodeMarketplaceExtension; { + ${publisher}.${name} = buildVscodeMarketplaceExtension { + mktplcRef = { + inherit + publisher + name + version + hash + ; + }; + + meta = { + inherit + ( + if license != null + then {license = license;} + else {} + ) + description + homepage + maintainers + ; + downloadPage = "https://marketplace.visualstudio.com/items?itemName=${publisher}.${name}"; + changelog = + if changelog != null + then changelog + else "https://marketplace.visualstudio.com/items/${publisher}.${name}/changelog"; + }; + }; + }; + in + lib.mergeAttrsList [ + (mkVscMarketplaceExtension { + publisher = "ms-dotnettools"; + name = "dotnet-maui"; + version = "1.11.14"; + hash = lib.fakeHash; + + description = "Extend C# Dev Kit with tools for building .NET Multi-platform App UI (MAUI) apps"; + homepage = "https://github.com/microsoft/vscode-dotnettools"; + license = lib.licenses.unfree; + }) + ]); + } + ) + ]; + + # REF: https://home-manager-options.extranix.com/?query=vscode&release=release-25.05 + programs.vscode = { + enable = true; + # TODO: clean up + package = + ( + if vscodium + then pkgs.vscodium + else pkgs.vscode + ).overrideAttrs (oldAttrs: { + # runtimeDependencies = oldAttrs.runtimeDependencies ++ [] + }); + + mutableExtensionsDir = true; + + profiles.default = { + enableUpdateCheck = false; + enableExtensionUpdateCheck = false; + # extension format: USER.PACKAGENAME + extensions = with pkgs.vscode-extensions; [ + # .NET + ms-dotnettools.csharp + ms-dotnettools.csdevkit + ms-dotnettools.vscode-dotnet-runtime + # TODO: these extensions aren't packaged :( + # deitry.solution-syntax + # ms-dotnettools.vscode-dotnet-pack + # ms-dotnettools.dotnet-maui + + # Python + ms-python.python + + # GitLens by GitKraken + eamodio.gitlens + ms-azuretools.vscode-docker + + github.copilot + github.copilot-chat + + # Colors & Themes + dracula-theme.theme-dracula + catppuccin.catppuccin-vsc + catppuccin.catppuccin-vsc-icons + mvllow.rose-pine + ]; + + userSettings = { + "workbench.colorTheme" = "Dracula Theme"; + "github.copilot.nextEditSuggestions.enabled" = true; + }; + }; + }; + + # TODO: this is super ugly, make sure the JSON is formatted!! + home.file.${vscode-argv}.text = builtins.toJSON { + password-store = secret-service; + + disable-hardware-acceleration = false; + disable-color-correct-rendering = false; + enable-crash-reporter = false; + # crash-report-id = ...; + }; +} From ce3eb7a6d80546318e052b27c8cdb5890a25639c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:47:58 +1000 Subject: [PATCH 175/197] vscode requires an OS keyring daemon --- homes/me/default.nix | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/homes/me/default.nix b/homes/me/default.nix index ac87870..d37a8e9 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -50,6 +50,12 @@ name = "Bibata-Modern-Ice"; size = 16; }; + + packages = with pkgs; [ + # for services.gnome-keyring + pkgs.gcr # provides org.gnome.keyring.SystemPrompter + seahorse # gui + ]; }; gtk = { @@ -144,8 +150,12 @@ }; }; - # enable OpenSSH private key agent - services.ssh-agent.enable = true; + services = { + # enable OpenSSH private key agent + ssh-agent.enable = true; + + gnome-keyring.enable = true; + }; # the ssh-agent won't set this for itself... systemd.user.sessionVariables.SSH_AUTH_SOCK = "$XDG_RUNTIME_DIR/ssh-agent"; # Nicely reload system units when changing configs From 63c1f112d4b27287be3af8088d83a1be9f699657 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:48:49 +1000 Subject: [PATCH 176/197] (temp) hide chameleonultra+flipperzero to improve build time --- hosts/myputer/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 244f5eb..72b1e7d 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -22,8 +22,8 @@ in { ../modules/steam.nix ../modules/obsidian.nix - ../modules/flipperzero.nix - ../modules/chameleonultragui.nix + #../modules/flipperzero.nix + #../modules/chameleonultragui.nix ]; nix.settings.experimental-features = [ From 1ee0ba1a4ca55b0c62ba12a1a586760a642a4025 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:50:00 +1000 Subject: [PATCH 177/197] fix vscode plugins not whitelisted --- hosts/myputer/default.nix | 29 ++++++++++++++++++++--------- 1 file changed, 20 insertions(+), 9 deletions(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 72b1e7d..df47254 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -39,15 +39,26 @@ in { # ]; nixpkgs.config.allowUnfreePredicate = let - whitelist = map lib.getName [ - pkgs.obsidian - pkgs.gitkraken - pkgs.steam - pkgs.steamcmd - pkgs.steam-unwrapped - pkgs.dwarf-fortress - pkgs.discord - ]; + whitelist = let + vscext = pkgs.vscode-extensions; + in + with pkgs; + map lib.getName [ + discord + steam + steamcmd + steam-unwrapped + dwarf-fortress + + obsidian + gitkraken + + vscode + vscext.ms-dotnettools.csharp + vscext.ms-dotnettools.csdevkit + vscext.github.copilot + vscext.github.copilot-chat + ]; in pkg: builtins.elem (lib.getName pkg) whitelist; From 892a1ae877b27b88aa0af16ff7c5f107d8d054a5 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:51:49 +1000 Subject: [PATCH 178/197] add MicroTik WinBox --- hosts/modules/apps/winbox.nix | 6 ++++++ hosts/myputer/default.nix | 14 +++++++++++++- 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 hosts/modules/apps/winbox.nix diff --git a/hosts/modules/apps/winbox.nix b/hosts/modules/apps/winbox.nix new file mode 100644 index 0000000..eaf8b7c --- /dev/null +++ b/hosts/modules/apps/winbox.nix @@ -0,0 +1,6 @@ +{...}: { + programs.winbox = { + enable = true; + openFirewall = false; # port: 5678 + }; +} diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index df47254..2ba674d 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -20,7 +20,9 @@ in { ../modules/wm/hyprland.nix ../modules/steam.nix + ../modules/obsidian.nix + ../modules/apps/winbox.nix #../modules/flipperzero.nix #../modules/chameleonultragui.nix @@ -50,6 +52,8 @@ in { steam-unwrapped dwarf-fortress + winbox + obsidian gitkraken @@ -118,7 +122,15 @@ in { hostName = "myputer"; networkmanager.enable = true; - firewall.enable = true; + firewall = { + enable = true; + allowedTCPPorts = [ + 22 # SSH + 80 # HTTP + 443 # HTTPS + 5678 # MikroTik WinBox + ]; + }; }; # ----- SERVICES ----- From fd48d6af9a3eaf7a12bb8560048161d849b4d2b0 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:52:08 +1000 Subject: [PATCH 179/197] add Mozilla Thunderbird --- homes/me/default.nix | 1 + homes/modules/apps/thunderbird.nix | 10 ++++++++++ 2 files changed, 11 insertions(+) create mode 100644 homes/modules/apps/thunderbird.nix diff --git a/homes/me/default.nix b/homes/me/default.nix index d37a8e9..227ae21 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -17,6 +17,7 @@ ../modules/btop.nix ../modules/term/foot.nix ../modules/firefox.nix + ../modules/apps/thunderbird.nix #../modules/wm/hypr/hypridle.nix ../modules/wm/hypr/hyprlock.nix diff --git a/homes/modules/apps/thunderbird.nix b/homes/modules/apps/thunderbird.nix new file mode 100644 index 0000000..dd4f861 --- /dev/null +++ b/homes/modules/apps/thunderbird.nix @@ -0,0 +1,10 @@ +{...}: { + programs.thunderbird = { + enable = true; + profiles = { + "me" = { + isDefault = true; + }; + }; + }; +} From 596fcd5389f45bbc79e13e7a78631cb9625d37e9 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:52:24 +1000 Subject: [PATCH 180/197] add Tor Browser --- homes/me/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/homes/me/default.nix b/homes/me/default.nix index 227ae21..f264790 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -56,6 +56,7 @@ # for services.gnome-keyring pkgs.gcr # provides org.gnome.keyring.SystemPrompter seahorse # gui + tor-browser ]; }; From 46ed0778136576b1dbb33e8d7fe9934b2214f3b3 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:52:46 +1000 Subject: [PATCH 181/197] open minecraft server port 25565 (myputer) --- hosts/myputer/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 2ba674d..17bdc86 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -129,6 +129,7 @@ in { 80 # HTTP 443 # HTTPS 5678 # MikroTik WinBox + 25565 # Minecraft LAN ]; }; }; From 17807752e57ef6f56d552e5cda553a8ca19daf87 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 11:53:42 +1000 Subject: [PATCH 182/197] packaging JetBrains Rider (UNSTABLE) --- hosts/modules/apps/rider.nix | 47 ++++++++++++++++++++++++++++++++++++ hosts/myputer/default.nix | 8 ++++++ 2 files changed, 55 insertions(+) create mode 100644 hosts/modules/apps/rider.nix diff --git a/hosts/modules/apps/rider.nix b/hosts/modules/apps/rider.nix new file mode 100644 index 0000000..cf54c66 --- /dev/null +++ b/hosts/modules/apps/rider.nix @@ -0,0 +1,47 @@ +{ + pkgs, + pkgs-unstable, + ... +}: { + nixpkgs.overlays = [ + (self: super: { + # rider-override = super.jetbrains.rider.overrideAttrs ( + # final: prev: { + # # XXX: DEBUG + # buildInputs = prev.buildInputs ++ [pkgs.icu]; + # } + # ); + + # rider-fhs = super.buildFHSEnv { + # name = "rider-fhs"; + + # targetPkgs = pkgs: + # with pkgs; [ + # jetbrains.rider + # icu + # ]; + + # runScript = ''${super.jetbrains.rider}/bin/rider''; + + # profile = '' + # export DOTNET_CLI_TELEMETRY_OPTOUT=1 + # ''; + # }; + }) + ]; + + environment.systemPackages = [ + # rider-fhs + # rider-override + + # Unsure latest "stable" version + # pkgs-unstable.jetbrains.rider + ]; + + programs.nix-ld = { + enable = true; + libraries = with pkgs; [ + icu + ]; + }; +} diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 17bdc86..753899f 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -22,6 +22,7 @@ in { ../modules/steam.nix ../modules/obsidian.nix + ../modules/apps/rider.nix ../modules/apps/winbox.nix #../modules/flipperzero.nix @@ -62,6 +63,12 @@ in { vscext.ms-dotnettools.csdevkit vscext.github.copilot vscext.github.copilot-chat + + # XXX: DEBUG + # rider-override + # XXX: DEBUG + + # jetbrains.rider ]; in pkg: builtins.elem (lib.getName pkg) whitelist; @@ -327,6 +334,7 @@ in { dotnetCorePackages.dotnet_9.sdk dotnetCorePackages.dotnet_9.aspnetcore dotnetCorePackages.dotnet_9.runtime + mono omnisharp-roslyn netcoredbg From 09db1c47e18c2c79ba5960c91249884b8b65a55e Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 17:22:27 +1000 Subject: [PATCH 183/197] progress flake inputs to latest --- flake.lock | 80 +++++++++++++++++++++++++++++------------------------- 1 file changed, 43 insertions(+), 37 deletions(-) diff --git a/flake.lock b/flake.lock index 4785725..14e353a 100644 --- a/flake.lock +++ b/flake.lock @@ -2,15 +2,15 @@ "nodes": { "ags": { "inputs": { - "nixpkgs": "nixpkgs", - "systems": "systems" + "astal": "astal", + "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1728326430, - "narHash": "sha256-tV1ABHuA1HItMdCTuNdA8fMB+qw7LpjvI945VwMSABI=", + "lastModified": 1761132437, + "narHash": "sha256-ODNtCB3BHSv0EEA6AT3YDCELPeFX1n8e9lU1yL+s+Hk=", "owner": "Aylur", "repo": "ags", - "rev": "60180a184cfb32b61a1d871c058b31a3b9b0743d", + "rev": "63df72508c7d334c8f9f65d2e80e9db02838378b", "type": "github" }, "original": { @@ -19,6 +19,27 @@ "type": "github" } }, + "astal": { + "inputs": { + "nixpkgs": [ + "ags", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1761075011, + "narHash": "sha256-gQFgsJz2RQUMFdaHrbqRPYackAZYF3chcsZp8rUctVU=", + "owner": "aylur", + "repo": "astal", + "rev": "c8df34d0e5fc4f3a36f72bae7dfc5ecf0000e1c8", + "type": "github" + }, + "original": { + "owner": "aylur", + "repo": "astal", + "type": "github" + } + }, "colmena": { "inputs": { "flake-compat": "flake-compat", @@ -78,11 +99,11 @@ "nixpkgs": "nixpkgs_3" }, "locked": { - "lastModified": 1730004881, - "narHash": "sha256-8xVIqIW25o2uCL0fxAmP4Sj9sdebarQXmd1+64yMe8o=", + "lastModified": 1757136219, + "narHash": "sha256-tKU+vq34KHu/A2wD7WdgP5A4/RCmSD8hB0TyQAUlixA=", "owner": "vinceliuice", "repo": "grub2-themes", - "rev": "42c232dfb46bf93c17506cbc1a574e5e89b5e09f", + "rev": "80dd04ddf3ba7b284a7b1a5df2b1e95ee2aad606", "type": "github" }, "original": { @@ -114,15 +135,15 @@ }, "nixpkgs": { "locked": { - "lastModified": 1725634671, - "narHash": "sha256-v3rIhsJBOMLR8e/RNWxr828tB+WywYIoajrZKFM+0Gg=", - "owner": "NixOS", + "lastModified": 1760878510, + "narHash": "sha256-K5Osef2qexezUfs0alLvZ7nQFTGS9DL2oTVsIXsqLgs=", + "owner": "nixos", "repo": "nixpkgs", - "rev": "574d1eac1c200690e27b8eb4e24887f8df7ac27c", + "rev": "5e2a59a5b1a82f89f2c7e598302a9cacebb72a67", "type": "github" }, "original": { - "owner": "NixOS", + "owner": "nixos", "ref": "nixos-unstable", "repo": "nixpkgs", "type": "github" @@ -130,11 +151,11 @@ }, "nixpkgs-unstable": { "locked": { - "lastModified": 1753939845, - "narHash": "sha256-K2ViRJfdVGE8tpJejs8Qpvvejks1+A4GQej/lBk5y7I=", + "lastModified": 1761114652, + "narHash": "sha256-f/QCJM/YhrV/lavyCVz8iU3rlZun6d+dAiC3H+CDle4=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "94def634a20494ee057c76998843c015909d6311", + "rev": "01f116e4df6a15f4ccdffb1bcd41096869fb385c", "type": "github" }, "original": { @@ -162,11 +183,11 @@ }, "nixpkgs_3": { "locked": { - "lastModified": 1730808093, - "narHash": "sha256-oOenwoxpzQsBNi7KltgnXqq6e0+CxlfNXKn3k27w6cQ=", + "lastModified": 1761269590, + "narHash": "sha256-yTr+PCi4wGbOEidrm8XyXBobLxLMqIBsbUyhwsN6wrc=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c1a390f74b2c93f69a6805142f11a215a689cec1", + "rev": "d792a6e0cd4ba35c90ea787b717d72410f56dc40", "type": "github" }, "original": { @@ -178,11 +199,11 @@ }, "nixpkgs_4": { "locked": { - "lastModified": 1752620740, - "narHash": "sha256-f3pO+9lg66mV7IMmmIqG4PL3223TYMlnlw+pnpelbss=", + "lastModified": 1761016216, + "narHash": "sha256-G/iC4t/9j/52i/nm+0/4ybBmAF4hzR8CNHC75qEhjHo=", "owner": "nixos", "repo": "nixpkgs", - "rev": "32a4e87942101f1c9f9865e04dc3ddb175f5f32e", + "rev": "481cf557888e05d3128a76f14c76397b7d7cc869", "type": "github" }, "original": { @@ -216,21 +237,6 @@ "repo": "nixpkgs", "type": "github" } - }, - "systems": { - "locked": { - "lastModified": 1689347949, - "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", - "owner": "nix-systems", - "repo": "default-linux", - "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default-linux", - "type": "github" - } } }, "root": "root", From 11b4c920fc22c6c8fc50c4fc45c2cee79592cb78 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 17:23:28 +1000 Subject: [PATCH 184/197] patch mbedtls_2 now labelled insecure occurred due to flake.lock progression --- hosts/modules/steam.nix | 33 +++++++++++++++++++++++++-------- 1 file changed, 25 insertions(+), 8 deletions(-) diff --git a/hosts/modules/steam.nix b/hosts/modules/steam.nix index 5c72185..e554441 100644 --- a/hosts/modules/steam.nix +++ b/hosts/modules/steam.nix @@ -3,13 +3,25 @@ lib, ... }: { - nixpkgs.config.allowUnfreePredicate = pkg: - builtins.elem (lib.getName pkg) [ - "steam" - "steam-original" - "steam-unwrapped" - "steam-run" - ]; + # nixpkgs.config.allowUnfreePredicate = pkg: + # builtins.elem (lib.getName pkg) [ + # "steam" + # "steam-original" + # "steam-unwrapped" + # "steam-run" + # ]; + nixpkgs.overlays = [ + (self: super: { + lutris = super.lutris.overrideAttrs (final: prev: { + # WARNING: pkgs.mbedtls_2 is marked insecure! + # Replace pkgs.mbedtls_2 (v2.28.10) with pkgs.mbedtls (v3.6.4) + targetPkgs = pkgs: ( + (builtins.filter (p: p != pkgs.mbedtls_2) (prev.targetPkgs pkgs)) + ++ [pkgs.mbedtls] + ); + }); + }) + ]; programs = { steam = { @@ -33,7 +45,12 @@ mangohud protonup-qt - lutris + + # XXX: DEBUG: disable lutris + # XXX: NOTE: pkgs.lutris depends on pkgs.mbedtls_2 which is marked insecure! + # XXX: NOTE: Use the provided overlay to patch pkgs.mbedtls_2 -> pkgs.mbedtls + # lutris + bottles heroic ]; From 2fb9171d923761168d24776f855a6cb487bf6820 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 17:24:11 +1000 Subject: [PATCH 185/197] replace ags -> fuzzel ags usage changed after flake.lock progression --- config.temp/hyprland.conf | 5 +++-- homes/me/default.nix | 3 +++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/config.temp/hyprland.conf b/config.temp/hyprland.conf index 7243478..4876e8a 100755 --- a/config.temp/hyprland.conf +++ b/config.temp/hyprland.conf @@ -25,8 +25,9 @@ monitor=eDP-1, highres@highrr, auto, 1.0 # Set programs that you use $terminal = ghostty #rio $fileManager = thunar -#$menu = wofi --show drun -$menu = ags -t "applauncher" +# $menu = wofi --show drun +# $menu = ags -t "applauncher" +$menu = fuzzel $colorpicker = hyprpicker | head -c 7 | wl-copy ################# diff --git a/homes/me/default.nix b/homes/me/default.nix index f264790..6df442b 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -56,7 +56,10 @@ # for services.gnome-keyring pkgs.gcr # provides org.gnome.keyring.SystemPrompter seahorse # gui + tor-browser + + fuzzel ]; }; From ffb9b35d46342e71fba5150dd4da0004ba5859c0 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 17:24:58 +1000 Subject: [PATCH 186/197] clean rider install + progress to latest on pkgs-unstable --- hosts/modules/apps/rider.nix | 43 +++++++++++------------------------- hosts/myputer/default.nix | 8 ------- 2 files changed, 13 insertions(+), 38 deletions(-) diff --git a/hosts/modules/apps/rider.nix b/hosts/modules/apps/rider.nix index cf54c66..94ac874 100644 --- a/hosts/modules/apps/rider.nix +++ b/hosts/modules/apps/rider.nix @@ -3,39 +3,22 @@ pkgs-unstable, ... }: { - nixpkgs.overlays = [ - (self: super: { - # rider-override = super.jetbrains.rider.overrideAttrs ( - # final: prev: { - # # XXX: DEBUG - # buildInputs = prev.buildInputs ++ [pkgs.icu]; - # } - # ); + environment.systemPackages = with pkgs; [ + # Ensure latest stable Rider version (not necessarily stable on NixOS) + pkgs-unstable.jetbrains.rider - # rider-fhs = super.buildFHSEnv { - # name = "rider-fhs"; + # .NET + dotnetCorePackages.dotnet_9.sdk + dotnetCorePackages.dotnet_9.aspnetcore + dotnetCorePackages.dotnet_9.runtime - # targetPkgs = pkgs: - # with pkgs; [ - # jetbrains.rider - # icu - # ]; + # Mono + mono + msbuild - # runScript = ''${super.jetbrains.rider}/bin/rider''; - - # profile = '' - # export DOTNET_CLI_TELEMETRY_OPTOUT=1 - # ''; - # }; - }) - ]; - - environment.systemPackages = [ - # rider-fhs - # rider-override - - # Unsure latest "stable" version - # pkgs-unstable.jetbrains.rider + # .NET Framework Tools/Services + omnisharp-roslyn + netcoredbg ]; programs.nix-ld = { diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 753899f..7121aeb 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -330,14 +330,6 @@ in { # Sage sageWithDoc # SageMath + HTML Documentation - # .NET - dotnetCorePackages.dotnet_9.sdk - dotnetCorePackages.dotnet_9.aspnetcore - dotnetCorePackages.dotnet_9.runtime - mono - omnisharp-roslyn - netcoredbg - openvpn inetutils From 728f933f394bfe32f1ebcbc72e4ad114e698dcbd Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 17:25:15 +1000 Subject: [PATCH 187/197] increase nix.settings.download-buffer-size --- hosts/myputer/default.nix | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 7121aeb..0ffa5d5 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -29,10 +29,13 @@ in { #../modules/chameleonultragui.nix ]; - nix.settings.experimental-features = [ - "nix-command" - "flakes" - ]; + nix.settings = { + experimental-features = [ + "nix-command" + "flakes" + ]; + download-buffer-size = 524288000; # 500 MiB + }; # nixpkgs.overlays = [ # (self: super: { # jdk17 = super.jdk17.override (prev: { From e2f641e5535342db34fefb07bb261a32f626c1a5 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 17:31:23 +1000 Subject: [PATCH 188/197] use pkgs-unstable.msbuild pkgs.msbuild use .NET6 (marked insecure), pkgs-unstable.msbuild uses .NET8 --- hosts/modules/apps/rider.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hosts/modules/apps/rider.nix b/hosts/modules/apps/rider.nix index 94ac874..d7b3a1c 100644 --- a/hosts/modules/apps/rider.nix +++ b/hosts/modules/apps/rider.nix @@ -14,7 +14,9 @@ # Mono mono - msbuild + # NOTE: nixpkgs-unstable uses .NET8 SDK + # WARNING: nixpkgs-25.05 uses .NET6 SDK (now marked insecure) + pkgs-unstable.msbuild # .NET Framework Tools/Services omnisharp-roslyn From c8d3fe1e6b552a697ff2de3f198c9d1057227b97 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 23:39:00 +1000 Subject: [PATCH 189/197] add tmux --- homes/me/default.nix | 8 +++++--- homes/modules/tmux.nix | 5 +++++ 2 files changed, 10 insertions(+), 3 deletions(-) create mode 100644 homes/modules/tmux.nix diff --git a/homes/me/default.nix b/homes/me/default.nix index 6df442b..5f4c039 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -8,14 +8,16 @@ ... } @ args: { imports = [ + ../modules/fish.nix + ../modules/btop.nix + ../modules/tmux.nix + ../modules/term/foot.nix ../modules/git.nix ../modules/bat.nix - ../modules/fish.nix + ../modules/editor/helix.nix (import ../modules/editor/vscode.nix args) - ../modules/btop.nix - ../modules/term/foot.nix ../modules/firefox.nix ../modules/apps/thunderbird.nix diff --git a/homes/modules/tmux.nix b/homes/modules/tmux.nix new file mode 100644 index 0000000..e5946c0 --- /dev/null +++ b/homes/modules/tmux.nix @@ -0,0 +1,5 @@ +{...}: { + programs.tmux = { + enable = true; + }; +} From ca3fd4093f9d25d6966bdc98f5bcbaa6dc60e696 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 23:44:56 +1000 Subject: [PATCH 190/197] fix ugly nixpkgs.config.allowUnfreePredicate --- hosts/myputer/default.nix | 44 +++++++++++++++++++-------------------- 1 file changed, 21 insertions(+), 23 deletions(-) diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 0ffa5d5..8b5079b 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -45,34 +45,32 @@ in { # ]; nixpkgs.config.allowUnfreePredicate = let - whitelist = let - vscext = pkgs.vscode-extensions; - in - with pkgs; - map lib.getName [ - discord - steam - steamcmd - steam-unwrapped - dwarf-fortress + vscext = pkgs.vscode-extensions; + whitelist = with pkgs; + map lib.getName [ + discord + steam + steamcmd + steam-unwrapped + dwarf-fortress - winbox + winbox - obsidian - gitkraken + obsidian + gitkraken - vscode - vscext.ms-dotnettools.csharp - vscext.ms-dotnettools.csdevkit - vscext.github.copilot - vscext.github.copilot-chat + vscode + vscext.ms-dotnettools.csharp + vscext.ms-dotnettools.csdevkit + vscext.github.copilot + vscext.github.copilot-chat - # XXX: DEBUG - # rider-override - # XXX: DEBUG + # XXX: DEBUG + # rider-override + # XXX: DEBUG - # jetbrains.rider - ]; + # jetbrains.rider + ]; in pkg: builtins.elem (lib.getName pkg) whitelist; From 8f222f454ad6c49ca2b67e6de33ae63471b13e66 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 23:45:29 +1000 Subject: [PATCH 191/197] add vscode + extensions to lolcathost nixpkgs allowed unfree --- hosts/lolcathost/default.nix | 34 ++++++++++++++++++++++++++-------- 1 file changed, 26 insertions(+), 8 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index 9075286..b09a29c 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -35,14 +35,32 @@ in { ]; nixpkgs.config.allowUnfreePredicate = let - whitelist = map lib.getName [ - pkgs.obsidian - pkgs.gitkraken - pkgs.steam - pkgs.steamcmd - pkgs.steam-unwrapped - pkgs.dwarf-fortress - ]; + vscext = pkgs.vscode-extensions; + whitelist = with pkgs; + map lib.getName [ + discord + steam + steamcmd + steam-unwrapped + dwarf-fortress + + winbox + + obsidian + gitkraken + + vscode + vscext.ms-dotnettools.csharp + vscext.ms-dotnettools.csdevkit + vscext.github.copilot + vscext.github.copilot-chat + + # XXX: DEBUG + # rider-override + # XXX: DEBUG + + # jetbrains.rider + ]; in pkg: builtins.elem (lib.getName pkg) whitelist; From 8a14f7e2fc78d40dddb499a79d088f2b8896b3b9 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Fri, 24 Oct 2025 23:46:17 +1000 Subject: [PATCH 192/197] remove dwarf-fortress & mindustry --- hosts/lolcathost/default.nix | 3 --- hosts/myputer/default.nix | 1 - 2 files changed, 4 deletions(-) diff --git a/hosts/lolcathost/default.nix b/hosts/lolcathost/default.nix index b09a29c..dbf965d 100755 --- a/hosts/lolcathost/default.nix +++ b/hosts/lolcathost/default.nix @@ -42,7 +42,6 @@ in { steam steamcmd steam-unwrapped - dwarf-fortress winbox @@ -382,8 +381,6 @@ in { libargon2 # Games - mindustry - dwarf-fortress prismlauncher # minecraft ]; diff --git a/hosts/myputer/default.nix b/hosts/myputer/default.nix index 8b5079b..6986a31 100755 --- a/hosts/myputer/default.nix +++ b/hosts/myputer/default.nix @@ -52,7 +52,6 @@ in { steam steamcmd steam-unwrapped - dwarf-fortress winbox From 8f7a725fd591ac63a5dec2f27826e88f5136a5da Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 1 Nov 2025 12:08:58 +1000 Subject: [PATCH 193/197] JetBrains Rider requires Chromium browser --- hosts/modules/apps/rider.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hosts/modules/apps/rider.nix b/hosts/modules/apps/rider.nix index d7b3a1c..adf8885 100644 --- a/hosts/modules/apps/rider.nix +++ b/hosts/modules/apps/rider.nix @@ -7,6 +7,10 @@ # Ensure latest stable Rider version (not necessarily stable on NixOS) pkgs-unstable.jetbrains.rider + # NOTE: Blazor requires a Chromium-based browser + chromium + # arc-browser + # .NET dotnetCorePackages.dotnet_9.sdk dotnetCorePackages.dotnet_9.aspnetcore From 91afb320497611681ed4fffa5d33b0008f8f867c Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 1 Nov 2025 12:09:28 +1000 Subject: [PATCH 194/197] add speedtest-cli --- homes/me/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/homes/me/default.nix b/homes/me/default.nix index 5f4c039..6998e63 100755 --- a/homes/me/default.nix +++ b/homes/me/default.nix @@ -62,6 +62,8 @@ tor-browser fuzzel + + speedtest-cli ]; }; From a03ea35af7cf5a8c50deec0bacf4b091f897ebc2 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 1 Nov 2025 12:27:00 +1000 Subject: [PATCH 195/197] begin working on my nib library <3 --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 31f728a..81b47aa 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ ISSUES/ secrets/ +nib/ result rebuild*.log From 540fd9c2a99e1317375a0849b4de670d76c086bf Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 1 Nov 2025 13:21:32 +1000 Subject: [PATCH 196/197] begin migrating hyprland config to home-manager --- homes/modules/wm/hypr/hyprland.nix | 41 ++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/homes/modules/wm/hypr/hyprland.nix b/homes/modules/wm/hypr/hyprland.nix index 40a1d99..b9ca1f7 100755 --- a/homes/modules/wm/hypr/hyprland.nix +++ b/homes/modules/wm/hypr/hyprland.nix @@ -1,2 +1,43 @@ # NOTE: hyprland must be enabled in BOTH your host config (for running hyprland) # and your home-manager config (for managing hyprland's config files) +{ + pkgs, + pkgs-unstable, + inputs, + config, + lib, + ... +}: { + options.hyprland = { + enable = lib.mkEnableOption "Hyprland"; + }; + + config = lib.mkIf config.hyprland.enable { + wayland.windowManager.hyprland = { + enable = true; + package = pkgs.hyprland; # pkgs-unstable.hyprland; + + xwayland.enable = true; + + systemd = { + enable = true; + # enable autostart of applications + # REF: `man 8 systemd-xdg-autostart-generator` + enableXdgAutostart = true; + }; + + plugins = with inputs; [ + split-monitor-workspaces.packages.${pkgs.system}.split + ]; + }; + + xdg.portal = { + enable = true; + extraPortals = with pkgs; [ + xdg-desktop-portal-gtk + ]; + }; + + # TODO: finish this + }; +} From f0c7f565c3435cedd17859dfce0acdb1d7da0f03 Mon Sep 17 00:00:00 2001 From: Emile Clark-Boman Date: Sat, 1 Nov 2025 13:21:55 +1000 Subject: [PATCH 197/197] remove flake.nix:inputs.ags --- flake.lock | 75 +++++++----------------------------------------------- flake.nix | 6 ++--- 2 files changed, 11 insertions(+), 70 deletions(-) diff --git a/flake.lock b/flake.lock index 14e353a..e1ab303 100644 --- a/flake.lock +++ b/flake.lock @@ -1,51 +1,11 @@ { "nodes": { - "ags": { - "inputs": { - "astal": "astal", - "nixpkgs": "nixpkgs" - }, - "locked": { - "lastModified": 1761132437, - "narHash": "sha256-ODNtCB3BHSv0EEA6AT3YDCELPeFX1n8e9lU1yL+s+Hk=", - "owner": "Aylur", - "repo": "ags", - "rev": "63df72508c7d334c8f9f65d2e80e9db02838378b", - "type": "github" - }, - "original": { - "owner": "Aylur", - "repo": "ags", - "type": "github" - } - }, - "astal": { - "inputs": { - "nixpkgs": [ - "ags", - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1761075011, - "narHash": "sha256-gQFgsJz2RQUMFdaHrbqRPYackAZYF3chcsZp8rUctVU=", - "owner": "aylur", - "repo": "astal", - "rev": "c8df34d0e5fc4f3a36f72bae7dfc5ecf0000e1c8", - "type": "github" - }, - "original": { - "owner": "aylur", - "repo": "astal", - "type": "github" - } - }, "colmena": { "inputs": { "flake-compat": "flake-compat", "flake-utils": "flake-utils", "nix-github-actions": "nix-github-actions", - "nixpkgs": "nixpkgs_2", + "nixpkgs": "nixpkgs", "stable": "stable" }, "locked": { @@ -96,7 +56,7 @@ }, "grub2-themes": { "inputs": { - "nixpkgs": "nixpkgs_3" + "nixpkgs": "nixpkgs_2" }, "locked": { "lastModified": 1757136219, @@ -135,15 +95,15 @@ }, "nixpkgs": { "locked": { - "lastModified": 1760878510, - "narHash": "sha256-K5Osef2qexezUfs0alLvZ7nQFTGS9DL2oTVsIXsqLgs=", - "owner": "nixos", + "lastModified": 1734119587, + "narHash": "sha256-AKU6qqskl0yf2+JdRdD0cfxX4b9x3KKV5RqA6wijmPM=", + "owner": "NixOS", "repo": "nixpkgs", - "rev": "5e2a59a5b1a82f89f2c7e598302a9cacebb72a67", + "rev": "3566ab7246670a43abd2ffa913cc62dad9cdf7d5", "type": "github" }, "original": { - "owner": "nixos", + "owner": "NixOS", "ref": "nixos-unstable", "repo": "nixpkgs", "type": "github" @@ -166,22 +126,6 @@ } }, "nixpkgs_2": { - "locked": { - "lastModified": 1734119587, - "narHash": "sha256-AKU6qqskl0yf2+JdRdD0cfxX4b9x3KKV5RqA6wijmPM=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "3566ab7246670a43abd2ffa913cc62dad9cdf7d5", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_3": { "locked": { "lastModified": 1761269590, "narHash": "sha256-yTr+PCi4wGbOEidrm8XyXBobLxLMqIBsbUyhwsN6wrc=", @@ -197,7 +141,7 @@ "type": "github" } }, - "nixpkgs_4": { + "nixpkgs_3": { "locked": { "lastModified": 1761016216, "narHash": "sha256-G/iC4t/9j/52i/nm+0/4ybBmAF4hzR8CNHC75qEhjHo=", @@ -215,10 +159,9 @@ }, "root": { "inputs": { - "ags": "ags", "colmena": "colmena", "grub2-themes": "grub2-themes", - "nixpkgs": "nixpkgs_4", + "nixpkgs": "nixpkgs_3", "nixpkgs-unstable": "nixpkgs-unstable" } }, diff --git a/flake.nix b/flake.nix index 3d40a53..e339ce6 100644 --- a/flake.nix +++ b/flake.nix @@ -5,11 +5,9 @@ nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05"; nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable"; - grub2-themes.url = "github:vinceliuice/grub2-themes"; - - ags.url = "github:Aylur/ags"; - colmena.url = "github:zhaofengli/colmena/?rev=47b6414d800c8471e98ca072bc0835345741a56a"; + + grub2-themes.url = "github:vinceliuice/grub2-themes"; }; outputs = {