Structural changes

This commit is contained in:
David C
2023-05-15 20:04:36 -04:00
parent 4d3a16a2d4
commit 291db5d45b
14 changed files with 269 additions and 698 deletions

1
programs/.#terminal.nix Symbolic link
View File

@@ -0,0 +1 @@
universe@universedesktop.1343137805946690560

90
programs/art.nix Normal file
View File

@@ -0,0 +1,90 @@
{ lib, config, pkgs, ... }: let
py3 = pkgs.python3;
py3Pkgs = py3.pkgs;
equation = py3Pkgs.buildPythonPackage {
pname = "Equation";
version = "1.2.01";
nativeBuildInputs = [
py3Pkgs.setuptools
py3Pkgs.numpy
];
src = pkgs.fetchzip {
url = "https://files.pythonhosted.org/packages/2e/cc/115fb1722051f99b9699864586e7f96ca0080645387698af922fade4f7b2/Equation-1.2.01.zip";
sha256 = "YFxZB3vaC5s49K1AQLFF4WGUr2RpomJTLQdZ24ITXr4=";
};
};
morphio = py3.pkgs.toPythonModule ( pkgs.stdenv.mkDerivation rec {
pname = "MorphIO";
version = "3.3.4";
nativeBuildInputs = (with pkgs; [
cmake
ninja
py3
py3.pkgs.numpy
hdf5
]);
cmakeFlags = [
"-DMorphIO_CXX_WARNINGS=OFF"
];
postInstall = ''
mkdir -p $out/${py3.sitePackages}
mv ../morphio $out/${py3.sitePackages}
cp binds/python/_morphio.* $out/${py3.sitePackages}/morphio/
'';
src = pkgs.fetchFromGitHub {
owner = "BlueBrain";
repo = "MorphIO";
rev = "v${version}";
deepClone = true;
fetchSubmodules = true;
sha256 = "C3zDziG7LF7v22ZvplBrtOYq7iKGnAavfpiBCcShHaQ=";
};
});
in {
nixpkgs.overlays = [(self: super: rec {
# Add CUDA Support to Blender
blender_cuda = super.blender.override {
cudaSupport = true;
};
# Add Opencamlib for BlenderCAM Support
blender = blender_cuda.overrideAttrs (old: {
pythonPath = old.pythonPath ++ (with py3Pkgs; [
# OpenCAMLib support
shapely
equation
opencamlib
# NeuroMorphoVis support
matplotlib
seaborn
pandas
pillow
h5py
morphio
# TODO add BluePy support?
]);
});
# Update RX and Aseprite
rx = super.rx.overrideAttrs (old: {
version = "git";
src = super.fetchFromGitHub {
owner = "cloudhead";
repo = old.pname;
rev = "18625a68921873ebe21a7ea8096409a9f0314541";
sha256 = "sha256-LTpaV/fgYUgA2M6Wz5qLHnTNywh13900g+umhgLvciM=";
};
});
})];
environment.systemPackages = with pkgs; [
blender
# GTK theme support (basic) for GTK apps e.g. inkscape
gnome.adwaita-icon-theme
rx
aseprite-unfree
gimp
synfigstudio
inkscape-with-extensions
];
}

11
programs/audio.nix Normal file
View File

@@ -0,0 +1,11 @@
{ lib, config, pkgs, ... }: {
environment.systemPackages = with pkgs; [
easyeffects
helvum
musescore
audacity
tidal-hifi
];
}

63
programs/cad.nix Normal file
View File

@@ -0,0 +1,63 @@
{ lib, config, pkgs, ... }: let
py3 = pkgs.python3;
py3Pkgs = py3.pkgs;
# For 3D CNC machining
opencamlib = py3Pkgs.toPythonModule (pkgs.stdenv.mkDerivation rec {
pname = "opencamlib";
version = "2019.07";
nativeBuildInputs = (with pkgs;[
cmake
git
doxygen
boost
texlive.combined.scheme-full
]);
propagatedNativeBuildInputs = (with pkgs; [
py3
py3.pkgs.boost
py3.pkgs.vtk
]);
postPatch = ''
mkdir -p $out/${py3.sitePackages}/{lib,ocl}
sed -e 's#LIBRARY DESTINATION ''${PYTHON_ARCH_PACKAGES}#LIBRARY DESTINATION '"$out"'/${py3.sitePackages}#g' -i src/pythonlib/pythonlib.cmake
sed -e 's#DESTINATION ''${PYTHON_SITE_PACKAGES}#DESTINATION '"$out"'/${py3.sitePackages}#g' -i src/pythonlib/pythonlib.cmake
'';
cmakeFlags = [
"-DVERSION_STRING=2019.07"
"-DBUILD_CXX_LIB=ON"
"-DBUILD_PY_LIB=ON"
"-DUSE_PY_3=ON"
"-DCMAKE_BUILD_TYPE=Release"
];
src = pkgs.fetchFromGitHub {
owner = "aewallin";
repo = "opencamlib";
rev = "2019.07";
sha256 = "1a8pxp1mh8x3bfsb0l97vgxrpk482p7q9jprkd4m9hv69vva2bdz";
};
});
py3Cad = pkgs.python3.withPackages (p: (with p; [
numpy
scipy
seaborn
pandas
matplotlib
ipython
python-lsp-server
opencamlib
]));
in
# if you also want support for flakes
nixpkgs.overlays = [(self: super: rec {
freecad = super.freecad.override {
python = py3Cad;
};
})];
environment.systemPackages = with pkgs; [
openscad
freecad
kicad
];
}

29
programs/desktop.nix Normal file
View File

@@ -0,0 +1,29 @@
{ lib, config, pkgs, ... }: {
nixpkgs.overlays = [(self: super: rec {
# Discord fix
discord = super.discord.override {
nss = super.pkgs.nss_latest;
};
discord-canary = super.discord-canary.override {
nss = super.pkgs.nss_latest;
};
})];
environment.systemPackages = with pkgs; [
firefox
chromium
bitwarden
bitwarden-cli
nextcloud-client
libsForQt5.kdeconnect-kde
discord-canary
discord
betterdiscordctl
slack
teams
signal-desktop
];
}

15
programs/games.nix Normal file
View File

@@ -0,0 +1,15 @@
{ lib, config, pkgs, ... }: {
# For steam
services.flatpak.enable = true;
# Game compat
programs.gamemode.enable = true;
environment.systemPackages = with pkgs; [
# Minecraft
openjdk17
prismlauncher
# PS2 Games
pcsx2
];
}

14
programs/office.nix Normal file
View File

@@ -0,0 +1,14 @@
{ lib, config, pkgs, ... }: {
environment.systemPackages = with pkgs; [
kitty
emacs
rnix-lsp
texlive.combined.scheme-full
pandoc
libreoffice-qt
pandoc
ispell
# Fonts
julia-mono
];
}

9
programs/programming.nix Normal file
View File

@@ -0,0 +1,9 @@
{ lib, config, pkgs, ... }: {
environment.systemPackages = with pkgs; [
godot_4
cbqn-replxx
cudaPackages.cudatoolkit
cudaPackages.cudnn
];
}

16
programs/terminal.nix Normal file
View File

@@ -0,0 +1,16 @@
{ lib, config, pkgs, ... }: {
environment.systemPackages = with pkgs; [
wget
curl
git
zip
unzip
lsof
htop
btop
xclip
screen
man-pages
man-pages-posix
];
}

6
programs/video.nix Normal file
View File

@@ -0,0 +1,6 @@
{ lib, config, pkgs, ... }: {
environment.systemPackages = with pkgs; [
vlc
ffmpeg_5-full
];
}