check_updates now in scripts, removed redundant pkgs argument passage in overlay.nix
This commit is contained in:
@@ -31,7 +31,7 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
Service = {
|
Service = {
|
||||||
ExecStart = "${pkgs.nix}/bin/nix-shell -p python3Packages.requests --run '${pkgs.python311}/bin/python ${pkgs.myPkgs.check_updates}/bin/checkupdates.py'";
|
ExecStart = "${pkgs.nix}/bin/nix-shell -p python3Packages.requests --run '${pkgs.python311}/bin/python ${pkgs.myScripts.check_updates}/bin/checkupdates.py'";
|
||||||
Type = "simple";
|
Type = "simple";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -4,28 +4,28 @@
|
|||||||
# Packages that I've made
|
# Packages that I've made
|
||||||
tinyfetch = super.callPackage ./tinyfetch/package.nix {};
|
tinyfetch = super.callPackage ./tinyfetch/package.nix {};
|
||||||
breezex-cursor = super.callPackage ./breezex-cursor/package.nix {};
|
breezex-cursor = super.callPackage ./breezex-cursor/package.nix {};
|
||||||
check_updates = super.callPackage ./check_updates/package.nix {};
|
|
||||||
};
|
};
|
||||||
myScripts = {
|
myScripts = {
|
||||||
# Scripts written using pkgs.writeShellApplication
|
# Scripts written using pkgs.writeShellApplication
|
||||||
icanhazip = super.callPackage ./scripts/commands/icanhazip.nix { pkgs = super; };
|
icanhazip = super.callPackage ./scripts/commands/icanhazip.nix {};
|
||||||
invoke = super.callPackage ./scripts/commands/invoke.nix { pkgs = super; self = root; };
|
invoke = super.callPackage ./scripts/commands/invoke.nix { self = root; };
|
||||||
git-compose = super.callPackage ./scripts/commands/git-compose.nix { pkgs = super; };
|
git-compose = super.callPackage ./scripts/commands/git-compose.nix {};
|
||||||
runbg = super.callPackage ./scripts/commands/runbg.nix { pkgs = super; };
|
runbg = super.callPackage ./scripts/commands/runbg.nix {};
|
||||||
splash = super.callPackage ./scripts/commands/splash.nix { pkgs = super; };
|
splash = super.callPackage ./scripts/commands/splash.nix {};
|
||||||
toolbelt = super.callPackage ./scripts/commands/toolbelt.nix { pkgs = super; };
|
toolbelt = super.callPackage ./scripts/commands/toolbelt.nix {};
|
||||||
viconf = super.callPackage ./scripts/commands/viconf.nix { pkgs = super; };
|
viconf = super.callPackage ./scripts/commands/viconf.nix {};
|
||||||
vipkg = super.callPackage ./scripts/commands/vipkg.nix { pkgs = super; };
|
vipkg = super.callPackage ./scripts/commands/vipkg.nix {};
|
||||||
fetchfromgh = super.callPackage ./scripts/nix/fetchfromgh.nix { pkgs = super; };
|
fetchfromgh = super.callPackage ./scripts/nix/fetchfromgh.nix {};
|
||||||
garbage-collect = super.callPackage ./scripts/nix/garbage-collect.nix { pkgs = super; };
|
garbage-collect = super.callPackage ./scripts/nix/garbage-collect.nix {};
|
||||||
nsp = super.callPackage ./scripts/nix/nsp.nix { pkgs = super; };
|
check_updates = super.callPackage ./scripts/nix/check_updates.nix {};
|
||||||
rebuild = super.callPackage ./scripts/nix/rebuild.nix { inherit host; self = root; pkgs = super; };
|
nsp = super.callPackage ./scripts/nix/nsp.nix {};
|
||||||
chpaper = super.callPackage ./scripts/wm-controls/chpaper.nix { pkgs = super; };
|
rebuild = super.callPackage ./scripts/nix/rebuild.nix { inherit host; self = root; };
|
||||||
chscheme = super.callPackage ./scripts/wm-controls/chscheme.nix { pkgs = super; };
|
chpaper = super.callPackage ./scripts/wm-controls/chpaper.nix {};
|
||||||
keyring = super.callPackage ./scripts/wm-controls/keyring.nix { pkgs = super; };
|
chscheme = super.callPackage ./scripts/wm-controls/chscheme.nix {};
|
||||||
mkscreenshots = super.callPackage ./scripts/wm-controls/mkscreenshots.nix { pkgs = super; };
|
keyring = super.callPackage ./scripts/wm-controls/keyring.nix {};
|
||||||
moveonscreen = super.callPackage ./scripts/wm-controls/moveonscreen.nix { pkgs = super; };
|
mkscreenshots = super.callPackage ./scripts/wm-controls/mkscreenshots.nix {};
|
||||||
s_check = super.callPackage ./scripts/wm-controls/s_check.nix { pkgs = super; };
|
moveonscreen = super.callPackage ./scripts/wm-controls/moveonscreen.nix {};
|
||||||
switchmon = super.callPackage ./scripts/wm-controls/switchmon.nix { pkgs = super; };
|
s_check = super.callPackage ./scripts/wm-controls/s_check.nix {};
|
||||||
|
switchmon = super.callPackage ./scripts/wm-controls/switchmon.nix {};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,97 +0,0 @@
|
|||||||
{ host, lib, config, self, pkgs, ... }:
|
|
||||||
let
|
|
||||||
fetchfromgh = import ./nix/fetchfromgh.nix { inherit pkgs; };
|
|
||||||
vipkg = import ./commands/vipkg.nix { inherit pkgs; };
|
|
||||||
keyring = import ./wm-controls/keyring.nix { inherit pkgs; };
|
|
||||||
invoke = import ./commands/invoke.nix { inherit pkgs; };
|
|
||||||
splash = import ./commands/splash.nix { inherit pkgs; };
|
|
||||||
runbg = import ./commands/runbg.nix { inherit pkgs; };
|
|
||||||
icanhazip = import ./commands/icanhazip.nix { inherit pkgs; };
|
|
||||||
garbage-collect = import ./nix/garbage-collect.nix { inherit pkgs; };
|
|
||||||
nsp = import ./nix/nsp.nix { inherit pkgs; };
|
|
||||||
scheck = import ./wm-controls/s_check.nix { inherit pkgs; };
|
|
||||||
switchmon = import ./wm-controls/switchmon.nix { inherit pkgs; };
|
|
||||||
rebuild = import ./nix/rebuild.nix { inherit host self pkgs; };
|
|
||||||
moveonscreen = import ./wm-controls/moveonscreen.nix { inherit pkgs; };
|
|
||||||
toolbelt = import ./commands/toolbelt.nix { inherit pkgs; };
|
|
||||||
viconf = import ./commands/viconf.nix { inherit pkgs; };
|
|
||||||
chscheme = import ./wm-controls/chscheme.nix { inherit pkgs; };
|
|
||||||
chpaper = import ./wm-controls/chpaper.nix { inherit pkgs; };
|
|
||||||
mkscreenshots = import ./wm-controls/mkscreenshots.nix { inherit pkgs; };
|
|
||||||
scriptList = [
|
|
||||||
fetchfromgh
|
|
||||||
vipkg
|
|
||||||
keyring
|
|
||||||
invoke
|
|
||||||
splash
|
|
||||||
runbg
|
|
||||||
icanhazip
|
|
||||||
garbage-collect
|
|
||||||
nsp
|
|
||||||
scheck
|
|
||||||
switchmon
|
|
||||||
rebuild
|
|
||||||
moveonscreen
|
|
||||||
toolbelt
|
|
||||||
viconf
|
|
||||||
chscheme
|
|
||||||
chpaper
|
|
||||||
mkscreenshots
|
|
||||||
];
|
|
||||||
loadScript = scriptName:
|
|
||||||
lib.foldl' (acc: dir:
|
|
||||||
if builtins.pathExists "${dir}/${scriptName}.nix"
|
|
||||||
then acc // { inherit (import "${dir}/${scriptName}.nix" { inherit pkgs; }) scriptName; }
|
|
||||||
else acc
|
|
||||||
) {} scriptList;
|
|
||||||
in {
|
|
||||||
options = {
|
|
||||||
movOpts.enabledScripts =
|
|
||||||
};
|
|
||||||
|
|
||||||
config = lib.mkIf config.movOpts.movScripts.enable {
|
|
||||||
home.packages =
|
|
||||||
lib.optionals config.movOpts.movScripts.commandScripts.invoke.enable [
|
|
||||||
invoke
|
|
||||||
]
|
|
||||||
# Command Scripts Overrides
|
|
||||||
++ lib.optionals config.movOpts.movScripts.commandScripts.vipkg.enable
|
|
||||||
[ vipkg ]
|
|
||||||
++ lib.optionals config.movOpts.movScripts.commandScripts.runbg.enable
|
|
||||||
[ runbg ]
|
|
||||||
++ lib.optionals config.movOpts.movScripts.commandScripts.icanhazip.enable
|
|
||||||
[ icanhazip ]
|
|
||||||
++ lib.optionals config.movOpts.movScripts.commandScripts.splash.enable
|
|
||||||
[ splash ]
|
|
||||||
++ lib.optionals config.movOpts.movScripts.commandScripts.toolbelt.enable
|
|
||||||
[ toolbelt ]
|
|
||||||
++ lib.optionals config.movOpts.movScripts.commandScripts.viconf.enable [
|
|
||||||
viconf
|
|
||||||
]
|
|
||||||
|
|
||||||
# Hyprland Controls Overrides
|
|
||||||
++ lib.optionals config.movOpts.movScripts.hyprlandControls.chpaper.enable
|
|
||||||
[ chpaper ]
|
|
||||||
++ lib.optionals config.movOpts.movScripts.hyprlandControls.scheck.enable
|
|
||||||
[ scheck ] ++ lib.optionals
|
|
||||||
config.movOpts.movScripts.hyprlandControls.chscheme.enable [ chscheme ]
|
|
||||||
++ lib.optionals config.movOpts.movScripts.hyprlandControls.keyring.enable
|
|
||||||
[ keyring ] ++ lib.optionals
|
|
||||||
config.movOpts.movScripts.hyprlandControls.moveonscreen.enable
|
|
||||||
[ moveonscreen ] ++ lib.optionals
|
|
||||||
config.movOpts.movScripts.hyprlandControls.switchmon.enable [ switchmon ]
|
|
||||||
++ lib.optionals
|
|
||||||
config.movOpts.movScripts.hyprlandControls.mkscreenshots.enable [
|
|
||||||
mkscreenshots
|
|
||||||
]
|
|
||||||
|
|
||||||
# Nix Shortcuts Overrides
|
|
||||||
++ lib.optionals config.movOpts.movScripts.nixShortcuts.fetchfromgh.enable
|
|
||||||
[ fetchfromgh ] ++ lib.optionals
|
|
||||||
config.movOpts.movScripts.nixShortcuts.garbage-collect.enable
|
|
||||||
[ garbage-collect ]
|
|
||||||
++ lib.optionals config.movOpts.movScripts.nixShortcuts.nsp.enable [ nsp ]
|
|
||||||
++ lib.optionals config.movOpts.movScripts.nixShortcuts.rebuild.enable
|
|
||||||
[ rebuild ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
{ pkgs ? import <nixpkgs> { } }:
|
{ pkgs }:
|
||||||
|
|
||||||
pkgs.stdenv.mkDerivation {
|
pkgs.stdenv.mkDerivation {
|
||||||
pname = "pkg_maintenance_check";
|
pname = "pkg_maintenance_check";
|
||||||
Reference in New Issue
Block a user