Compare commits

..

No commits in common. "622e2ee25f1a82f49f1b06169d9c84ebe4452c94" and "9d9a349b6528abc321347750c8d687a12b4bbb77" have entirely different histories.

3 changed files with 71 additions and 139 deletions

View File

@ -1,2 +0,0 @@
[build]
rustflags = ["-C", "link-arg=-fuse-ld=lld"]

View File

@ -1,4 +1,4 @@
{ config, lib, pkgs, ... }: { config, pkgs, ... }:
let let
my-python3-packages = python3-packages: with python3-packages; [ my-python3-packages = python3-packages: with python3-packages; [
@ -11,10 +11,6 @@ let
pyside2 pyside2
markdown markdown
psutil psutil
scipy
numpy
pillow
]; ];
#my-python2-packages = python2-packages: with python2-packages; [ #my-python2-packages = python2-packages: with python2-packages; [
# pip setuptools # pip setuptools
@ -26,12 +22,8 @@ let
# pyopengl-accelerate # pyopengl-accelerate
#]; #];
python3-with-my-packages = pkgs.python3.withPackages my-python3-packages; python3-with-my-packages = pkgs.python3.withPackages my-python3-packages;
#python2-with-my-packages = pkgs.python2.withPackages my-python2-packages; #python2-with-my-packages = pkgs.python2.withPackages my-python2-packages;
linuxPackages = pkgs.linuxPackages_5_10; linuxPackages = pkgs.linuxPackages_5_10;
mpvPlus = pkgs.mpv-with-scripts.override {
scripts = [ pkgs.mpvScripts.mpris ];
};
microsoftErgonomicKeyboard = pkgs.callPackage /home/arne/nixpkgs/microsoft-ergonomic-keyboard { kernel = linuxPackages.kernel; };
in in
{ {
imports = imports =
@ -39,20 +31,13 @@ in
./hardware-configuration.nix ./hardware-configuration.nix
]; ];
nix.autoOptimiseStore = true; # Use the systemd-boot EFI boot loader.
boot.loader.systemd-boot.enable = true; boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true; boot.loader.efi.canTouchEfiVariables = true;
boot.kernelPackages = linuxPackages; boot.kernelPackages = linuxPackages;
#boot.kernelPatches = [ boot.extraModulePackages = [ config.boot.kernelPackages.v4l2loopback ];
# { boot.kernelModules = [ "v4l2loopback" ];
# name = "fixup MS keyboard"; boot.kernelParams = [ "mitigations=off" ];
# patch = /home/arne/src/linux-5.10.62/0001-change-it.patch;
# }
#];
boot.extraModulePackages = [ config.boot.kernelPackages.v4l2loopback microsoftErgonomicKeyboard ];
boot.kernelModules = [ "v4l2loopback" "nct6775" "hid_microsoft_ergonomic" ];
boot.kernelParams = [ "mitigations=off" "amdgpu.noretry=0" ];
boot.kernel.sysctl = { boot.kernel.sysctl = {
# enable Alt+SysRq commands # enable Alt+SysRq commands
"kernel.sysrq" = 1; "kernel.sysrq" = 1;
@ -72,32 +57,12 @@ in
boot.tmpOnTmpfs = true; boot.tmpOnTmpfs = true;
hardware.cpu.amd.updateMicrocode = true; hardware.cpu.amd.updateMicrocode = true;
hardware.mcelog.enable = true;
services.fstrim.enable = true; services.fstrim.enable = true;
services.journald.extraConfig = "SystemMaxUse=100M"; services.journald.extraConfig = "SystemMaxUse=100M";
#hardware.bluetooth.enable = true;
networking.useDHCP = false; networking.useDHCP = false;
networking.interfaces.enp39s0.useDHCP = true; networking.interfaces.enp39s0.useDHCP = true;
#networking.interfaces.enp42s0f3u2.useDHCP = false;
#networking.interfaces.enp42s0f3u2.proxyARP = true;
#networking.interfaces.enp42s0f3u2.ipv4.routes = [
# {
# address = "10.0.0.0";
# prefixLength = 24;
# }
#];
#networking.interfaces.enp42s0f3u2.ipv4.addresses = [
# {
# address = "10.0.0.1";
# prefixLength = 24;
# }
#];
networking.hostName = "nixOS"; networking.hostName = "nixOS";
#networking.hosts = {
# "10.0.0.2" = [ "arne-ThinkPad-T410" ];
#};
networking.firewall.logRefusedConnections = false; networking.firewall.logRefusedConnections = false;
networking.firewall.rejectPackets = true; networking.firewall.rejectPackets = true;
networking.firewall.allowedTCPPorts = [ 12783 12975 25565 ]; networking.firewall.allowedTCPPorts = [ 12783 12975 25565 ];
@ -115,7 +80,7 @@ in
security.sudo.extraConfig = '' security.sudo.extraConfig = ''
Defaults insults Defaults insults
Defaults timestamp_timeout=10 Defaults timestamp_timeout=-1
''; '';
time.timeZone = "Europe/Berlin"; time.timeZone = "Europe/Berlin";
@ -134,6 +99,7 @@ in
KDE_UTF8_FILENAMES = "1"; KDE_UTF8_FILENAMES = "1";
ANDROID_SDK_HOME = "$HOME/.cache"; ANDROID_SDK_HOME = "$HOME/.cache";
GRADLE_USER_HOME = "$HOME/.cache/gradle"; GRADLE_USER_HOME = "$HOME/.cache/gradle";
MATHEMATICA_USERBASE = "$HOME/.cache/mathematica";
XCOMPOSECACHE = "$HOME/.cache/X11/xcompose"; XCOMPOSECACHE = "$HOME/.cache/X11/xcompose";
}; };
environment.extraInit = '' environment.extraInit = ''
@ -159,29 +125,17 @@ in
services.xserver.enable = true; services.xserver.enable = true;
services.xserver.enableCtrlAltBackspace = true; services.xserver.enableCtrlAltBackspace = true;
services.xserver.libinput.enable = true; services.xserver.libinput.enable = true;
#services.xserver.libinput.accelProfile = "flat"; services.xserver.layout = "us";
services.xserver.layout = "dvorak-custom"; services.xserver.xkbVariant = "dvorak";
services.xserver.extraLayouts = {
dvorak-custom = {
description = "Dvorak customized";
languages = [ "eng" ];
symbolsFile = /home/arne/.config/dvorak-custom;
};
};
services.xserver.autoRepeatDelay = 183;
services.xserver.autoRepeatInterval = 33;
services.xserver.displayManager.sddm.enable = true; services.xserver.displayManager.sddm.enable = true;
services.xserver.displayManager.job.logToJournal = true;
services.xserver.desktopManager.plasma5.enable = true; services.xserver.desktopManager.plasma5.enable = true;
xdg.portal.enable = true; xdg.portal.enable = true;
xdg.portal.gtkUsePortal = true; xdg.portal.gtkUsePortal = true;
fonts.enableDefaultFonts = true; fonts.enableDefaultFonts = true;
fonts.fonts = with pkgs; [ fonts.fonts = with pkgs; [
noto-fonts-emoji noto-fonts-emoji
liberation_ttf liberation_ttf
cozette
font-awesome
]; ];
virtualisation.docker.enable = true; virtualisation.docker.enable = true;
@ -189,10 +143,6 @@ in
#virtualisation.anbox.enable = true; #virtualisation.anbox.enable = true;
# services.printing.enable = true; # services.printing.enable = true;
services.trilium-server.enable = true;
#services.trilium-server.dataDir = "/home/arne/.local/share/trilium-sync-server-data";
#services.trilium-server.host = "192.168.178.21";
services.trilium-server.port = 12783;
services.boinc.enable = true; services.boinc.enable = true;
services.vnstat.enable = true; services.vnstat.enable = true;
services.gitlab-runner.enable = true; services.gitlab-runner.enable = true;
@ -200,12 +150,11 @@ in
shell = { shell = {
registrationConfigFile = "/home/arne/Documents/gitlab-runner-registration"; registrationConfigFile = "/home/arne/Documents/gitlab-runner-registration";
executor = "shell"; executor = "shell";
buildsDir = "/tmp/builds_dir";
}; };
#shell2 = { shell2 = {
# registrationConfigFile = "/home/arne/Documents/gitlab-runner-registration-kv"; registrationConfigFile = "/home/arne/Documents/gitlab-runner-registration-kv";
# executor = "shell"; executor = "shell";
#}; };
}; };
services.openvpn.servers = { services.openvpn.servers = {
kit-split = { kit-split = {
@ -223,24 +172,9 @@ in
}; };
# services.logmein-hamachi.enable = true; # services.logmein-hamachi.enable = true;
sound.enable = false; sound.enable = true;
#hardware.pulseaudio.enable = false; hardware.pulseaudio.enable = true;
#hardware.pulseaudio.support32Bit = false; hardware.pulseaudio.support32Bit = true;
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
# this does not exist (yet?)
#pulse.support32Bit = true;
# If you want to use JACK applications, uncomment this
#jack.enable = true;
# use the example session manager (no others are packaged yet so this is enabled by default,
# no need to redefine it in your config for now)
#media-session.enable = true;
};
hardware.opengl.enable = true; hardware.opengl.enable = true;
hardware.opengl.driSupport = true; hardware.opengl.driSupport = true;
@ -250,7 +184,7 @@ in
users.users.arne = { users.users.arne = {
isNormalUser = true; isNormalUser = true;
extraGroups = [ "wheel" "docker" "adbusers" "wireshark" "audio" ]; extraGroups = [ "wheel" "docker" "adbusers" ];
shell = pkgs.zsh; shell = pkgs.zsh;
}; };
@ -263,43 +197,55 @@ in
"mathematica" "mathematica"
"idea-ultimate" "idea-ultimate"
"android-studio-stable" "android-studio-stable"
#"logmein-hamachi"
]; ];
packageOverrides = super: let self = super.pkgs; in { packageOverrides = super: let self = super.pkgs; in {
maven = super.maven.override { maven = super.maven.override {
jdk = super.pkgs.jdk11; jdk = super.pkgs.jdk11;
}; };
# remove openssl/curl # remove tesseract and ImageMagick
rustup = super.rustup.overrideAttrs (attrs: rec { ripgrep-all = super.ripgrep-all.overrideDerivation (attrs: {
buildInputs = [ super.pkgs.zlib ]; postInstall = ''
cargoBuildFlags = [ "--no-default-features --features no-self-update,reqwest-backend,reqwest-rustls-tls" ]; wrapProgram $out/bin/rga \
doCheck = false; --prefix PATH ":" "${super.pkgs.lib.makeBinPath [ super.pkgs.pandoc super.pkgs.poppler_utils super.pkgs.ripgrep ]}"
'';
doInstallCheck = false;
}); });
qbittorrent = super.qbittorrent.overrideAttrs (attrs: rec {
version = "4.3.4.1";
src = pkgs.fetchFromGitHub {
owner = "qbittorrent";
repo = "qbittorrent";
rev = "release-4.3.4.1"; # TODO: is there some reason this also has to be specified?
sha256 = "0hpv99ky077h5rvxxd76l5xv99ivqa1hq6739jp1gvl4w6w3cbgc";
};
});
# remove openssl
#rustup = super.rustup.overrideAttrs (attrs: rec {
# buildInputs = [ super.pkgs.zlib ];
# # this does not actually work due to #103130
# cargoBuildFlags = [ "--no-default-features" "--features" "no-self-update" "reqwest-backend" "reqwest-rustls-tls" ];
# doCheck = false;
#});
}; };
}; };
programs.steam.enable = true; programs.steam.enable = true;
programs.zsh.enable = true; programs.zsh.enable = true;
programs.zsh.enableGlobalCompInit = false; programs.zsh.enableGlobalCompInit = false;
programs.zsh.interactiveShellInit = ''
source ${pkgs.nix-index}/etc/profile.d/command-not-found.sh
'';
programs.command-not-found.enable = false;
programs.adb.enable = true; programs.adb.enable = true;
programs.wireshark.enable = true; programs.gnupg.agent = {
programs.wireshark.package = pkgs.wireshark;
programs.gnupg.agent = {
enable = true; enable = true;
enableSSHSupport = false; enableSSHSupport = true;
pinentryFlavor = "qt"; pinentryFlavor = "qt";
}; };
# do not show unlock prompt on login
security.pam.services.sddm.enableKwallet = lib.mkOverride 0 false;
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
# standard utilities # standard utilities
coreutils coreutils
gzip gzip
gcc
manpages manpages
dnsutils dnsutils
vim htop curl wget file zsh git git-branchless vim htop curl wget file zsh git
tree killall tree killall
# premium utilities # premium utilities
jq tmux jq tmux
@ -309,7 +255,6 @@ in
iotop iotop
img2pdf img2pdf
pdftk pdftk
exa
fd fd
zoxide zoxide
fzf fzf
@ -318,47 +263,39 @@ in
ffmpeg_4 ffmpeg_4
# programming environments # programming environments
#geckodriver geckodriver
#python2-with-my-packages #python2-with-my-packages
python3-with-my-packages python3-with-my-packages
jdk8 jdk11 maven visualvm
#visualvm
rustup rustup
cargo-outdated cargo-edit jupyter
#jupyter
vscodium vscodium
jetbrains.idea-ultimate jetbrains.idea-ultimate
#androidStudioPackages.stable #androidStudioPackages.stable
#nodejs nodejs
gcc10 gnumake cmake
llvmPackages_11.bintools
# cplex
key
# CLI applications # CLI applications
lynx lynx
droidcam droidcam
sqlite sqlite
borgbackup borgbackup
nix-tree rnix-hashes nix-tree
#gallery-dl gallery-dl
yt-dlp youtube-dl
#plantuml plantuml
#tectonic tectonic
docker-compose docker-compose
qemu qemu
graphviz graphviz
# GUI applications # GUI applications
sqlitebrowser sqlitebrowser
(gimp-with-plugins.override { plugins = [ gimpPlugins.gmic ]; }) gimp
firefox firefox
thunderbird thunderbird
ungoogled-chromium
keepassxc keepassxc
josm josm
#anki anki
tor-browser-bundle-bin tor-browser-bundle-bin
mathematica mathematica
gparted gparted
@ -366,25 +303,27 @@ in
qdirstat qdirstat
filelight filelight
libreoffice-fresh libreoffice-fresh
filezilla
qbittorrent qbittorrent
tdesktop tdesktop
alacritty yakuake okular akregator kwalletmanager gwenview ark kcalc kcolorchooser kompare k3b kcharselect
okular akregator kwalletmanager gwenview ark kcalc kcolorchooser kompare k3b kcharselect kmag kdeApplications.kruler
plasma5Packages.kruler
kdeconnect kdeconnect
plasma-vault plasma-vault
ksshaskpass ksshaskpass
notepadqq notepadqq
mpvPlus mpv
bitcoin
#xorg.xkbcomp xorg.xkbcomp
xorg.xrandr xorg.xrandr
#evtest
lm_sensors lm_sensors
xclip xclip
ntfs3g ntfs3g
cryptsetup pinentry-qt cryptsetup pinentry-qt
wineWowPackages.full
winetricks
cdrkit cdrkit
vnstat vnstat
aspellDicts.de aspellDicts.de
@ -393,19 +332,15 @@ in
linuxPackages.perf linuxPackages.perf
perf-tools perf-tools
smartmontools smartmontools
#libfaketime libfaketime
#afl afl
# Games # Games
multimc multimc
#minecraft minecraft
#logmein-hamachi #logmein-hamachi
update-resolv-conf # for OpenVPN configs update-resolv-conf
# List of packages to get on demand
#wineWowPackages.full
#winetricks
]; ];
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions

View File

@ -1,10 +1,9 @@
profile=gpu-hq profile=gpu-hq
hwdec=auto-safe hwdec=vdpau
loop-playlist=inf loop-playlist=inf
image-display-duration=2 image-display-duration=2
shuffle shuffle
no-audio-display no-audio-display
volume-max=1000.0
[noosd] [noosd]
no-osc no-osc