diff --git a/configs/fedora/home.nix b/configs/fedora/home.nix index 8b8a7e7..15b25d6 100644 --- a/configs/fedora/home.nix +++ b/configs/fedora/home.nix @@ -10,7 +10,7 @@ in { isGeneric = true; isGnome = false; noiseSuppression.enable = false; - isGraphical = false; + isGraphical = true; }; fonts.fontconfig.enable = true; @@ -18,9 +18,4 @@ in { nixpkgs.config.allowUnfree = true; nixGLPrefix = lib.getExe pkgs.nixgl.nixGLIntel; - - home.packages = with pkgs; [ - (nixGL insomnia) - (nixGL inputs.muse-sounds-manager.packages.x86_64-linux.muse-sounds-manager) - ]; } diff --git a/home-manager/modules/machine.nix b/home-manager/modules/machine.nix index 0083974..0e11133 100644 --- a/home-manager/modules/machine.nix +++ b/home-manager/modules/machine.nix @@ -126,16 +126,6 @@ with lib; { ${pkgs.nodejs}/bin/npm config set prefix ${config.home.homeDirectory}/.node-global ''; }; - } // mkIf (config.machine.isGeneric && config.machine.isGraphical) { - linkDesktopApplications = { - after = [ "writeBoundary" "createXdgUserDirectories" ]; - before = [ ]; - data = '' - for dir in ${config.home.homeDirectory}/.nix-profile/share/applications/*; do - chmod +x $(realpath $dir) -v - done - ''; - }; }; sessionPath = [ "${config.home.homeDirectory}/.node-global/bin" ]; }; diff --git a/home-manager/modules/packages.nix b/home-manager/modules/packages.nix index 9098b60..5989800 100644 --- a/home-manager/modules/packages.nix +++ b/home-manager/modules/packages.nix @@ -2,9 +2,11 @@ with lib; let + nixGL = import ./../../home-manager/utils/nixGLWrap.nix { inherit pkgs config; }; electronFlags = "--enable-features=UseOzonePlatform --ozone-platform=wayland --enable-wayland-ime --disable-gpu-shader-disk-cache -n"; -in { +in +{ config = { nixpkgs.overlays = [ (_: prev: { @@ -76,60 +78,70 @@ in { nix-output-monitor nodePackages.pnpm npm-check-updates - ] ++ (if config.machine.isGraphical then [ - corefonts - vistafonts - jetbrains.webstorm - jetbrains.phpstorm - jetbrains.rust-rover - jetbrains.goland - element-desktop - ludusavi - dbeaver - insomnia - onlyoffice-bin - spotify - vesktop - (lutris.override { - extraLibraries = _: [ gnome3.adwaita-icon-theme ]; - extraPkgs = _: [ - wineWowPackages.full - winetricks - gnome3.adwaita-icon-theme - ]; - }) - bottles - protontricks - heroic - (vscode.override { commandLineArgs = electronFlags; }) - quickemu - quickgui - trilium-desktop - anki - inputs.muse-sounds-manager.packages.x86_64-linux.muse-sounds-manager - jetbrains-toolbox - mumble - prusa-slicer - trayscale - gnome.gnome-disk-utility - inkscape - musescore - obsidian - syncthingtray - reaper - yabridge - inputs.suyu.packages.x86_64-linux.suyu - inputs.nix-alien.packages.x86_64-linux.nix-alien - kdePackages.kdenlive - audacity - ] else - [ ]) ++ (if config.machine.isGnome then [ - gnomeExtensions.blur-my-shell - gnomeExtensions.dash-to-panel - gnomeExtensions.user-themes - gnomeExtensions.vitals - gnomeExtensions.custom-accent-colors + ] ++ ( + if ( + config.machine.isGraphical + ) then [ + (nixGL insomnia) ] else - [ ]); + [ ] + ) ++ ( + if ( + config.machine.isGraphical && !config.machine.isGeneric + ) then [ + corefonts + vistafonts + jetbrains.webstorm + jetbrains.phpstorm + jetbrains.rust-rover + jetbrains.goland + element-desktop + ludusavi + dbeaver + onlyoffice-bin + spotify + vesktop + (lutris.override { + extraLibraries = _: [ gnome3.adwaita-icon-theme ]; + extraPkgs = _: [ + wineWowPackages.full + winetricks + gnome3.adwaita-icon-theme + ]; + }) + bottles + protontricks + heroic + (vscode.override { commandLineArgs = electronFlags; }) + quickemu + quickgui + trilium-desktop + anki + # inputs.muse-sounds-manager.packages.x86_64-linux.muse-sounds-manager + jetbrains-toolbox + mumble + prusa-slicer + trayscale + gnome.gnome-disk-utility + inkscape + musescore + obsidian + syncthingtray + reaper + yabridge + inputs.suyu.packages.x86_64-linux.suyu + inputs.nix-alien.packages.x86_64-linux.nix-alien + kdePackages.kdenlive + audacity + ] else + [ ] + ) ++ (if config.machine.isGnome then [ + gnomeExtensions.blur-my-shell + gnomeExtensions.dash-to-panel + gnomeExtensions.user-themes + gnomeExtensions.vitals + gnomeExtensions.custom-accent-colors + ] else + [ ]); }; } diff --git a/home-manager/programs/alacritty.nix b/home-manager/programs/alacritty.nix index 2f8a30f..64d4fcf 100644 --- a/home-manager/programs/alacritty.nix +++ b/home-manager/programs/alacritty.nix @@ -1,8 +1,11 @@ { config, pkgs, lib, ... }: -{ +let + nixGL = import ./../../home-manager/utils/nixGLWrap.nix { inherit pkgs config; }; +in { programs.alacritty = { enable = if config.machine.isGraphical then true else false; + package = (nixGL pkgs.alacritty); settings = { window = { decorations = "full"; diff --git a/home-manager/programs/chromium.nix b/home-manager/programs/chromium.nix index 00ef453..5a8f6d8 100644 --- a/home-manager/programs/chromium.nix +++ b/home-manager/programs/chromium.nix @@ -19,7 +19,7 @@ let "bmnlcjabgnpnenekpadlanbbkooimhnj" # Honey "kbfnbcaeplbcioakkpcpgfkobkghlhen" # Grammarly ]; - isEnabled = if config.machine.isGraphical then true else false; + isEnabled = if (config.machine.isGraphical && !config.machine.isGeneric) then true else false; dictionaries = with pkgs.hunspellDictsChromium; [ en_US de_DE ]; commandLineArgs = [ "--enable-wayland-ime" diff --git a/home-manager/programs/firefox.nix b/home-manager/programs/firefox.nix index ef4e59c..06ffc31 100644 --- a/home-manager/programs/firefox.nix +++ b/home-manager/programs/firefox.nix @@ -2,6 +2,6 @@ { programs.firefox = { - enable = if config.machine.isGraphical then true else false; + enable = if (config.machine.isGraphical && !config.machine.isGeneric) then true else false; }; } diff --git a/home-manager/programs/mpv.nix b/home-manager/programs/mpv.nix index fc5b54a..c286a52 100644 --- a/home-manager/programs/mpv.nix +++ b/home-manager/programs/mpv.nix @@ -2,7 +2,7 @@ { programs.mpv = { - enable = if config.machine.isGraphical then true else false; + enable = if (config.machine.isGraphical && !config.machine.isGeneric) then true else false; scripts = with pkgs.mpvScripts; [ autoload mpris sponsorblock ]; }; }