Compare commits

...

1 Commits

Author SHA1 Message Date
5ee328cdf8 refactor(flake): centralize custom packages 2026-10-12 11:34:18 -04:00
7 changed files with 67 additions and 34 deletions

View File

@@ -30,32 +30,7 @@ in
home-manager.users.${config.user.name}.programs.waybar = {
enable = true;
# Waybar 0.15.0 sends old Hyprland workspace dispatch commands.
# Use the fix commit until a release includes upstream PR #5013.
package = pkgs.waybar.overrideAttrs {
src = pkgs.fetchFromGitHub {
owner = "Alexays";
repo = "Waybar";
rev = "05945748dccce28bf96d26d8f64a9e69a8dd49ba";
hash = "sha256-51R3mIt8cLNvh/X5qe9vOqeJCj0U9KRyemVE5y+OhiU=";
};
postUnpack =
let
libcava = pkgs.fetchFromGitHub {
owner = "LukashonakV";
repo = "cava";
tag = "0.10.7";
hash = "sha256-zkyj1vBzHtoypX4Bxdh1Vmwh967DKKxN751v79hzmgQ=";
};
in
''
pushd "$sourceRoot"
cp -R --no-preserve=mode,ownership ${libcava} subprojects/cava-0.10.7
patchShebangs .
popd
'';
};
package = pkgs.alexion.waybar;
# A user service bound to graphical-session.target, which uwsm activates,
# so the bar comes up with the session and no compositor exec-once.

View File

@@ -12,18 +12,14 @@ let
piDir = "${config.users.users.${user}.home}/.pi/agent";
in
{
options.modules.shell.pi = {
enable = lib.mkEnableOption "Pi, a terminal coding agent, configured through home-manager";
};
options.modules.shell.pi.enable =
lib.mkEnableOption "Pi, a terminal coding agent, configured through home-manager";
config = lib.mkIf config.modules.shell.pi.enable {
home-manager.users.${user} = {
programs.pi-coding-agent = {
enable = true;
package = pkgs.pi-coding-agent.overrideAttrs {
src = ../../../../../third_party/pi;
patches = [ ];
};
package = pkgs.alexion.pi-coding-agent;
settings = {
defaultProvider = "openai-codex";

View File

@@ -33,7 +33,12 @@ let
repositoryModules = modules;
root = root + "/guests";
};
modules.imports = util.collectNixFiles (root + "/modules");
modules.imports = [
{
nixpkgs.overlays = [ self.overlays.custom ];
}
]
++ util.collectNixFiles (root + "/modules");
in
import ./hosts.nix {

View File

@@ -6,6 +6,19 @@
system,
}:
{
overlays.custom = final: _prev: {
alexion = import ./packages {
pkgs = final;
inherit root;
};
};
packages.${system} =
(import inputs.nixpkgs {
inherit system;
overlays = [ self.overlays.custom ];
}).alexion;
nixosConfigurations = import ../dotfiles {
inherit
inputs

View File

@@ -0,0 +1,8 @@
{ pkgs, root }:
{
pi-coding-agent = pkgs.callPackage ./pi-coding-agent.nix {
inherit root;
};
waybar = pkgs.callPackage ./waybar.nix { };
}

View File

@@ -0,0 +1,8 @@
{
pi-coding-agent,
root,
}:
pi-coding-agent.overrideAttrs {
src = root + "/third_party/pi";
patches = [ ];
}

View File

@@ -0,0 +1,28 @@
{
fetchFromGitHub,
waybar,
}:
waybar.overrideAttrs {
src = fetchFromGitHub {
owner = "Alexays";
repo = "Waybar";
rev = "05945748dccce28bf96d26d8f64a9e69a8dd49ba";
hash = "sha256-51R3mIt8cLNvh/X5qe9vOqeJCj0U9KRyemVE5y+OhiU=";
};
postUnpack =
let
libcava = fetchFromGitHub {
owner = "LukashonakV";
repo = "cava";
tag = "0.10.7";
hash = "sha256-zkyj1vBzHtoypX4Bxdh1Vmwh967DKKxN751v79hzmgQ=";
};
in
''
pushd "$sourceRoot"
cp -R --no-preserve=mode,ownership ${libcava} subprojects/cava-0.10.7
patchShebangs .
popd
'';
}