diff --git a/modules/packages/desktop.nix b/modules/packages/desktop.nix index 37d2f23a..7556cf57 100644 --- a/modules/packages/desktop.nix +++ b/modules/packages/desktop.nix @@ -33,7 +33,7 @@ inputs: waifu2x-converter-cpp blender paraview vlc whalebird spotify obs-studio subtitlecomposer (inkscape-with-extensions.override { inkscapeExtensions = null; }) # development - adb-sync scrcpy dbeaver-bin cling aircrack-ng + adb-sync scrcpy dbeaver-bin cling aircrack-ng kitty weston cage openbox krita fprettify # jetbrains.clion # password and key management yubikey-manager bitwarden hashcat yubikey-personalization @@ -71,7 +71,9 @@ inputs: activitywatch super-productivity ] ++ (builtins.filter (p: !((p.meta.broken or false) || (builtins.elem p.pname or null [ "falkon" "kalzium" ]))) - (builtins.filter inputs.lib.isDerivation (builtins.attrValues kdePackages.kdeGear))); + (builtins.filter inputs.lib.isDerivation (builtins.attrValues kdePackages.kdeGear))) + ++ (inputs.lib.optionals (inputs.config.nixos.system.gui.implementation == "kde") + [ inputs.topInputs.plasma-manager.packages.${inputs.pkgs.system}.rc2nix ]); _pythonPackages = [(pythonPackages: with pythonPackages; [ phonopy scipy scikit-learn jupyterlab autograd inputs.pkgs.localPackages.phono3py numpy ])]; }; diff --git a/modules/packages/minimal.nix b/modules/packages/minimal.nix index c5cd157d..996522b8 100644 --- a/modules/packages/minimal.nix +++ b/modules/packages/minimal.nix @@ -10,7 +10,7 @@ inputs: [ # basic tools beep dos2unix gnugrep pv tmux screen parallel tldr cowsay jq yq ipfetch localPackages.pslist - fastfetch reptyr duc ncdu progress libva-utils ksh neofetch dateutils kitty glib + fastfetch reptyr duc ncdu progress libva-utils ksh neofetch dateutils glib # lsxx pciutils usbutils lshw util-linux lsof dmidecode lm_sensors hwloc acpica-tools ethtool # top @@ -43,32 +43,8 @@ inputs: (octodns.withProviders (_: with octodns-providers; [ cloudflare ])) # stupid things toilet lolcat localPackages.stickerpicker graph-easy - # office - pdfgrep ffmpeg-full hdf5 - # scientific computing - (if inputs.config.nixos.system.nixpkgs.cuda != null then localPackages.mumax else emptyDirectory) - (if inputs.config.nixos.system.nixpkgs.cuda != null - then (lammps.override { stdenv = cudaPackages.backendStdenv; }).overrideAttrs (prev: - { - cmakeFlags = prev.cmakeFlags ++ - [ "-DPKG_GPU=on" "-DGPU_API=cuda" "-DCMAKE_POLICY_DEFAULT_CMP0146=OLD" ]; - nativeBuildInputs = prev.nativeBuildInputs ++ [ cudaPackages.cudatoolkit ]; - buildInputs = prev.buildInputs ++ [ mpi ]; - }) - else lammps-mpi) ] - ++ (with inputs.config.boot.kernelPackages; [ cpupower usbip ]) - ++ (inputs.lib.optionals (inputs.config.nixos.system.gui.implementation == "kde") - [ inputs.topInputs.plasma-manager.packages.${inputs.pkgs.system}.rc2nix ]); - _pythonPackages = [(pythonPackages: with pythonPackages; - [ - openai python-telegram-bot fastapi-cli pypdf2 pandas matplotlib plotly gunicorn redis jinja2 certifi - charset-normalizer idna orjson psycopg2 inquirerpy requests tqdm pydbus inputs.pkgs.localPackages.brokenaxes - # allow pandas read odf - odfpy - # for vasp plot-workfunc.py - ase - ])]; + ++ (with inputs.config.boot.kernelPackages; [ cpupower usbip ]); }; programs = { diff --git a/modules/packages/server.nix b/modules/packages/server.nix new file mode 100644 index 00000000..7c2bef03 --- /dev/null +++ b/modules/packages/server.nix @@ -0,0 +1,39 @@ +inputs: +{ + options.nixos.packages.server = let inherit (inputs.lib) mkOption types; in mkOption + { + type = types.nullOr (types.submodule {}); + default = if builtins.elem inputs.config.nixos.model.type [ "server" "desktop" ] then {} else null; + }; + config = let inherit (inputs.config.nixos.packages) server; in inputs.lib.mkIf (server != null) + { + nixos.packages.packages = + { + _packages = with inputs.pkgs; + [ + # office + pdfgrep ffmpeg-full hdf5 + # scientific computing + (if inputs.config.nixos.system.nixpkgs.cuda != null then localPackages.mumax else emptyDirectory) + (if inputs.config.nixos.system.nixpkgs.cuda != null + then (lammps.override { stdenv = cudaPackages.backendStdenv; }).overrideAttrs (prev: + { + cmakeFlags = prev.cmakeFlags ++ + [ "-DPKG_GPU=on" "-DGPU_API=cuda" "-DCMAKE_POLICY_DEFAULT_CMP0146=OLD" ]; + nativeBuildInputs = prev.nativeBuildInputs ++ [ cudaPackages.cudatoolkit ]; + buildInputs = prev.buildInputs ++ [ mpi ]; + }) + else lammps-mpi) + ]; + _pythonPackages = [(pythonPackages: with pythonPackages; + [ + openai python-telegram-bot fastapi-cli pypdf2 pandas matplotlib plotly gunicorn redis jinja2 certifi + charset-normalizer idna orjson psycopg2 inquirerpy requests tqdm pydbus inputs.pkgs.localPackages.brokenaxes + # allow pandas read odf + odfpy + # for vasp plot-workfunc.py + ase + ])]; + }; + }; +}