Compare commits

..

No commits in common. "6bbbb8e7b6da5deffa792c5c19b5056fa953cd8b" and "299df4379bbc930bcc33396a66101c02f7e257ed" have entirely different histories.

35 changed files with 321 additions and 495 deletions

View file

@ -1,15 +1,8 @@
{ { pkgs, config, lib, inputs, ... }:
pkgs,
config,
lib,
inputs,
...
}:
let let
nixGL = import ./../../home-manager/utils/nixGLWrap.nix { inherit pkgs config; }; nixGL = import ./../../home-manager/utils/nixGLWrap.nix { inherit pkgs config; };
in in {
{
imports = [ ./../../home-manager/modules/machine.nix ]; imports = [ ./../../home-manager/modules/machine.nix ];
machine = { machine = {

View file

@ -1,21 +1,11 @@
{ { config, lib, modulesPath, ... }:
config,
lib,
modulesPath,
...
}:
{ {
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
boot = { boot = {
initrd = { initrd = {
availableKernelModules = [ availableKernelModules = [ "nvme" "xhci_pci" "usb_storage" "sd_mod" ];
"nvme"
"xhci_pci"
"usb_storage"
"sd_mod"
];
kernelModules = [ ]; kernelModules = [ ];
}; };
kernelModules = [ "kvm-amd" ]; kernelModules = [ "kvm-amd" ];
@ -27,7 +17,8 @@
fsType = "ext4"; fsType = "ext4";
}; };
boot.initrd.luks.devices."luks-6f077715-c436-4254-acb2-66d8be0a0c55".device = "/dev/disk/by-uuid/6f077715-c436-4254-acb2-66d8be0a0c55"; boot.initrd.luks.devices."luks-6f077715-c436-4254-acb2-66d8be0a0c55".device =
"/dev/disk/by-uuid/6f077715-c436-4254-acb2-66d8be0a0c55";
fileSystems."/boot" = { fileSystems."/boot" = {
device = "/dev/disk/by-uuid/877C-C918"; device = "/dev/disk/by-uuid/877C-C918";
@ -45,5 +36,6 @@
# networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true; # networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; hardware.cpu.amd.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
} }

View file

@ -4,9 +4,7 @@
home-manager = { home-manager = {
useGlobalPkgs = true; useGlobalPkgs = true;
useUserPackages = true; useUserPackages = true;
extraSpecialArgs = { extraSpecialArgs = { inherit inputs; };
inherit inputs;
};
users.thilo = { users.thilo = {
imports = [ ./../../home-manager/modules/machine.nix ]; imports = [ ./../../home-manager/modules/machine.nix ];
@ -18,9 +16,7 @@
isGraphical = true; isGraphical = true;
}; };
home.sessionVariables = { home.sessionVariables = { LD_LIBRARY_PATH = "${pkgs.libGL}/lib"; };
LD_LIBRARY_PATH = "${pkgs.libGL}/lib";
};
}; };
}; };
} }

View file

@ -1,8 +1,7 @@
{ pkgs, ... }: { pkgs, ... }:
{ {
imports = [ imports = [ # Include the results of the hardware scan.
# Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
./../../nixos/common.nix ./../../nixos/common.nix
./../../nixos/builders.nix ./../../nixos/builders.nix
@ -16,19 +15,14 @@
boot.plymouth.enable = true; boot.plymouth.enable = true;
# Setup keyfile # Setup keyfile
boot.initrd.secrets = { boot.initrd.secrets = { "/crypto_keyfile.bin" = null; };
"/crypto_keyfile.bin" = null;
};
networking.hostName = "thilo-laptop"; # Define your hostname. networking.hostName = "thilo-laptop"; # Define your hostname.
# Configure console keymap # Configure console keymap
console.keyMap = "de"; console.keyMap = "de";
environment.gnome.excludePackages = with pkgs; [ environment.gnome.excludePackages = with pkgs; [ tracker tracker-miners ];
tracker
tracker-miners
];
hardware.bluetooth.enable = true; hardware.bluetooth.enable = true;
@ -72,16 +66,18 @@
]; ];
}; };
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [ brlaser brgenml1lpr ];
brlaser
brgenml1lpr nixpkgs.config.permittedInsecurePackages = [
"nix-2.16.2"
]; ];
nixpkgs.config.permittedInsecurePackages = [ "nix-2.16.2" ];
xdg.portal = { xdg.portal = {
enable = true; enable = true;
extraPortals = [ pkgs.kdePackages.xdg-desktop-portal-kde ]; extraPortals = [
pkgs.kdePackages.xdg-desktop-portal-kde
];
}; };
system.stateVersion = "23.05"; system.stateVersion = "23.05";

View file

@ -1,27 +1,15 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ { config, lib, modulesPath, ... }:
config,
lib,
modulesPath,
...
}:
{ {
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
boot = { boot = {
initrd = { initrd = {
availableKernelModules = [ availableKernelModules =
"nvme" [ "nvme" "xhci_pci" "ahci" "usbhid" "uas" "usb_storage" "sd_mod" ];
"xhci_pci"
"ahci"
"usbhid"
"uas"
"usb_storage"
"sd_mod"
];
kernelModules = [ ]; kernelModules = [ ];
}; };
kernelModules = [ "kvm-amd" ]; kernelModules = [ "kvm-amd" ];
@ -56,5 +44,6 @@
# networking.interfaces.enp8s0.useDHCP = lib.mkDefault true; # networking.interfaces.enp8s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; hardware.cpu.amd.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
} }

View file

@ -4,9 +4,7 @@
home-manager = { home-manager = {
useGlobalPkgs = true; useGlobalPkgs = true;
useUserPackages = true; useUserPackages = true;
extraSpecialArgs = { extraSpecialArgs = { inherit inputs; };
inherit inputs;
};
users.thilo = { users.thilo = {
imports = [ ./../../home-manager/modules/machine.nix ]; imports = [ ./../../home-manager/modules/machine.nix ];
@ -18,17 +16,13 @@
isGraphical = true; isGraphical = true;
}; };
/* /* xsession.pointerCursor = {
xsession.pointerCursor = { name = "Bibata-Modern-Classic";
name = "Bibata-Modern-Classic"; package = pkgs.bibata-cursors;
package = pkgs.bibata-cursors; size = 128;
size = 128; }; */
};
*/
home.sessionVariables = { home.sessionVariables = { LD_LIBRARY_PATH = "${pkgs.libGL}/lib"; };
LD_LIBRARY_PATH = "${pkgs.libGL}/lib";
};
home.packages = with pkgs; [ libsForQt5.discover ]; home.packages = with pkgs; [ libsForQt5.discover ];
}; };

View file

@ -58,10 +58,7 @@
programs.nix-ld.enable = true; programs.nix-ld.enable = true;
hardware.opengl = { hardware.opengl = {
extraPackages = with pkgs; [ extraPackages = with pkgs; [ vaapiVdpau libvdpau-va-gl ];
vaapiVdpau
libvdpau-va-gl
];
}; };
hardware.bluetooth.enable = true; hardware.bluetooth.enable = true;
@ -89,7 +86,9 @@
]; ];
}; };
nixpkgs.config.permittedInsecurePackages = [ "nix-2.16.2" ]; nixpkgs.config.permittedInsecurePackages = [
"nix-2.16.2"
];
system.stateVersion = "23.05"; system.stateVersion = "23.05";
} }

View file

@ -7,11 +7,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1716892732, "lastModified": 1715270390,
"narHash": "sha256-n1UnQ7RbJwDAUX1fq4+hUNVVIWDlZKvAsUp/muSkV3g=", "narHash": "sha256-j4k51vcfTCgEPElhB+/4fL8MA05HhC+vZvUh1eQYzc0=",
"owner": "dagger", "owner": "dagger",
"repo": "nix", "repo": "nix",
"rev": "9e26b2f73eebf9e3b9fbc1a31c378ccb2daf84cd", "rev": "561a09f4c8b0eadf291f072b2e35498d9e33cdb9",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -93,11 +93,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1716908526, "lastModified": 1715930644,
"narHash": "sha256-Zl6e/sEVDh07K47XxDGPsXTYT4nI6llUDbQ4xMIwp7k=", "narHash": "sha256-W9pyM3/vePxrffHtzlJI6lDS3seANQ+Nqp+i58O46LI=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "373ead20606efa9181cd15ba19a5deac7ead1492", "rev": "e3ad5108f54177e6520535768ddbf1e6af54b59d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -214,11 +214,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1716772633, "lastModified": 1716170277,
"narHash": "sha256-Idcye44UW+EgjbjCoklf2IDF+XrehV6CVYvxR1omst4=", "narHash": "sha256-fCAiox/TuzWGVaAz16PxrR4Jtf9lN5dwWL2W74DS0yI=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nix-index-database", "repo": "nix-index-database",
"rev": "ff80cb4a11bb87f3ce8459be6f16a25ac86eb2ac", "rev": "e0638db3db43b582512a7de8c0f8363a162842b9",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -288,11 +288,11 @@
"treefmt-nix": "treefmt-nix" "treefmt-nix": "treefmt-nix"
}, },
"locked": { "locked": {
"lastModified": 1716350738, "lastModified": 1715679428,
"narHash": "sha256-aTwS8rp0vaDOIgirVNfYNr8swW/yG8AtOxbBoFpdD9U=", "narHash": "sha256-WapL4RmvX+FaRtJvhbtCDGGzefn8wam+yO0hnf4l9+s=",
"owner": "ryantm", "owner": "ryantm",
"repo": "nixpkgs-update", "repo": "nixpkgs-update",
"rev": "3e25ce4c5f54e790bf757ac2f17915fc8ec4fc1d", "rev": "4e1df89d081c96429f257d125f4c7ab02adffd47",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -303,11 +303,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1716509168, "lastModified": 1716137900,
"narHash": "sha256-4zSIhSRRIoEBwjbPm3YiGtbd8HDWzFxJjw5DYSDy1n8=", "narHash": "sha256-sowPU+tLQv8GlqtVtsXioTKeaQvlMz/pefcdwg8MvfM=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "bfb7a882678e518398ce9a31a881538679f6f092", "rev": "6c0b7a92c30122196a761b440ac0d46d3d9954f1",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -2,12 +2,8 @@
description = "Nixos config"; description = "Nixos config";
inputs = { inputs = {
nixpkgs = { nixpkgs = { url = "github:NixOS/nixpkgs/nixos-unstable"; };
url = "github:NixOS/nixpkgs/nixos-unstable"; nixpkgs-update = { url = "github:ryantm/nixpkgs-update"; };
};
nixpkgs-update = {
url = "github:ryantm/nixpkgs-update";
};
home-manager = { home-manager = {
url = "github:nix-community/home-manager"; url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
@ -35,28 +31,21 @@
}; };
nixConfig = { nixConfig = {
substituters = [ substituters = [
"https://cache.nixos.org" "https://cache.nixos.org"
"https://nix-community.cachix.org" "https://nix-community.cachix.org"
"https://nixpkgs-update.cachix.org" "https://nixpkgs-update.cachix.org"
"https://devenv.cachix.org" "https://devenv.cachix.org"
]; ];
trusted-public-keys = [ trusted-public-keys = [
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
"nixpkgs-update.cachix.org-1:6y6Z2JdoL3APdu6/+Iy8eZX2ajf09e4EE9SnxSML1W8=" "nixpkgs-update.cachix.org-1:6y6Z2JdoL3APdu6/+Iy8eZX2ajf09e4EE9SnxSML1W8="
"devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw=" "devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw="
]; ];
}; };
outputs = outputs = { nixpkgs, home-manager, nixgl, w17, ... }@inputs:
{
nixpkgs,
home-manager,
nixgl,
w17,
...
}@inputs:
let let
system = "x86_64-linux"; system = "x86_64-linux";
pkgs = import nixpkgs { pkgs = import nixpkgs {
@ -64,8 +53,7 @@
overlays = [ nixgl.overlay ]; overlays = [ nixgl.overlay ];
allowUnfree = true; allowUnfree = true;
}; };
in in {
{
nixosConfigurations.thilo-pc = nixpkgs.lib.nixosSystem { nixosConfigurations.thilo-pc = nixpkgs.lib.nixosSystem {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
@ -73,9 +61,7 @@
./configs/thilo-pc/nixos.nix ./configs/thilo-pc/nixos.nix
./configs/thilo-pc/home.nix ./configs/thilo-pc/home.nix
]; ];
specialArgs = { specialArgs = { inherit inputs; };
inherit inputs;
};
}; };
nixosConfigurations.thilo-laptop = nixpkgs.lib.nixosSystem { nixosConfigurations.thilo-laptop = nixpkgs.lib.nixosSystem {
system = "x86_64-linux"; system = "x86_64-linux";
@ -84,33 +70,28 @@
./configs/thilo-laptop/nixos.nix ./configs/thilo-laptop/nixos.nix
./configs/thilo-laptop/home.nix ./configs/thilo-laptop/home.nix
]; ];
specialArgs = { specialArgs = { inherit inputs; };
inherit inputs;
};
}; };
homeConfigurations."thilo@thilo-pc" = home-manager.lib.homeManagerConfiguration { homeConfigurations."thilo@thilo-pc" =
inherit pkgs; home-manager.lib.homeManagerConfiguration {
modules = [ inherit pkgs;
inputs.nix-index-database.hmModules.nix-index modules = [
./configs/fedora/home.nix inputs.nix-index-database.hmModules.nix-index
]; ./configs/fedora/home.nix
extraSpecialArgs = { ];
inherit inputs nixgl; extraSpecialArgs = { inherit inputs nixgl; };
}; };
}; homeConfigurations."thilo@thilo-laptop" =
homeConfigurations."thilo@thilo-laptop" = home-manager.lib.homeManagerConfiguration { home-manager.lib.homeManagerConfiguration {
inherit pkgs; inherit pkgs;
modules = [ ./configs/fedora/home.nix ]; modules = [ ./configs/fedora/home.nix ];
extraSpecialArgs = { extraSpecialArgs = { inherit inputs nixgl; };
inherit inputs nixgl;
}; };
}; homeConfigurations."thilo@thilo-pc-win" =
homeConfigurations."thilo@thilo-pc-win" = home-manager.lib.homeManagerConfiguration { home-manager.lib.homeManagerConfiguration {
inherit pkgs; inherit pkgs;
modules = [ ./configs/wsl/home.nix ]; modules = [ ./configs/wsl/home.nix ];
extraSpecialArgs = { extraSpecialArgs = { inherit inputs nixgl; };
inherit inputs nixgl;
}; };
};
}; };
} }

View file

@ -1,11 +1,5 @@
{ { lib, pkgs, config, ... }:
lib, with lib; {
pkgs,
config,
...
}:
with lib;
{
imports = [ imports = [
./../programs/atuin.nix ./../programs/atuin.nix
./../programs/alacritty.nix ./../programs/alacritty.nix
@ -86,7 +80,8 @@ with lib;
''; '';
".ssh/config_source" = { ".ssh/config_source" = {
source = ./../dotfiles/ssh-config; source = ./../dotfiles/ssh-config;
onChange = "cat ~/.ssh/config_source > ~/.ssh/config && chmod 600 ~/.ssh/config"; onChange =
"cat ~/.ssh/config_source > ~/.ssh/config && chmod 600 ~/.ssh/config";
}; };
".gitignore".source = ./../dotfiles/.gitignore; ".gitignore".source = ./../dotfiles/.gitignore;
".config/pipewire/pipewire.conf.d/99-noise-suppression.conf".text = '' ".config/pipewire/pipewire.conf.d/99-noise-suppression.conf".text = ''
@ -136,3 +131,4 @@ with lib;
}; };
}; };
} }

View file

@ -1,15 +1,10 @@
{ { config, pkgs, lib, inputs, ... }:
config,
pkgs,
lib,
inputs,
...
}:
with lib; with lib;
let let
nixGL = import ./../../home-manager/utils/nixGLWrap.nix { inherit pkgs config; }; 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"; electronFlags =
"--enable-features=UseOzonePlatform --ozone-platform=wayland --enable-wayland-ime --disable-gpu-shader-disk-cache -n";
in in
{ {
config = { config = {
@ -21,15 +16,14 @@ in
}) })
]; ];
home.packages = home.packages = with pkgs;
with pkgs;
[ [
pkgs.nixVersions.latest # because remotely invoked updates are fun ;) pkgs.nixVersions.latest # because remotely invoked updates are fun ;)
up up
htop htop
rustc rustc
cargo cargo
nixfmt-rfc-style nixfmt
nodejs nodejs
bun bun
deno deno
@ -46,11 +40,12 @@ in
hub hub
httpie httpie
manix manix
(pkgs.writeShellScriptBin "ssh-fix-permissions" ( (pkgs.writeShellScriptBin "ssh-fix-permissions"
builtins.readFile ./../scripts/ssh-fix-permissions.sh (builtins.readFile ./../scripts/ssh-fix-permissions.sh))
)) (pkgs.writeShellScriptBin "yt-dlp-audio"
(pkgs.writeShellScriptBin "yt-dlp-audio" (builtins.readFile ./../scripts/yt-dlp-audio.sh)) (builtins.readFile ./../scripts/yt-dlp-audio.sh))
(pkgs.writeShellScriptBin "nix-shell-init" (builtins.readFile ./../scripts/nix-shell-init.sh)) (pkgs.writeShellScriptBin "nix-shell-init"
(builtins.readFile ./../scripts/nix-shell-init.sh))
(pkgs.writeShellScriptBin "http-server" '' (pkgs.writeShellScriptBin "http-server" ''
${pkgs.caddy}/bin/caddy file-server --listen :2345 ${pkgs.caddy}/bin/caddy file-server --listen :2345
'') '')
@ -77,94 +72,84 @@ in
inputs.w17.packages.x86_64-linux.default inputs.w17.packages.x86_64-linux.default
aichat aichat
(pkgs.nerdfonts.override { (pkgs.nerdfonts.override {
fonts = [ fonts = [ "JetBrainsMono" "FiraCode" "FiraMono" ];
"JetBrainsMono"
"FiraCode"
"FiraMono"
];
}) })
nix-output-monitor nix-output-monitor
nodePackages.pnpm nodePackages.pnpm
npm-check-updates npm-check-updates
] ] ++ (
++ ( if (
if (!config.machine.isGeneric) then !config.machine.isGeneric
[ ) then [
toolbox toolbox
distrobox distrobox
] ] else
else
[ ] [ ]
) ) ++ (
++ ( if (
if (config.machine.isGraphical) then config.machine.isGraphical
[ ) then [
(nixGL insomnia) (nixGL insomnia)
(nixGL comma) (nixGL comma)
] ] else
else
[ ] [ ]
) ) ++ (
++ ( if (
if (config.machine.isGraphical && !config.machine.isGeneric) then config.machine.isGraphical && !config.machine.isGeneric
[ ) then [
jetbrains.webstorm corefonts
jetbrains.phpstorm vistafonts
jetbrains.rust-rover jetbrains.webstorm
jetbrains.goland jetbrains.phpstorm
element-desktop jetbrains.rust-rover
ludusavi jetbrains.goland
dbeaver element-desktop
onlyoffice-bin ludusavi
spotify dbeaver
vesktop onlyoffice-bin
(lutris.override { spotify
extraLibraries = _: [ gnome3.adwaita-icon-theme ]; vesktop
extraPkgs = _: [ (lutris.override {
wineWowPackages.full extraLibraries = _: [ gnome3.adwaita-icon-theme ];
winetricks extraPkgs = _: [
gnome3.adwaita-icon-theme wineWowPackages.full
]; winetricks
}) gnome3.adwaita-icon-theme
bottles ];
protontricks })
heroic bottles
(vscode.override { commandLineArgs = electronFlags; }) protontricks
quickemu heroic
quickgui (vscode.override { commandLineArgs = electronFlags; })
trilium-desktop quickemu
anki quickgui
# inputs.muse-sounds-manager.packages.x86_64-linux.muse-sounds-manager trilium-desktop
jetbrains-toolbox anki
mumble # inputs.muse-sounds-manager.packages.x86_64-linux.muse-sounds-manager
prusa-slicer jetbrains-toolbox
trayscale mumble
gnome.gnome-disk-utility prusa-slicer
inkscape trayscale
musescore gnome.gnome-disk-utility
obsidian inkscape
syncthingtray musescore
reaper obsidian
yabridge syncthingtray
inputs.suyu.packages.x86_64-linux.suyu reaper
inputs.nix-alien.packages.x86_64-linux.nix-alien yabridge
kdePackages.kdenlive inputs.suyu.packages.x86_64-linux.suyu
audacity inputs.nix-alien.packages.x86_64-linux.nix-alien
] kdePackages.kdenlive
else audacity
] else
[ ] [ ]
) ) ++ (if config.machine.isGnome then [
++ ( gnomeExtensions.blur-my-shell
if config.machine.isGnome then gnomeExtensions.dash-to-panel
[ gnomeExtensions.user-themes
gnomeExtensions.blur-my-shell gnomeExtensions.vitals
gnomeExtensions.dash-to-panel gnomeExtensions.custom-accent-colors
gnomeExtensions.user-themes ] else
gnomeExtensions.vitals [ ]);
gnomeExtensions.custom-accent-colors
]
else
[ ]
);
}; };
} }

View file

@ -1,8 +1,4 @@
{ { lib, stdenv, fetchFromGitHub }:
lib,
stdenv,
fetchFromGitHub,
}:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "docker-craft-cms-dev-env"; pname = "docker-craft-cms-dev-env";
@ -21,7 +17,8 @@ stdenv.mkDerivation rec {
''; '';
meta = with lib; { meta = with lib; {
description = "Docker image for local development of sites based on Craft CMS"; description =
"Docker image for local development of sites based on Craft CMS";
homepage = "https://github.com/codemonauts/docker-craft-cms-dev-env"; homepage = "https://github.com/codemonauts/docker-craft-cms-dev-env";
license = licenses.mit; license = licenses.mit;
maintainers = with maintainers; [ ]; maintainers = with maintainers; [ ];

View file

@ -1,24 +1,24 @@
{ pkgs }: { pkgs }:
# SOURCE: https://ostechnix.com/a-bash-function-to-extract-file-archives-of-various-types/ /* SOURCE: https://ostechnix.com/a-bash-function-to-extract-file-archives-of-various-types/ */
pkgs.writeShellScriptBin "extract" '' pkgs.writeShellScriptBin "extract" ''
if [ -f $1 ] ; then if [ -f $1 ] ; then
case $1 in case $1 in
*.tar.bz2) ${pkgs.gnutar}/bin/tar xjf $1 ;; *.tar.bz2) ${pkgs.gnutar}/bin/tar xjf $1 ;;
*.tar.gz) ${pkgs.gnutar}/bin/tar $1 ;; *.tar.gz) ${pkgs.gnutar}/bin/tar $1 ;;
*.bz2) ${pkgs.bzip2}/bin/bunzip2 $1 ;; *.bz2) ${pkgs.bzip2}/bin/bunzip2 $1 ;;
*.rar) ${pkgs.rar}/bin/rar x $1 ;; *.rar) ${pkgs.rar}/bin/rar x $1 ;;
*.gz) ${pkgs.gzip}/bin/gunzip $1 ;; *.gz) ${pkgs.gzip}/bin/gunzip $1 ;;
*.tar) ${pkgs.gnutar}/bin/tar xf $1 ;; *.tar) ${pkgs.gnutar}/bin/tar xf $1 ;;
*.tbz2) ${pkgs.gnutar}/bin/tar xjf $1 ;; *.tbz2) ${pkgs.gnutar}/bin/tar xjf $1 ;;
*.tgz) ${pkgs.gnutar}/bin/tar xzf $1 ;; *.tgz) ${pkgs.gnutar}/bin/tar xzf $1 ;;
*.zip) ${pkgs.unzip}/bin/unzip $1 ;; *.zip) ${pkgs.unzip}/bin/unzip $1 ;;
*.Z) ${pkgs.gzip}/bin/uncompress $1 ;; *.Z) ${pkgs.gzip}/bin/uncompress $1 ;;
*.7z) ${pkgs._7zz}/bin/7z x $1 ;; *.7z) ${pkgs._7zz}/bin/7z x $1 ;;
*) echo "'$1' cannot be extracted via extract()" ;; *) echo "'$1' cannot be extracted via extract()" ;;
esac esac
else else
echo "'$1' is not a valid file" echo "'$1' is not a valid file"
fi fi
'' ''

View file

@ -1,8 +1,4 @@
{ { lib, buildNpmPackage, fetchFromGitHub }:
lib,
buildNpmPackage,
fetchFromGitHub,
}:
buildNpmPackage rec { buildNpmPackage rec {
pname = "spx-gc"; pname = "spx-gc";
@ -25,7 +21,8 @@ buildNpmPackage rec {
''; '';
meta = with lib; { meta = with lib; {
description = "SPX is a graphics control client for live video productions and live streams using CasparCG, OBS, vMix, or similar software"; description =
"SPX is a graphics control client for live video productions and live streams using CasparCG, OBS, vMix, or similar software";
homepage = "https://github.com/TuomoKu/SPX-GC#npminstall"; homepage = "https://github.com/TuomoKu/SPX-GC#npminstall";
license = licenses.mit; license = licenses.mit;
maintainers = with maintainers; [ ]; maintainers = with maintainers; [ ];

View file

@ -1,14 +1,8 @@
{ { config, pkgs, lib, ... }:
config,
pkgs,
lib,
...
}:
let let
nixGL = import ./../../home-manager/utils/nixGLWrap.nix { inherit pkgs config; }; nixGL = import ./../../home-manager/utils/nixGLWrap.nix { inherit pkgs config; };
in in {
{
programs.alacritty = { programs.alacritty = {
enable = if config.machine.isGraphical then true else false; enable = if config.machine.isGraphical then true else false;
package = (nixGL pkgs.alacritty); package = (nixGL pkgs.alacritty);

View file

@ -1,5 +1,3 @@
{ {
programs.atuin = { programs.atuin = { enable = true; };
enable = true;
};
} }

View file

@ -1,5 +1 @@
{ { programs.bat = { enable = true; }; }
programs.bat = {
enable = true;
};
}

View file

@ -12,9 +12,7 @@
duplicate_action = "ask"; duplicate_action = "ask";
default_action = "apply"; default_action = "apply";
}; };
badfiles = { badfiles = { check_on_import = "yes"; };
check_on_import = "yes";
};
match = { match = {
max_rec = { max_rec = {
track_length = "strong"; track_length = "strong";

View file

@ -20,10 +20,7 @@ let
"kbfnbcaeplbcioakkpcpgfkobkghlhen" # Grammarly "kbfnbcaeplbcioakkpcpgfkobkghlhen" # Grammarly
]; ];
isEnabled = if (config.machine.isGraphical && !config.machine.isGeneric) then true else false; isEnabled = if (config.machine.isGraphical && !config.machine.isGeneric) then true else false;
dictionaries = with pkgs.hunspellDictsChromium; [ dictionaries = with pkgs.hunspellDictsChromium; [ en_US de_DE ];
en_US
de_DE
];
commandLineArgs = [ commandLineArgs = [
"--enable-wayland-ime" "--enable-wayland-ime"
"--ignore-gpu-blocklist" "--ignore-gpu-blocklist"
@ -33,8 +30,7 @@ let
"--enable-features=WaylandWindowDecorations,VaapiVideoDecoder,VaapiVideoEncoder,VaapiVideoDecodeLinuxGL,WebRTCPipeWireCapturer" "--enable-features=WaylandWindowDecorations,VaapiVideoDecoder,VaapiVideoEncoder,VaapiVideoDecodeLinuxGL,WebRTCPipeWireCapturer"
]; ];
extensions = map (eid: { id = eid; }) chromium_extension; extensions = map (eid: { id = eid; }) chromium_extension;
in in {
{
programs.chromium = { programs.chromium = {
inherit dictionaries commandLineArgs extensions; inherit dictionaries commandLineArgs extensions;
enable = isEnabled; enable = isEnabled;

View file

@ -1,5 +1 @@
{ { programs.command-not-found = { enable = false; }; }
programs.command-not-found = {
enable = false;
};
}

View file

@ -15,28 +15,18 @@
ui = true; ui = true;
pager = true; pager = true;
}; };
log = { log = { date = "short"; };
date = "short"; rerere = { enabled = "1"; };
};
rerere = {
enabled = "1";
};
core = { core = {
whitespace = "fix,-indent-with-non-tab,trailing-space,cr-at-eol"; whitespace = "fix,-indent-with-non-tab,trailing-space,cr-at-eol";
excludesfile = "~/.gitignore"; excludesfile = "~/.gitignore";
autocrlf = "input"; autocrlf = "input";
}; };
apply = { apply = { whitespace = "nowarn"; };
whitespace = "nowarn"; branch = { autosetuprebase = "always"; };
};
branch = {
autosetuprebase = "always";
};
}; };
}; };
programs.git-credential-oauth = { programs.git-credential-oauth = { enable = true; };
enable = true;
};
programs.gh.enable = true; programs.gh.enable = true;
programs.gh-dash.enable = true; programs.gh-dash.enable = true;
programs.lazygit.enable = true; programs.lazygit.enable = true;

View file

@ -1,5 +1 @@
{ { programs.go = { enable = true; }; }
programs.go = {
enable = true;
};
}

View file

@ -1,5 +1 @@
{ { programs.hstr = { enable = true; }; }
programs.hstr = {
enable = true;
};
}

View file

@ -3,10 +3,6 @@
{ {
programs.mpv = { programs.mpv = {
enable = if (config.machine.isGraphical && !config.machine.isGeneric) then true else false; enable = if (config.machine.isGraphical && !config.machine.isGeneric) then true else false;
scripts = with pkgs.mpvScripts; [ scripts = with pkgs.mpvScripts; [ autoload mpris sponsorblock ];
autoload
mpris
sponsorblock
];
}; };
} }

View file

@ -7,9 +7,7 @@
viAlias = true; viAlias = true;
vimAlias = true; vimAlias = true;
vimdiffAlias = true; vimdiffAlias = true;
coc = { coc = { enable = true; };
enable = true;
};
extraConfig = '' extraConfig = ''
set title set title
set ignorecase set ignorecase

View file

@ -3,12 +3,8 @@
enable = true; enable = true;
settings = { settings = {
add_newline = false; add_newline = false;
character = { character = { success_symbol = "[](bold white)"; };
success_symbol = "[](bold white)"; package = { disabled = true; };
};
package = {
disabled = true;
};
}; };
}; };
} }

View file

@ -1,5 +1 @@
{ { services.syncthing = { enable = true; }; }
services.syncthing = {
enable = true;
};
}

View file

@ -1,5 +1,3 @@
{ {
programs.thefuck = { programs.thefuck = { enable = false; };
enable = false;
};
} }

View file

@ -1,13 +1,11 @@
{ config, pkgs, ... }: { config, pkgs, ... }:
let let
configPath = configPath = if config.machine.isGeneric then
if config.machine.isGeneric then "${config.home.homeDirectory}/.config/home-manager"
"${config.home.homeDirectory}/.config/home-manager" else
else "${config.home.homeDirectory}/.nixos-config";
"${config.home.homeDirectory}/.nixos-config"; in {
in
{
programs.topgrade = { programs.topgrade = {
enable = true; enable = true;
settings = { settings = {
@ -18,18 +16,13 @@ in
pre_sudo = false; pre_sudo = false;
cleanup = true; cleanup = true;
skip_notify = true; skip_notify = true;
disable = [ disable = [ "bun" "tldr" "flutter" ];
"bun"
"tldr"
"flutter"
];
}; };
git.repos = [ configPath ]; git.repos = [ configPath ];
firmware = { firmware = { upgrade = true; };
upgrade = true;
};
pre_commands = { pre_commands = {
flakeUpgrade = "cd ${configPath} && ${pkgs.nixVersions.latest}/bin/nix flake update --commit-lock-file --verbose --repair"; flakeUpgrade =
"cd ${configPath} && ${pkgs.nixVersions.latest}/bin/nix flake update --commit-lock-file --verbose --repair";
}; };
}; };
}; };

View file

@ -1,5 +1,2 @@
{ { programs.yt-dlp = { enable = true; }; }
programs.yt-dlp = {
enable = true;
};
}

View file

@ -1,9 +1,12 @@
# Call once on import to load global context # Call once on import to load global context
{ pkgs, config }: {
pkgs,
config,
}:
# Wrap a single package # Wrap a single package
pkg: pkg:
if config.nixGLPrefix == "" then if config.nixGLPrefix == ""
pkg then pkg
else else
# Wrap the package's binaries with nixGL, while preserving the rest of # Wrap the package's binaries with nixGL, while preserving the rest of
# the outputs and derivation attributes. # the outputs and derivation attributes.
@ -14,14 +17,12 @@ else
${ ${
# Heavily inspired by https://stackoverflow.com/a/68523368/6259505 # Heavily inspired by https://stackoverflow.com/a/68523368/6259505
pkgs.lib.concatStringsSep "\n" ( pkgs.lib.concatStringsSep "\n" (map (outputName: ''
map (outputName: '' echo "Copying output ${outputName}"
echo "Copying output ${outputName}" set -x
set -x cp -rs --no-preserve=mode "${pkg.${outputName}}" "''$${outputName}"
cp -rs --no-preserve=mode "${pkg.${outputName}}" "''$${outputName}" set +x
set +x '') (old.outputs or ["out"]))
'') (old.outputs or [ "out" ])
)
} }
rm -rf $out/bin/* rm -rf $out/bin/*
@ -33,4 +34,4 @@ else
done done
shopt -u nullglob # Revert nullglob back to its normal default state shopt -u nullglob # Revert nullglob back to its normal default state
''; '';
})) }))

View file

@ -24,8 +24,7 @@ let
chrome-stable-wrapper = pkgs.writeShellScriptBin "google-chrome-stable" '' chrome-stable-wrapper = pkgs.writeShellScriptBin "google-chrome-stable" ''
exec /usr/bin/google-chrome-stable ${chromeArgs} "$@" exec /usr/bin/google-chrome-stable ${chromeArgs} "$@"
''; '';
in in {
{
home.packages = with pkgs; [ home.packages = with pkgs; [
code-wrapper code-wrapper
chrome-wrapper chrome-wrapper

View file

@ -8,10 +8,7 @@
sandbox = relaxed sandbox = relaxed
''; '';
settings = { settings = {
trusted-users = [ trusted-users = [ "root" "thilo" ];
"root"
"thilo"
];
substituters = [ substituters = [
"https://cache.nixos.org" "https://cache.nixos.org"
"https://nix-community.cachix.org" "https://nix-community.cachix.org"

View file

@ -8,76 +8,71 @@
nix = { nix = {
distributedBuilds = true; distributedBuilds = true;
buildMachines = [ buildMachines = [ {
{ hostName = "build1.darmstadt.ccc.de";
hostName = "build1.darmstadt.ccc.de"; protocol = "ssh";
protocol = "ssh"; sshUser = "avocadoom";
sshUser = "avocadoom"; sshKey = "/home/thilo/.ssh/id_darmstadt-ccc-de";
sshKey = "/home/thilo/.ssh/id_darmstadt-ccc-de"; systems = [
systems = [ "i686-linux"
"i686-linux" "x86_64-linux"
"x86_64-linux" ];
]; maxJobs = 4;
maxJobs = 4; speedFactor = 6;
speedFactor = 6; supportedFeatures = [
supportedFeatures = [ "big-parallel"
"big-parallel" "kvm"
"kvm" "nixos-test"
"nixos-test" ];
]; } {
} hostName = "build2.darmstadt.ccc.de";
{ protocol = "ssh";
hostName = "build2.darmstadt.ccc.de"; sshUser = "avocadoom";
protocol = "ssh"; sshKey = "/home/thilo/.ssh/id_darmstadt-ccc-de";
sshUser = "avocadoom"; systems = [
sshKey = "/home/thilo/.ssh/id_darmstadt-ccc-de"; "i686-linux"
systems = [ "x86_64-linux"
"i686-linux" ];
"x86_64-linux" maxJobs = 4;
]; speedFactor = 6;
maxJobs = 4; supportedFeatures = [
speedFactor = 6; "big-parallel"
supportedFeatures = [ "kvm"
"big-parallel" "nixos-test"
"kvm" ];
"nixos-test" } {
]; hostName = "build3.darmstadt.ccc.de";
} protocol = "ssh";
{ sshUser = "avocadoom";
hostName = "build3.darmstadt.ccc.de"; sshKey = "/home/thilo/.ssh/id_darmstadt-ccc-de";
protocol = "ssh"; systems = [
sshUser = "avocadoom"; "i686-linux"
sshKey = "/home/thilo/.ssh/id_darmstadt-ccc-de"; "x86_64-linux"
systems = [ ];
"i686-linux" maxJobs = 4;
"x86_64-linux" speedFactor = 6;
]; supportedFeatures = [
maxJobs = 4; "big-parallel"
speedFactor = 6; "kvm"
supportedFeatures = [ "nixos-test"
"big-parallel" ];
"kvm" } {
"nixos-test" hostName = "build4.darmstadt.ccc.de";
]; protocol = "ssh";
} sshUser = "avocadoom";
{ sshKey = "/home/thilo/.ssh/id_darmstadt-ccc-de";
hostName = "build4.darmstadt.ccc.de"; systems = [
protocol = "ssh"; "i686-linux"
sshUser = "avocadoom"; "x86_64-linux"
sshKey = "/home/thilo/.ssh/id_darmstadt-ccc-de"; ];
systems = [ # this node has half the cpu of the others
"i686-linux" maxJobs = 2;
"x86_64-linux" speedFactor = 6;
]; supportedFeatures = [
# this node has half the cpu of the others "big-parallel"
maxJobs = 2; "kvm"
speedFactor = 6; "nixos-test"
supportedFeatures = [ ];
"big-parallel" } ];
"kvm"
"nixos-test"
];
}
];
}; };
} }

View file

@ -1,10 +1,4 @@
{ { config, pkgs, lib, inputs, ... }:
config,
pkgs,
lib,
inputs,
...
}:
{ {
imports = [ ./../nix.nix ]; imports = [ ./../nix.nix ];
@ -16,15 +10,13 @@
# This will additionally add your inputs to the system's legacy channels # This will additionally add your inputs to the system's legacy channels
# Making legacy nix commands consistent as well, awesome! # Making legacy nix commands consistent as well, awesome!
nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}") config.nix.registry; nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}")
config.nix.registry;
}; };
nixpkgs = { nixpkgs = {
config = { config = {
permittedInsecurePackages = [ permittedInsecurePackages = [ "electron-24.8.6" "electron-25.9.0" ];
"electron-24.8.6"
"electron-25.9.0"
];
allowUnfree = true; allowUnfree = true;
}; };
}; };
@ -86,12 +78,7 @@
}; };
}; };
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [ git zsh kitty steamtinkerlaunch ];
git
zsh
kitty
steamtinkerlaunch
];
networking.networkmanager.enable = true; networking.networkmanager.enable = true;
@ -104,9 +91,7 @@
pulse.enable = true; pulse.enable = true;
jack.enable = true; jack.enable = true;
}; };
tailscale = { tailscale = { enable = true; };
enable = true;
};
flatpak.enable = true; flatpak.enable = true;
avahi = { avahi = {
enable = true; enable = true;