Stop overriding taffybar flake input

This commit is contained in:
2026-05-10 21:11:29 -07:00
parent a121100271
commit 65243e8a7e
3 changed files with 159 additions and 103 deletions

View File

@@ -9,25 +9,28 @@ How the taffybar ecosystem packages are consumed by the NixOS configuration thro
See also: `taffybar-ecosystem-release` for the package dependency graph, release workflow, and Hackage publishing.
## The Three-Layer Flake Chain
## The Flake Chain
The NixOS system build pulls in taffybar through three nested flake.nix files:
The NixOS system build pulls in taffybar through the personal
`imalison-taffybar` config flake. The top-level NixOS flake should not declare
or override a direct `taffybar` input; the config flake owns its taffybar
version.
```
nixos/flake.nix (top `just switch` reads this)
── taffybar path:.../taffybar/taffybar
│ ├── imalison-taffybar path:../dotfiles/config/taffybar
│ └── gtk-sni-tray, gtk-strut, etc. (GitHub inputs)
nixos/flake.nix (top - `just switch` reads this)
── imalison-taffybar path:../dotfiles/config/taffybar
dotfiles/config/taffybar/flake.nix (middle imalison-taffybar config)
dotfiles/config/taffybar/flake.nix (middle - imalison-taffybar config)
│ ├── taffybar path:.../taffybar/taffybar
│ └── gtk-sni-tray, gtk-strut, etc. (GitHub inputs)
dotfiles/config/taffybar/taffybar/flake.nix (bottom taffybar library)
dotfiles/config/taffybar/taffybar/flake.nix (bottom - taffybar library)
│ └── gtk-sni-tray, gtk-strut, etc. (flake = false GitHub inputs)
```
All three flakes declare their own top-level inputs for the ecosystem packages and use `follows` to keep versions consistent within each layer.
The NixOS layer may make `imalison-taffybar` follow shared inputs such as
`nixpkgs`, `flake-utils`, and `xmonad`, but it should not set
`imalison-taffybar.inputs.taffybar.follows`.
## Why Bottom-Up Updates Matter
@@ -43,14 +46,14 @@ cd ~/.config/taffybar/taffybar && nix flake update <pkg>
cd ~/.config/taffybar && nix flake update <pkg> taffybar
# Top:
cd ~/dotfiles/nixos && nix flake update <pkg> imalison-taffybar taffybar
cd ~/dotfiles/nixos && nix flake update imalison-taffybar
```
Not every change requires touching all three layers. Think about which flake.lock files actually contain stale references:
- Changed **taffybar itself** — it's the bottom layer, so start at the middle (`nix flake update taffybar`) then the top.
- Changed **taffybar itself** — it's owned by the config flake, so start at the middle (`nix flake update taffybar`) then update `imalison-taffybar` at the top.
- Changed a **leaf ecosystem package** (e.g. gtk-strut) — start at the bottom since taffybar's flake.lock references it, then cascade up.
- The nixos flake also has **direct GitHub inputs** for ecosystem packages with `follows` overrides. Updating those at the top level may be sufficient if nothing changed in the middle/bottom flake.lock files themselves.
- The nixos flake can still have unrelated direct inputs such as `kanshi-sni`. Do not add a top-level `taffybar` input just to control the config flake's taffybar source.
## Rebuilding

224
nixos/flake.lock generated
View File

@@ -264,15 +264,15 @@
"flake-compat_2": {
"flake": false,
"locked": {
"lastModified": 1767039857,
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=",
"owner": "NixOS",
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"type": "github"
},
"original": {
"owner": "NixOS",
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
@@ -282,13 +282,13 @@
"locked": {
"lastModified": 1767039857,
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=",
"owner": "edolstra",
"owner": "NixOS",
"repo": "flake-compat",
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
"type": "github"
},
"original": {
"owner": "edolstra",
"owner": "NixOS",
"repo": "flake-compat",
"type": "github"
}
@@ -296,11 +296,11 @@
"flake-compat_4": {
"flake": false,
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"lastModified": 1767039857,
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
"type": "github"
},
"original": {
@@ -431,6 +431,24 @@
"type": "github"
}
},
"flake-utils_2": {
"inputs": {
"systems": "systems_2"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"git-blame-rank": {
"inputs": {
"fenix": "fenix",
@@ -570,6 +588,7 @@
"gitignore_2": {
"inputs": {
"nixpkgs": [
"imalison-taffybar",
"taffybar",
"weeder-nix",
"pre-commit-hooks",
@@ -635,7 +654,7 @@
"hercules-ci-effects_2": {
"inputs": {
"flake-parts": "flake-parts_5",
"nixpkgs": "nixpkgs_5"
"nixpkgs": "nixpkgs_6"
},
"locked": {
"lastModified": 1701009247,
@@ -1135,9 +1154,7 @@
"nixpkgs": [
"nixpkgs"
],
"taffybar": [
"taffybar"
],
"taffybar": "taffybar",
"xmonad": [
"xmonad"
]
@@ -1218,10 +1235,10 @@
},
"nix": {
"inputs": {
"flake-compat": "flake-compat_2",
"flake-compat": "flake-compat_3",
"flake-parts": "flake-parts",
"git-hooks-nix": "git-hooks-nix",
"nixpkgs": "nixpkgs_3",
"nixpkgs": "nixpkgs_4",
"nixpkgs-23-11": "nixpkgs-23-11",
"nixpkgs-regression": "nixpkgs-regression"
},
@@ -1278,7 +1295,7 @@
},
"nixos-wsl": {
"inputs": {
"flake-compat": "flake-compat_3",
"flake-compat": "flake-compat_4",
"nixpkgs": [
"nixpkgs"
]
@@ -1396,6 +1413,22 @@
}
},
"nixpkgs_3": {
"locked": {
"lastModified": 1776877367,
"narHash": "sha256-EHq1/OX139R1RvBzOJ0aMRT3xnWyqtHBRUBuO1gFzjI=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "0726a0ecb6d4e08f6adced58726b95db924cef57",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_4": {
"locked": {
"lastModified": 1771903837,
"narHash": "sha256-jEA8WggGKtMFeNeCKq3NK8cLEjJmG6/RLUElYYbBZ0E=",
@@ -1408,7 +1441,7 @@
"url": "https://channels.nixos.org/nixos-25.11/nixexprs.tar.xz"
}
},
"nixpkgs_4": {
"nixpkgs_5": {
"locked": {
"lastModified": 1777954456,
"narHash": "sha256-hGdgeU2Nk87RAuZyYjyDjFL6LK7dAZN5RE9+hrDTkDU=",
@@ -1424,7 +1457,7 @@
"type": "github"
}
},
"nixpkgs_5": {
"nixpkgs_6": {
"locked": {
"lastModified": 1697723726,
"narHash": "sha256-SaTWPkI8a5xSHX/rrKzUe+/uVNy6zCGMXgoeMb7T9rg=",
@@ -1440,7 +1473,7 @@
"type": "github"
}
},
"nixpkgs_6": {
"nixpkgs_7": {
"locked": {
"lastModified": 1703255338,
"narHash": "sha256-Z6wfYJQKmDN9xciTwU3cOiOk+NElxdZwy/FiHctCzjU=",
@@ -1456,27 +1489,11 @@
"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"
}
},
"nixtheplanet": {
"inputs": {
"flake-parts": "flake-parts_4",
"hercules-ci-effects": "hercules-ci-effects_2",
"nixpkgs": "nixpkgs_6",
"nixpkgs": "nixpkgs_7",
"osx-kvm": "osx-kvm"
},
"locked": {
@@ -1639,9 +1656,12 @@
},
"pre-commit-hooks_2": {
"inputs": {
"flake-compat": "flake-compat_4",
"flake-compat": "flake-compat_2",
"gitignore": "gitignore_2",
"nixpkgs": "nixpkgs_7"
"nixpkgs": [
"imalison-taffybar",
"nixpkgs"
]
},
"locked": {
"lastModified": 1747372754,
@@ -1709,16 +1729,15 @@
"nixified-ai": "nixified-ai",
"nixos-hardware": "nixos-hardware",
"nixos-wsl": "nixos-wsl",
"nixpkgs": "nixpkgs_4",
"nixpkgs": "nixpkgs_5",
"nixtheplanet": "nixtheplanet",
"notifications-tray-icon": "notifications-tray-icon",
"org-agenda-api": "org-agenda-api",
"railbird-secrets": "railbird-secrets",
"systems": "systems_2",
"taffybar": "taffybar",
"systems": "systems_3",
"vscode-server": "vscode-server",
"xmonad": "xmonad",
"xmonad-contrib": "xmonad-contrib",
"xmonad": "xmonad_2",
"xmonad-contrib": "xmonad-contrib_2",
"xmonad-river": "xmonad-river"
}
},
@@ -1806,31 +1825,41 @@
"type": "github"
}
},
"taffybar": {
"inputs": {
"flake-utils": [
"flake-utils"
],
"nixpkgs": [
"nixpkgs"
],
"weeder-nix": "weeder-nix",
"xmonad": [
"xmonad"
],
"xmonad-contrib": [
"xmonad-contrib"
]
},
"systems_3": {
"locked": {
"lastModified": 1778446660,
"narHash": "sha256-uV4Lb74wvSwoTU1u/fg4xcUZ60yK2G+b2lTL6O0bKAU=",
"path": "/home/imalison/dotfiles/dotfiles/config/taffybar/taffybar",
"type": "path"
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"path": "/home/imalison/dotfiles/dotfiles/config/taffybar/taffybar",
"type": "path"
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"taffybar": {
"inputs": {
"flake-utils": "flake-utils_2",
"nixpkgs": "nixpkgs_3",
"weeder-nix": "weeder-nix",
"xmonad": "xmonad",
"xmonad-contrib": "xmonad-contrib"
},
"locked": {
"lastModified": 1778446663,
"narHash": "sha256-xHKRrar08yPsOVbPG7DlouKU83r8P0WAwoxUuje3kq0=",
"owner": "taffybar",
"repo": "taffybar",
"rev": "2c95fd5a8aa125d0ba89873a7d4dfd49bb57b00c",
"type": "github"
},
"original": {
"owner": "taffybar",
"repo": "taffybar",
"type": "github"
}
},
"vscode-server": {
@@ -1859,6 +1888,7 @@
"weeder-nix": {
"inputs": {
"nixpkgs": [
"imalison-taffybar",
"taffybar",
"nixpkgs"
],
@@ -1920,20 +1950,7 @@
}
},
"xmonad": {
"inputs": {
"flake-utils": [
"flake-utils"
],
"git-ignore-nix": [
"git-ignore-nix"
],
"nixpkgs": [
"nixpkgs"
],
"unstable": [
"nixpkgs"
]
},
"flake": false,
"locked": {
"lastModified": 1776502138,
"narHash": "sha256-mSOpNU1iJvfFh5uwayA6aPxneFMduNW1kG1gV2tGE+c=",
@@ -1944,11 +1961,29 @@
},
"original": {
"owner": "xmonad",
"ref": "master",
"repo": "xmonad",
"type": "github"
}
},
"xmonad-contrib": {
"flake": false,
"locked": {
"lastModified": 1769258911,
"narHash": "sha256-YGEKXs4UmS5QOIELJTdCiMzTktuue+Bd3yFoIKSHuBU=",
"owner": "xmonad",
"repo": "xmonad-contrib",
"rev": "803bc3d12bdcc512ec06856c4f119d37de1ba338",
"type": "github"
},
"original": {
"owner": "xmonad",
"ref": "master",
"repo": "xmonad-contrib",
"type": "github"
}
},
"xmonad-contrib_2": {
"inputs": {
"flake-utils": [
"flake-utils"
@@ -2007,6 +2042,35 @@
"repo": "xmonad",
"type": "github"
}
},
"xmonad_2": {
"inputs": {
"flake-utils": [
"flake-utils"
],
"git-ignore-nix": [
"git-ignore-nix"
],
"nixpkgs": [
"nixpkgs"
],
"unstable": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1776502138,
"narHash": "sha256-mSOpNU1iJvfFh5uwayA6aPxneFMduNW1kG1gV2tGE+c=",
"owner": "xmonad",
"repo": "xmonad",
"rev": "a618fb32662e44eb5d8276a3dc1925b0233e638b",
"type": "github"
},
"original": {
"owner": "xmonad",
"repo": "xmonad",
"type": "github"
}
}
},
"root": "root",

View File

@@ -172,21 +172,10 @@
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
taffybar.follows = "taffybar";
xmonad.follows = "xmonad";
};
};
taffybar = {
url = "path:/home/imalison/dotfiles/dotfiles/config/taffybar/taffybar";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
xmonad.follows = "xmonad";
xmonad-contrib.follows = "xmonad-contrib";
};
};
notifications-tray-icon = {
url = "github:colonelpanic8/notifications-tray-icon";
inputs = {