Refactor Nix package definitions in flake.nix and run.nix to improve dependency handling and formatting. Changes include renaming variables for clarity, adding the download package to run.nix, and enhancing the structure of package overrides.

This commit is contained in:
Danilo Reyes
2025-11-10 12:28:47 -06:00
parent b94855afb8
commit 6efd55712d
2 changed files with 13 additions and 6 deletions

View File

@@ -31,21 +31,27 @@
{
overlays.default = _final: prev: {
python3Packages = prev.python3Packages.override {
overrides = pyself: pysuper: {
overrides = _pyself: _pysuper: {
webcomix = prev.python3Packages.callPackage ./pkgs_pr/webcomix.nix { };
download = prev.python3Packages.callPackage ./pkgs/download.nix {
webcomix = _pyself.webcomix;
};
};
};
download = _final.python3Packages.download;
};
packages.x86_64-linux =
let
scriptBin = path: name: pkgs.writeScriptBin name (builtins.readFile path);
pkgsBin = path: _name:
pkgsBin =
path: _name:
let
content = builtins.readFile path;
in
if builtins.match ".*(buildPythonPackage|buildPythonApplication).*" content != null
then pkgs.python3Packages.callPackage path { }
else pkgs.callPackage path { };
if builtins.match ".*(buildPythonPackage|buildPythonApplication).*" content != null then
pkgs.python3Packages.callPackage path { }
else
pkgs.callPackage path { };
in
{
citra = pkgs.callPackage ./pkgs/citra/default.nix { branch = "nightly"; };

View File

@@ -7,7 +7,7 @@
xclip,
ghostty,
rmlint,
callPackage,
download,
...
}:
writeShellApplication {
@@ -21,6 +21,7 @@ writeShellApplication {
xclip
ghostty
rmlint
download
];
text = builtins.readFile ../src/packaged_scripts/run.sh;