Compare commits

..

5 commits

Author SHA1 Message Date
a5631ee6f9 Use nixpkgs.config.allowUnfreePredicate
+removed unused apps
2025-07-19 23:24:33 +10:00
1b09aac8fc deploy helper script now pipes to ./rebuild.log 2025-07-19 23:22:24 +10:00
0762e2fba6 Added GUIDE markdown file 2025-07-19 23:20:20 +10:00
58065c0478 Added helper script for analyzing simple errors 2025-07-19 23:19:39 +10:00
6ccfdadeb5 Progress nixpkgs to 25.05
Update nerdfont naming convention accordingly
2025-07-19 23:19:15 +10:00
8 changed files with 108 additions and 239 deletions

18
GUIDE Normal file
View file

@ -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 <OLD_CHANNEL>
nix-channel --add <NEW_CHANNEL> # 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

13
deploy
View file

@ -20,13 +20,18 @@ collect_garbage () {
rebuild_flake () { rebuild_flake () {
# make sure all changes are visible to nixos # make sure all changes are visible to nixos
git add . --verbose git add . --verbose
local FLAGS=
if [ "$1" = "reinstall-bootloader" ]; then 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) # 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 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 () { deploy_hive () {

177
flake.lock generated
View file

@ -19,25 +19,6 @@
"type": "github" "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": { "aquamarine": {
"inputs": { "inputs": {
"hyprutils": [ "hyprutils": [
@ -127,20 +108,6 @@
} }
}, },
"flake-compat_3": { "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, "flake": false,
"locked": { "locked": {
"lastModified": 1696426674, "lastModified": 1696426674,
@ -156,7 +123,7 @@
"type": "github" "type": "github"
} }
}, },
"flake-compat_5": { "flake-compat_4": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1696426674, "lastModified": 1696426674,
@ -337,25 +304,6 @@
"type": "github" "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": { "hyprutils": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -406,22 +354,6 @@
"type": "github" "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": { "nix-github-actions": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -443,25 +375,6 @@
"type": "github" "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": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1725634671, "lastModified": 1725634671,
@ -544,69 +457,21 @@
}, },
"nixpkgs_5": { "nixpkgs_5": {
"locked": { "locked": {
"lastModified": 1725634671, "lastModified": 1752620740,
"narHash": "sha256-v3rIhsJBOMLR8e/RNWxr828tB+WywYIoajrZKFM+0Gg=", "narHash": "sha256-f3pO+9lg66mV7IMmmIqG4PL3223TYMlnlw+pnpelbss=",
"owner": "NixOS", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "574d1eac1c200690e27b8eb4e24887f8df7ac27c", "rev": "32a4e87942101f1c9f9865e04dc3ddb175f5f32e",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "NixOS", "owner": "nixos",
"ref": "nixos-unstable", "ref": "nixos-25.05",
"repo": "nixpkgs", "repo": "nixpkgs",
"type": "github" "type": "github"
} }
}, },
"nixpkgs_6": { "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": 1739357830,
"narHash": "sha256-9xim3nJJUFbVbJCz48UP4fGRStVW5nv4VdbimbKxJ3I=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "0ff09db9d034a04acd4e8908820ba0b410d7a33a",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-24.11",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_9": {
"locked": { "locked": {
"lastModified": 1730200266, "lastModified": 1730200266,
"narHash": "sha256-l253w0XMT8nWHGXuXqyiIC/bMvh1VRszGXgdpQlfhvU=", "narHash": "sha256-l253w0XMT8nWHGXuXqyiIC/bMvh1VRszGXgdpQlfhvU=",
@ -652,17 +517,14 @@
"colmena": "colmena", "colmena": "colmena",
"grub2-themes": "grub2-themes", "grub2-themes": "grub2-themes",
"hyprland": "hyprland", "hyprland": "hyprland",
"hyprpanel": "hyprpanel", "nixpkgs": "nixpkgs_5",
"nix-flatpak": "nix-flatpak",
"nixcord": "nixcord",
"nixpkgs": "nixpkgs_8",
"spicetify-nix": "spicetify-nix", "spicetify-nix": "spicetify-nix",
"swww": "swww" "swww": "swww"
} }
}, },
"spicetify-nix": { "spicetify-nix": {
"inputs": { "inputs": {
"flake-compat": "flake-compat_4", "flake-compat": "flake-compat_3",
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
] ]
@ -699,8 +561,8 @@
}, },
"swww": { "swww": {
"inputs": { "inputs": {
"flake-compat": "flake-compat_5", "flake-compat": "flake-compat_4",
"nixpkgs": "nixpkgs_9", "nixpkgs": "nixpkgs_6",
"utils": "utils" "utils": "utils"
}, },
"locked": { "locked": {
@ -748,21 +610,6 @@
} }
}, },
"systems_3": { "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": { "locked": {
"lastModified": 1681028828, "lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
@ -779,7 +626,7 @@
}, },
"utils": { "utils": {
"inputs": { "inputs": {
"systems": "systems_4" "systems": "systems_3"
}, },
"locked": { "locked": {
"lastModified": 1726560853, "lastModified": 1726560853,

View file

@ -2,8 +2,7 @@
description = "Emile's Nix Dotfiles"; description = "Emile's Nix Dotfiles";
inputs = { inputs = {
# nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05"; nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05";
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11";
#home-manager = { #home-manager = {
# url = "github:nix-community/home-manager"; # url = "github:nix-community/home-manager";
@ -15,26 +14,15 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
nixcord.url = "github:kaylorben/nixcord";
grub2-themes.url = "github:vinceliuice/grub2-themes"; grub2-themes.url = "github:vinceliuice/grub2-themes";
# is this necessary? (aren't I enabling it in `configuration.nix` anyways?) # is this necessary? (aren't I enabling it in `configuration.nix` anyways?)
hyprland.url = "github:hyprwm/Hyprland"; hyprland.url = "github:hyprwm/Hyprland";
hyprpanel = {
url = "github:Jas-SinghFSU/HyprPanel";
#inputs.nixpkgs.follows = "nixpkgs";
};
swww.url = "github:LGFae/swww"; 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"; ags.url = "github:Aylur/ags";
# colmena.url = "github:zhaofengli/colmena";
colmena.url = "github:zhaofengli/colmena/?rev=47b6414d800c8471e98ca072bc0835345741a56a"; colmena.url = "github:zhaofengli/colmena/?rev=47b6414d800c8471e98ca072bc0835345741a56a";
}; };
@ -44,8 +32,6 @@
#home-manager, #home-manager,
hyprland, hyprland,
grub2-themes, grub2-themes,
nixcord,
hyprpanel,
colmena, colmena,
... ...
} @ inputs: let } @ inputs: let
@ -54,11 +40,8 @@
pkgs = import nixpkgs { pkgs = import nixpkgs {
inherit system; inherit system;
config = { config = {
allowUnfree = true; allowUnfree = false; # sanity check
}; };
overlays = [
inputs.hyprpanel.overlay
];
}; };
# TODO: come back to this its really cool # TODO: come back to this its really cool
@ -76,7 +59,7 @@
# i be on my puter fr # i be on my puter fr
myputer = nixpkgs.lib.nixosSystem { myputer = nixpkgs.lib.nixosSystem {
# nix passes these to every single module # nix passes these to every single module
specialArgs = {inherit inputs pkgs;}; specialArgs = {inherit inputs;};
modules = [ modules = [
./hosts/myputer ./hosts/myputer
@ -86,7 +69,7 @@
# my laptop 0w0 # my laptop 0w0
lolcathost = nixpkgs.lib.nixosSystem { lolcathost = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs pkgs;}; specialArgs = {inherit inputs;};
modules = [ modules = [
./hosts/lolcathost ./hosts/lolcathost
@ -98,7 +81,6 @@
# remote deployment to my servers!! # remote deployment to my servers!!
colmenaHive = colmena.lib.makeHive { colmenaHive = colmena.lib.makeHive {
meta = { meta = {
# set nixpkgs global
nixpkgs = pkgs; nixpkgs = pkgs;
# set nixpkgs per server # set nixpkgs per server
nodeNixpkgs = { nodeNixpkgs = {
@ -107,9 +89,6 @@
config.allowUnfree = false; config.allowUnfree = false;
}; };
}; };
# we can use `specialArgs.inputs` to inject wishlist into hyrule's module
#specialArgs.inputs = with inputs; {inherit wishlist;};
}; };
# meine vps # meine vps

View file

@ -16,13 +16,12 @@
../modules/bat.nix ../modules/bat.nix
../modules/fish.nix ../modules/fish.nix
../modules/editor/helix.nix ../modules/editor/helix.nix
../modules/editor/vscodium.nix # ../modules/editor/vscodium.nix
../modules/btop.nix ../modules/btop.nix
../modules/term/ghostty.nix ../modules/term/ghostty.nix
../modules/term/rio.nix ../modules/term/rio.nix
../modules/firefox.nix ../modules/firefox.nix
../modules/nixcord.nix
#../modules/hypr/hypridle.nix #../modules/hypr/hypridle.nix
../modules/hypr/hyprlock.nix ../modules/hypr/hyprlock.nix

View file

@ -4,14 +4,14 @@
... ...
}: let }: let
home-manager = builtins.fetchTarball { 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 = "0gjfa3bv0m0kymxqla9iih11gjb6czyj942v34pyc7xy4qsx898k"; sha256 = "0z94i2ig7wcm63fp1wkpp6r4458g2bj3r7ijlfapxihqybpgvng5";
}; };
in { in {
imports = [ imports = [
./hardware-configuration.nix ./hardware-configuration.nix
(import "${home-manager}/nixos") (import "${home-manager}/nixos")
inputs.spicetify-nix.nixosModules.default # inputs.spicetify-nix.nixosModules.default
../modules/steam.nix ../modules/steam.nix
../modules/obsidian.nix ../modules/obsidian.nix
@ -21,18 +21,32 @@ in {
../modules/chameleonultragui.nix ../modules/chameleonultragui.nix
]; ];
programs.spicetify = let nixpkgs.config.allowUnfreePredicate = let
spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system}; whitelist = map lib.getName [
in { pkgs.jetbrains.rider
enable = true; pkgs.obsidian
enabledExtensions = with spicePkgs.extensions; [ pkgs.gitkraken
adblock pkgs.steam
hidePodcasts pkgs.steamcmd
shuffle # shuffle+ (special characters are sanitized out of extension names) pkgs.steam-unwrapped
pkgs.spotify
pkgs.dwarf-fortress
]; ];
#theme = spicePkgs.themes.catppuccin; in
#colorScheme = "mocha"; 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 = { boot.loader = {
efi = { efi = {
@ -159,13 +173,6 @@ in {
nitch nitch
starfetch starfetch
hyprpanel
# flatpak requires gnome-software
# for graphical applications
flatpak
gnome-software
colmena-latest colmena-latest
jetbrains.rider jetbrains.rider
@ -206,8 +213,6 @@ in {
#extraSpecialArgs = {inherit inputs pkgs;}; #extraSpecialArgs = {inherit inputs pkgs;};
sharedModules = [ sharedModules = [
inputs.ags.homeManagerModules.default inputs.ags.homeManagerModules.default
inputs.nixcord.homeManagerModules.nixcord
#{nixpkgs.overlays = [inputs.hyprpanel.overlay];}
]; ];
}; };
@ -351,20 +356,24 @@ in {
# ----- FONTS ----- # ----- FONTS -----
fonts = { fonts = {
enableDefaultPackages = true; # no clue what this line does tbh enableDefaultPackages = true; # no clue what this line does tbh
packages = with pkgs; [ packages = with pkgs;
#(nerdfonts.override { [
# fonts = [ #(nerdfonts.override {
# "Cousine" # fonts = [
# "Iosevka" # "Cousine"
# "JetBrainsMono" # "Iosevka"
# ]; # "JetBrainsMono"
# }) # ];
nerdfonts # })
geist-font # for my hyprlock theme # nerdfonts
geist-font # for my hyprlock theme
# texlive maintains a noto-emoji flake # texlive maintains a noto-emoji flake
texlivePackages.noto-emoji texlivePackages.noto-emoji
]; ]
++ builtins.filter lib.attrsets.isDerivation (
builtins.attrValues pkgs.nerd-fonts
);
# TODO: change my default fonts # TODO: change my default fonts
fontconfig = { fontconfig = {

View file

@ -7,7 +7,7 @@
}: let }: let
home-manager = builtins.fetchTarball { 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-24.11.tar.gz";
sha256 = "1mwq9mzyw1al03z4q2ifbp6d0f0sx9f128xxazwrm62z0rcgv4na"; sha256 = "0z94i2ig7wcm63fp1wkpp6r4458g2bj3r7ijlfapxihqybpgvng5";
}; };
in { in {
imports = [ imports = [
@ -153,10 +153,6 @@ in {
nitch nitch
starfetch starfetch
# flatpak requires gnome-software
flatpak
gnome-software
colmena-latest colmena-latest
gitkraken gitkraken
@ -179,9 +175,7 @@ in {
home-manager = { home-manager = {
users.me = import ../../homes/me; users.me = import ../../homes/me;
sharedModules = [ sharedModules = [
inputs.nixcord.homeManagerModules.nixcord
inputs.ags.homeManagerModules.default inputs.ags.homeManagerModules.default
{nixpkgs.overlays = [inputs.hyprpanel.overlay];}
]; ];
}; };

18
huhh.sh Executable file
View file

@ -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)}'