Add exclude_packages to allow modifying default install

This commit is contained in:
Henry Sipp
2025-07-24 20:42:02 -05:00
parent b83efbcf18
commit e22477bb58
4 changed files with 35 additions and 28 deletions
+5
View File
@@ -63,5 +63,10 @@ lib: {
"SUPER, slash, exec, $passwordManager" "SUPER, slash, exec, $passwordManager"
]; ];
}; };
exclude_packages = lib.mkOption {
type = lib.types.listOf lib.types.package;
default = [];
description = "Packages to exclude from the default system packages";
};
}; };
} }
+2 -1
View File
@@ -1,9 +1,10 @@
inputs: { inputs: {
config, config,
pkgs, pkgs,
lib,
... ...
}: let }: let
packages = import ../packages.nix {inherit pkgs;}; packages = import ../packages.nix {inherit pkgs lib; exclude_packages = config.omarchy.exclude_packages;};
themes = import ../themes.nix; themes = import ../themes.nix;
selectedTheme = themes.${config.omarchy.theme}; selectedTheme = themes.${config.omarchy.theme};
+2 -1
View File
@@ -1,10 +1,11 @@
{ {
config, config,
pkgs, pkgs,
lib,
... ...
}: let }: let
cfg = config.omarchy; cfg = config.omarchy;
packages = import ../packages.nix {inherit pkgs;}; packages = import ../packages.nix {inherit pkgs lib; exclude_packages = cfg.exclude_packages;};
in { in {
security.rtkit.enable = true; security.rtkit.enable = true;
services.pulseaudio.enable = false; services.pulseaudio.enable = false;
+26 -26
View File
@@ -1,26 +1,27 @@
{pkgs}: { {pkgs, lib, exclude_packages ? []}:
# Regular packages let
systemPackages = with pkgs; [ # Essential Hyprland packages - cannot be excluded
# Base system tools hyprlandPackages = with pkgs; [
git
vim
libnotify
pavucontrol
brightnessctl
ffmpeg
nautilus
hyprshot hyprshot
hyprpicker hyprpicker
hyprsunset hyprsunset
alejandra brightnessctl
pamixer pamixer
playerctl playerctl
bibata-cursors bibata-cursors
gnome-themes-extra gnome-themes-extra
pavucontrol
];
# Essential system packages - cannot be excluded
systemPackages = with pkgs; [
git
vim
libnotify
nautilus
alejandra
blueberry blueberry
clipse clipse
# Shell tools
fzf fzf
zoxide zoxide
ripgrep ripgrep
@@ -30,7 +31,10 @@
unzip unzip
wget wget
gnumake gnumake
];
# Discretionary packages - can be excluded by user
discretionaryPackages = with pkgs; [
# TUIs # TUIs
lazygit lazygit
lazydocker lazydocker
@@ -42,23 +46,12 @@
chromium chromium
obsidian obsidian
vlc vlc
# Can't find this in nixpkgs!
# Might have to make it ourselves
# asdcontrol
# Don't want these right now
# obs-studio
# kdePackages.kdenLive
# pinta
# libreoffice
signal-desktop signal-desktop
# Commercial GUIs # Commercial GUIs
typora typora
dropbox dropbox
spotify spotify
# zoom
# Development tools # Development tools
github-desktop github-desktop
@@ -66,9 +59,16 @@
# Containers # Containers
docker-compose docker-compose
# podman-compose ffmpeg
]; ];
# Only allow excluding discretionary packages to prevent breaking the system
filteredDiscretionaryPackages = lib.lists.subtractLists exclude_packages discretionaryPackages;
allSystemPackages = hyprlandPackages ++ systemPackages ++ filteredDiscretionaryPackages;
in {
# Regular packages
systemPackages = allSystemPackages;
homePackages = with pkgs; [ homePackages = with pkgs; [
]; ];
} }