Compare commits

..

No commits in common. "3b1d605c5daee8d47f5145ad00c8db8a88fb243d" and "ecad508d990fe2301d8849a13a851584ea77188a" have entirely different histories.

38 changed files with 438 additions and 347 deletions

View file

@ -1,29 +1,26 @@
{ config, lib, modulesPath, ... }: { config, lib, pkgs, modulesPath, ... }:
{ {
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot = { boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "usb_storage" "sd_mod" ];
initrd = { boot.initrd.kernelModules = [ ];
availableKernelModules = [ "nvme" "xhci_pci" "usb_storage" "sd_mod" ]; boot.kernelModules = [ "kvm-amd" ];
kernelModules = [ ]; boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/2e1227f6-8725-43a3-aeb6-961df4ed9b25";
fsType = "ext4";
}; };
kernelModules = [ "kvm-amd" ];
extraModulePackages = [ ];
};
fileSystems."/" = { boot.initrd.luks.devices."luks-6f077715-c436-4254-acb2-66d8be0a0c55".device = "/dev/disk/by-uuid/6f077715-c436-4254-acb2-66d8be0a0c55";
device = "/dev/disk/by-uuid/2e1227f6-8725-43a3-aeb6-961df4ed9b25";
fsType = "ext4";
};
boot.initrd.luks.devices."luks-6f077715-c436-4254-acb2-66d8be0a0c55".device = fileSystems."/boot" =
"/dev/disk/by-uuid/6f077715-c436-4254-acb2-66d8be0a0c55"; { device = "/dev/disk/by-uuid/877C-C918";
fsType = "vfat";
fileSystems."/boot" = { };
device = "/dev/disk/by-uuid/877C-C918";
fsType = "vfat";
};
swapDevices = [ ]; swapDevices = [ ];
@ -36,6 +33,5 @@
# 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 = hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
lib.mkDefault config.hardware.enableRedistributableFirmware;
} }

View file

@ -1,43 +1,44 @@
{ inputs, pkgs, ... }: { inputs, pkgs, ... }:
{ {
home-manager = { home-manager.useGlobalPkgs = true;
useGlobalPkgs = true; home-manager.useUserPackages = true;
useUserPackages = true; home-manager.extraSpecialArgs = { inherit inputs; };
extraSpecialArgs = { inherit inputs; }; home-manager.users.thilo = {
users.thilo = { imports = [
imports = [ ./../../home-manager/modules/machine.nix ]; ./../../home-manager/modules/machine.nix
];
machine = { machine = {
username = "thilo"; username = "thilo";
isGeneric = false; isGeneric = false;
isGnome = false; isGnome = false;
noiseSuppression.enable = true; noiseSuppression.enable = true;
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;
}; };
programs.obs-studio = { programs.obs-studio = {
enable = true; enable = true;
/* plugins = with pkgs.obs-studio-plugins; [ /* plugins = with pkgs.obs-studio-plugins; [
obs-vaapi obs-vaapi
obs-teleport obs-teleport
droidcam-obs droidcam-obs
obs-gstreamer obs-gstreamer
obs-shaderfilter obs-shaderfilter
obs-command-source obs-command-source
obs-move-transition obs-move-transition
advanced-scene-switcher advanced-scene-switcher
]; ]; */
*/ };
};
home.sessionVariables = { LD_LIBRARY_PATH = "${pkgs.libGL}/lib"; }; home.sessionVariables = {
LD_LIBRARY_PATH = "${pkgs.libGL}/lib";
}; };
}; };
} }

View file

@ -1,26 +1,35 @@
{ pkgs, ... }: {
config,
pkgs,
lib,
...
}:
{ {
imports = [ # Include the results of the hardware scan. imports =
./hardware-configuration.nix [ # Include the results of the hardware scan.
./../../nixos/common.nix ./hardware-configuration.nix
]; ./../../nixos/common.nix
];
# Bootloader. # Bootloader.
boot.loader = { boot.loader.systemd-boot.enable = true;
systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = true;
efi.canTouchEfiVariables = true;
};
# Setup keyfile # Setup keyfile
boot.initrd.secrets = { "/crypto_keyfile.bin" = null; }; boot.initrd.secrets = {
"/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; [ tracker tracker-miners ]; environment.gnome.excludePackages = with pkgs; [
tracker
tracker-miners
];
hardware.bluetooth.enable = true; hardware.bluetooth.enable = true;
@ -41,7 +50,10 @@
fwupd.enable = true; fwupd.enable = true;
}; };
environment.systemPackages = with pkgs; [ brlaser brgenml1lpr ]; environment.systemPackages = with pkgs; [
brlaser
brgenml1lpr
];
system.stateVersion = "23.05"; system.stateVersion = "23.05";
} }

View file

@ -1,38 +1,34 @@
# 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, pkgs, modulesPath, ... }:
{ {
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot = { boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "uas" "usb_storage" "sd_mod" ];
initrd = { boot.initrd.kernelModules = [ ];
availableKernelModules = boot.kernelModules = [ "kvm-amd" ];
[ "nvme" "xhci_pci" "ahci" "usbhid" "uas" "usb_storage" "sd_mod" ]; boot.extraModulePackages = [ ];
kernelModules = [ ];
};
kernelModules = [ "kvm-amd" ];
extraModulePackages = [ ];
};
fileSystems = { fileSystems."/" =
"/" = { { device = "/dev/disk/by-uuid/34eb30d5-5faa-409f-81ee-7b996d37534a";
device = "/dev/disk/by-uuid/34eb30d5-5faa-409f-81ee-7b996d37534a";
fsType = "btrfs"; fsType = "btrfs";
options = [ "subvol=@" ]; options = [ "subvol=@" ];
}; };
"/data" = { fileSystems."/data" =
{
device = "/dev/disk/by-uuid/91f64815-1d3c-4032-960f-0a53eb3b01ab"; device = "/dev/disk/by-uuid/91f64815-1d3c-4032-960f-0a53eb3b01ab";
fsType = "btrfs"; fsType = "btrfs";
}; };
"/boot" = { fileSystems."/boot" =
device = "/dev/disk/by-uuid/0EB3-BFB0"; { device = "/dev/disk/by-uuid/0EB3-BFB0";
fsType = "vfat"; fsType = "vfat";
}; };
};
swapDevices = [ ]; swapDevices = [ ];
@ -44,6 +40,5 @@
# 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 = hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
lib.mkDefault config.hardware.enableRedistributableFirmware;
} }

View file

@ -1,33 +1,37 @@
{ inputs, pkgs, ... }: { inputs, pkgs, ... }:
{ {
home-manager = { home-manager.useGlobalPkgs = true;
useGlobalPkgs = true; home-manager.useUserPackages = true;
useUserPackages = true; home-manager.extraSpecialArgs = { inherit inputs; };
extraSpecialArgs = { inherit inputs; }; home-manager.users.thilo = {
users.thilo = { imports = [
imports = [ ./../../home-manager/modules/machine.nix ]; ./../../home-manager/modules/machine.nix
];
machine = { machine = {
username = "thilo"; username = "thilo";
isGeneric = false; isGeneric = false;
isGnome = false; isGnome = false;
noiseSuppression.enable = true; noiseSuppression.enable = true;
isGraphical = true; isGraphical = true;
};
/* xsession.pointerCursor = {
name = "Bibata-Modern-Classic";
package = pkgs.bibata-cursors;
size = 128;
}; */
services.kdeconnect.enable = true;
services.kdeconnect.indicator = true;
home.sessionVariables = { LD_LIBRARY_PATH = "${pkgs.libGL}/lib"; };
home.packages = with pkgs; [ libsForQt5.discover ];
}; };
xsession.pointerCursor = {
name = "Bibata-Modern-Classic";
package = pkgs.bibata-cursors;
size = 128;
};
services.kdeconnect.enable = true;
services.kdeconnect.indicator = true;
home.sessionVariables = {
LD_LIBRARY_PATH = "${pkgs.libGL}/lib";
};
home.packages = with pkgs; [
libsForQt5.discover
];
}; };
} }

View file

@ -1,7 +1,11 @@
# Edit this configuration file to define what should be installed on # Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page # your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help). # and in the NixOS manual (accessible by running nixos-help).
{ pkgs, ... }: { config
, pkgs
, lib
, ...
}:
{ {
imports = [ imports = [
@ -11,18 +15,12 @@
]; ];
# Bootloader. # Bootloader.
boot = { boot.loader.systemd-boot.enable = true;
loader = { boot.loader.efi.canTouchEfiVariables = true;
systemd-boot = { boot.loader.systemd-boot.extraInstallCommands = ''
enable = true; ${pkgs.gnused}/bin/sed -i "/default/c\default @saved" /boot/loader/loader.conf
extraInstallCommands = '' '';
${pkgs.gnused}/bin/sed -i "/default/c\default @saved" /boot/loader/loader.conf boot.kernelPackages = pkgs.linuxPackages_latest;
'';
};
efi.canTouchEfiVariables = true;
};
kernelPackages = pkgs.linuxPackages_latest;
};
networking.hostName = "thilo-pc"; networking.hostName = "thilo-pc";
@ -31,15 +29,18 @@
xserver = { xserver = {
enable = true; enable = true;
displayManager.sddm.enable = true; displayManager.sddm.enable = true;
displayManager.defaultSession = "plasma"; displayManager.defaultSession = "plasmawayland";
desktopManager.plasma6.enable = true; desktopManager.plasma5.enable = true;
layout = "us"; layout = "us";
xkbVariant = ""; xkbVariant = "";
}; };
}; };
hardware.opengl = { hardware.opengl = {
extraPackages = with pkgs; [ vaapiVdpau libvdpau-va-gl ]; extraPackages = with pkgs; [
vaapiVdpau
libvdpau-va-gl
];
}; };
system.stateVersion = "23.05"; system.stateVersion = "23.05";

View file

@ -1,13 +1,15 @@
{ ... }: { inputs, ... }:
{ {
imports = [ ./../../home-manager/modules/machine.nix ]; imports = [
./../../home-manager/modules/machine.nix
];
machine = { machine = {
username = "thilo"; username = "thilo";
isGeneric = true; isGeneric = true;
isGnome = false; isGnome = false;
noiseSuppression.enable = false; noiseSuppression.enable = false;
isGraphical = false; isGraphical = false;
}; };
} }

View file

@ -7,11 +7,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1709049058, "lastModified": 1708440115,
"narHash": "sha256-RLag2Uy3wezy+oW+bsEwloDRaxV9BV/QdzHmSz1Ciwo=", "narHash": "sha256-j3n3LiEmsn2V5HqhzHf+nh7JrHGbFmzLMm9qnmzFPxw=",
"owner": "dagger", "owner": "dagger",
"repo": "nix", "repo": "nix",
"rev": "c4d98a163455709a6d8bba53465854981e115c15", "rev": "b489ac4da2e88296611e5841f4580ebc185d7b83",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -119,11 +119,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1709204054, "lastModified": 1708806879,
"narHash": "sha256-U1idK0JHs1XOfSI1APYuXi4AEADf+B+ZU4Wifc0pBHk=", "narHash": "sha256-MSbxtF3RThI8ANs/G4o1zIqF5/XlShHvwjl9Ws0QAbI=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "2f3367769a93b226c467551315e9e270c3f78b15", "rev": "4ee704cb13a5a7645436f400b9acc89a67b9c08a",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -381,11 +381,11 @@
}, },
"nixpkgs_5": { "nixpkgs_5": {
"locked": { "locked": {
"lastModified": 1709150264, "lastModified": 1708807242,
"narHash": "sha256-HofykKuisObPUfj0E9CJVfaMhawXkYx3G8UIFR/XQ38=", "narHash": "sha256-sRTRkhMD4delO/hPxxi+XwLqPn8BuUq6nnj4JqLwOu0=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "9099616b93301d5cf84274b184a3a5ec69e94e08", "rev": "73de017ef2d18a04ac4bfd0c02650007ccb31c2a",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -2,8 +2,12 @@
description = "Nixos config"; description = "Nixos config";
inputs = { inputs = {
nixpkgs = { url = "github:NixOS/nixpkgs/nixos-unstable"; }; nixpkgs = {
nixpkgs-update = { url = "github:ryantm/nixpkgs-update"; }; url = "github:NixOS/nixpkgs/nixos-unstable";
};
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";
@ -16,16 +20,19 @@
muse-sounds-manager.url = "github:thilobillerbeck/muse-sounds-manager-nix"; muse-sounds-manager.url = "github:thilobillerbeck/muse-sounds-manager-nix";
}; };
outputs = { nixpkgs, home-manager, nixgl, ... }@inputs: outputs = { self, nixpkgs, home-manager, nixgl, ... }@inputs:
let let
system = "x86_64-linux"; system = "x86_64-linux";
pkgs = import nixpkgs { pkgs = import nixpkgs {
system = "${system}"; system = "${system}";
overlays = [ nixgl.overlay ]; overlays = [ nixgl.overlay ];
}; };
in { in
{
nixConfig = { nixConfig = {
extra-substituters = [ "https://nix-community.cachix.org" ]; extra-substituters = [
"https://nix-community.cachix.org"
];
extra-trusted-public-keys = [ extra-trusted-public-keys = [
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
]; ];
@ -48,11 +55,10 @@
]; ];
specialArgs = { inherit inputs; }; specialArgs = { inherit inputs; };
}; };
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 = { inherit inputs; };
extraSpecialArgs = { inherit inputs; }; };
};
}; };
} }

View file

@ -1,5 +1,6 @@
{ lib, pkgs, config, ... }: { lib, pkgs, config, ... }:
with lib; { with lib;
{
imports = [ imports = [
./../programs/alacritty.nix ./../programs/alacritty.nix
./../programs/bat.nix ./../programs/bat.nix
@ -69,9 +70,8 @@ with lib; {
include "/usr/share/nano/*.nanorc" include "/usr/share/nano/*.nanorc"
''; '';
".ssh/config_source" = { ".ssh/config_source" = {
source = ./../dotfiles/ssh-config; source = ./../dotfiles/ssh-config;
onChange = onChange = ''cat ~/.ssh/config_source > ~/.ssh/config && chmod 600 ~/.ssh/config'';
"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 = ''

View file

@ -2,126 +2,128 @@
with lib; with lib;
let let
electronFlags = electronFlags = "--enable-features=UseOzonePlatform --ozone-platform=wayland --enable-wayland-ime --disable-gpu-shader-disk-cache -n";
"--enable-features=UseOzonePlatform --ozone-platform=wayland --enable-wayland-ime --disable-gpu-shader-disk-cache -n";
in { in {
config = { config = {
nixpkgs.overlays = [ nixpkgs.overlays = [
(_: prev: { (final: prev: {
quickemu = prev.quickemu.overrideAttrs (old: { quickemu = prev.quickemu.overrideAttrs (old: {
patches = (old.patches or [ ]) ++ [ ./../patches/quickemu.patch ]; patches = (old.patches or [ ]) ++ [
./../patches/quickemu.patch
];
}); });
}) })
]; ];
home.packages = with pkgs; home.packages = with pkgs; [
[ up
up htop
htop rustc
rustc cargo
cargo nixfmt
nixfmt nodejs
nodejs bun
bun deno
deno devbox
devbox tldr
tldr flutter
flutter nurl
nurl hcloud
hcloud tea
tea dgraph
dgraph nix-init
nix-init nodePackages.nodemon
nodePackages.nodemon pocketbase
pocketbase thefuck
thefuck 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"
(pkgs.writeShellScriptBin "nix-shell-init" (builtins.readFile ./../scripts/nix-shell-init.sh))
(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 '')
'') (pkgs.writeShellScriptBin "nix-build-default" ''
(pkgs.writeShellScriptBin "nix-build-default" '' nix-build -E 'with import <nixpkgs> { }; callPackage ./default.nix { }'
nix-build -E 'with import <nixpkgs> { }; callPackage ./default.nix { }' '')
'') (callPackage ./../pkgs/toggl-time-grouper/package.nix {
(callPackage ./../pkgs/toggl-time-grouper/package.nix { inherit python3Packages; }) inherit lib;
nixpkgs-fmt })
toolbox nixpkgs-fmt
distrobox toolbox
ddev distrobox
act ddev
mkcert act
pulumi mkcert
kubectl pulumi
pulumiPackages.pulumi-language-nodejs kubectl
ncdu pulumiPackages.pulumi-language-nodejs
inputs.devenv.packages.x86_64-linux.devenv ncdu
inputs.nixpkgs-update.packages.x86_64-linux.nixpkgs-update inputs.devenv.packages.x86_64-linux.devenv
inputs.dagger.packages.x86_64-linux.dagger inputs.nixpkgs-update.packages.x86_64-linux.nixpkgs-update
unzip inputs.dagger.packages.x86_64-linux.dagger
gh unzip
nil gh
nixd nil
unrar nixd
] ++ (if config.machine.isGraphical then [ unrar
(pkgs.nerdfonts.override { ] ++ (if config.machine.isGraphical then [
fonts = [ "JetBrainsMono" "FiraCode" "FiraMono" ]; (pkgs.nerdfonts.override {
}) fonts = [ "JetBrainsMono" "FiraCode" "FiraMono" ];
corefonts })
vistafonts corefonts
jetbrains.webstorm vistafonts
jetbrains.phpstorm jetbrains.webstorm
jetbrains.rust-rover jetbrains.phpstorm
jetbrains.goland jetbrains.rust-rover
element-desktop jetbrains.goland
ludusavi element-desktop
dbeaver ludusavi
insomnia dbeaver
onlyoffice-bin insomnia
spotify onlyoffice-bin
vesktop spotify
(lutris.override { vesktop
extraLibraries = _: [ gnome3.adwaita-icon-theme ]; (lutris.override {
extraPkgs = _: [ extraLibraries = pkgs: [
wineWowPackages.full gnome3.adwaita-icon-theme
winetricks ];
gnome3.adwaita-icon-theme extraPkgs = pkgs: [
]; wineWowPackages.full
}) winetricks
bottles gnome3.adwaita-icon-theme
protontricks ];
heroic })
(vscode.override { commandLineArgs = electronFlags; }) bottles
quickemu protontricks
quickgui heroic
trilium-desktop (vscode.override { commandLineArgs = electronFlags; })
anki quickemu
inputs.muse-sounds-manager.packages.x86_64-linux.muse-sounds-manager quickgui
jetbrains-toolbox trilium-desktop
mumble anki
prusa-slicer inputs.muse-sounds-manager.packages.x86_64-linux.muse-sounds-manager
trayscale jetbrains-toolbox
gnome.gnome-disk-utility mumble
inkscape prusa-slicer
# musescore trayscale
obsidian gnome.gnome-disk-utility
syncthingtray inkscape
reaper musescore
yabridge obsidian
] else syncthingtray
[ ]) ++ (if config.machine.isGnome then [ reaper
gnomeExtensions.blur-my-shell yabridge
gnomeExtensions.dash-to-panel ] else [ ]) ++ (if config.machine.isGnome then [
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,4 +1,7 @@
{ lib, stdenv, fetchFromGitHub }: { lib
, stdenv
, fetchFromGitHub
}:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "docker-craft-cms-dev-env"; pname = "docker-craft-cms-dev-env";
@ -17,8 +20,7 @@ stdenv.mkDerivation rec {
''; '';
meta = with lib; { meta = with lib; {
description = description = "Docker image for local development of sites based on Craft CMS";
"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,4 +1,8 @@
{ lib, buildNpmPackage, fetchFromGitHub }: { lib
, stdenv
, buildNpmPackage
, fetchFromGitHub
}:
buildNpmPackage rec { buildNpmPackage rec {
pname = "spx-gc"; pname = "spx-gc";
@ -21,8 +25,7 @@ buildNpmPackage rec {
''; '';
meta = with lib; { meta = with lib; {
description = description = "SPX is a graphics control client for live video productions and live streams using CasparCG, OBS, vMix, or similar software";
"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,7 +1,7 @@
{ python3Packages }: { lib, python3Packages }:
with python3Packages; with python3Packages;
buildPythonApplication { buildPythonApplication {
name = "toggl-time-grouper"; name = "toggl-time-grouper";
src = ./.; src = ./.;
propagatedBuildInputs = [ pandas ]; propagatedBuildInputs = [ pandas ];
} }

View file

@ -1,4 +1,4 @@
{ config, ... }: { config, pkgs, lib, ... }:
{ {
programs.alacritty = { programs.alacritty = {

View file

@ -1 +1,5 @@
{ programs.bat = { enable = true; }; } { config, pkgs, lib, ... }:
{
programs.bat = { enable = true; };
}

View file

@ -1,3 +1,5 @@
{ config, pkgs, lib, ... }:
{ {
programs.beets = { programs.beets = {
enable = false; enable = false;

View file

@ -22,23 +22,30 @@ let
isEnabled = if config.machine.isGraphical then true else false; isEnabled = if config.machine.isGraphical then true else false;
dictionaries = with pkgs.hunspellDictsChromium; [ en_US de_DE ]; dictionaries = with pkgs.hunspellDictsChromium; [ en_US de_DE ];
commandLineArgs = [ commandLineArgs = [
"--ignore-gpu-blocklist" "--ignore-gpu-blocklist"
"--enable-gpu-rasterization" "--enable-gpu-rasterization"
"--enable-zero-copy" "--enable-zero-copy"
"--enable-features=VaapiVideoDecoder,VaapiVideoEncoder,WebRTCPipeWireCapturer" "--enable-features=VaapiVideoDecoder,VaapiVideoEncoder,WebRTCPipeWireCapturer"
"--disable-features=UseChromeOSDirectVideoDecoder" "--disable-features=UseChromeOSDirectVideoDecoder"
"--use-vulkan" "--use-vulkan"
"--ozone-platform-hint=auto" "--ozone-platform-hint=auto"
"--enable-hardware-overlays" "--enable-hardware-overlays"
]; ];
extensions = map (eid: { id = eid; }) chromium_extension; extensions = map
in { (eid: {
id = eid;
})
chromium_extension;
in
{
programs.chromium = { programs.chromium = {
inherit dictionaries commandLineArgs extensions;
enable = isEnabled; enable = isEnabled;
dictionaries = dictionaries;
commandLineArgs = commandLineArgs;
extensions = extensions;
}; };
programs.google-chrome = { programs.google-chrome = {
inherit commandLineArgs;
enable = isEnabled; enable = isEnabled;
commandLineArgs = commandLineArgs;
}; };
} }

View file

@ -1 +1,5 @@
{ programs.command-not-found = { enable = true; }; } { config, pkgs, lib, ... }:
{
programs.command-not-found = { enable = true; };
}

View file

@ -1,3 +1,5 @@
{ config, pkgs, lib, ... }:
{ {
programs.dircolors = { programs.dircolors = {
enable = true; enable = true;

View file

@ -1,3 +1,5 @@
{ config, pkgs, lib, ... }:
{ {
programs.direnv = { programs.direnv = {
enable = true; enable = true;

View file

@ -4,4 +4,4 @@
programs.firefox = { programs.firefox = {
enable = if config.machine.isGraphical then true else false; enable = if config.machine.isGraphical then true else false;
}; };
} }

View file

@ -1,3 +1,5 @@
{ config, pkgs, lib, ... }:
{ {
programs.fzf = { programs.fzf = {
enable = true; enable = true;

View file

@ -1,4 +1,4 @@
{ pkgs, ... }: { config, pkgs, lib, ... }:
{ {
programs.git = { programs.git = {
@ -27,5 +27,7 @@
branch = { autosetuprebase = "always"; }; branch = { autosetuprebase = "always"; };
}; };
}; };
programs.git-credential-oauth = { enable = true; }; programs.git-credential-oauth = {
enable = true;
};
} }

View file

@ -1 +1,7 @@
{ programs.go = { enable = true; }; } { config, pkgs, lib, ... }:
{
programs.go = {
enable = true;
};
}

View file

@ -1 +1,5 @@
{ programs.hstr = { enable = true; }; } { config, pkgs, lib, ... }:
{
programs.hstr = { enable = true; };
}

View file

@ -1,3 +1,5 @@
{ config, pkgs, lib, ... }:
{ {
programs.htop = { programs.htop = {
enable = true; enable = true;

View file

@ -5,4 +5,4 @@
enable = if config.machine.isGraphical then true else false; enable = if config.machine.isGraphical then true else false;
scripts = with pkgs.mpvScripts; [ autoload mpris sponsorblock ]; scripts = with pkgs.mpvScripts; [ autoload mpris sponsorblock ];
}; };
} }

View file

@ -1,4 +1,4 @@
{ pkgs, ... }: { config, pkgs, lib, ... }:
{ {
programs.neovim = { programs.neovim = {

View file

@ -1,3 +1,5 @@
{ config, pkgs, lib, ... }:
{ {
programs.starship = { programs.starship = {
enable = true; enable = true;

View file

@ -1 +1,7 @@
{ services.syncthing = { enable = true; }; } { config, pkgs, lib, ... }:
{
services.syncthing = {
enable = true;
};
}

View file

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

View file

@ -1,2 +1,6 @@
{ programs.yt-dlp = { enable = true; }; } { config, pkgs, lib, ... }:
{
programs.yt-dlp = { enable = true; };
}

View file

@ -1,4 +1,4 @@
{ pkgs, ... }: { config, pkgs, lib, ... }:
let let
omz-plugins = [ omz-plugins = [
"git" "git"

View file

@ -1,4 +1,5 @@
{ pkgs, lib, ... }:
{ config, pkgs, lib, ... }:
let let
chromeArgs = lib.strings.concatStringsSep " " [ chromeArgs = lib.strings.concatStringsSep " " [
@ -15,15 +16,15 @@ let
"--ozone-platform-hint=auto" "--ozone-platform-hint=auto"
"--enable-features=WaylandWindowDecorations" "--enable-features=WaylandWindowDecorations"
]; ];
code-wrapper = pkgs.writeShellScriptBin "code" '' code-wrapper = (pkgs.writeShellScriptBin "code" ''
exec /usr/bin/code ${codeArgs} "$@" exec /usr/bin/code ${codeArgs} "$@"
''; '');
chrome-wrapper = pkgs.writeShellScriptBin "google-chrome" '' chrome-wrapper = (pkgs.writeShellScriptBin "google-chrome" ''
exec /usr/bin/google-chrome ${chromeArgs} "$@" exec /usr/bin/google-chrome ${chromeArgs} "$@"
''; '');
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
@ -201,7 +202,7 @@ in {
Name[vi]=Ca s Mi Name[vi]=Ca s Mi
Name[zh_CN]= Name[zh_CN]=
Name[zh_TW]= Name[zh_TW]=
Exec=/usr/bin/google-chrome-stable ${chromeArgs} Exec=/usr/bin/google-chrome-stable ${chromeArgs}
[Desktop Action new-private-window] [Desktop Action new-private-window]
Name=New Incognito Window Name=New Incognito Window

View file

View file

@ -8,15 +8,18 @@
sandbox = relaxed sandbox = relaxed
''; '';
settings = { settings = {
trusted-users = [ "root" "thilo" ]; trusted-users = [
"root"
"thilo"
];
trusted-substituters = [ trusted-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="

View file

@ -1,22 +1,31 @@
{ config, pkgs, lib, inputs, ... }: { config
, pkgs
, lib
, inputs
, ...
}:
{ {
imports = [ ./../nix.nix ]; imports = [
./../nix.nix
];
nix = { nix = {
# This will add each flake input as a registry # This will add each flake input as a registry
# To make nix3 commands consistent with your flake # To make nix3 commands consistent with your flake
registry = lib.mapAttrs (_: value: { flake = value; }) inputs; registry = lib.mapAttrs (_: value: {flake = value;}) inputs;
# 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}") nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}") config.nix.registry;
config.nix.registry;
}; };
nixpkgs = { nixpkgs = {
config = { config = {
permittedInsecurePackages = [ "electron-24.8.6" "electron-25.9.0" ]; permittedInsecurePackages = [
"electron-24.8.6"
"electron-25.9.0"
];
allowUnfree = true; allowUnfree = true;
}; };
}; };
@ -35,7 +44,7 @@
LC_TIME = "de_DE.UTF-8"; LC_TIME = "de_DE.UTF-8";
}; };
users.users.thilo = { users.users.thilo = {
uid = 1000; uid = 1000;
description = "Thilo Billerbeck"; description = "Thilo Billerbeck";
shell = pkgs.zsh; shell = pkgs.zsh;
@ -76,7 +85,12 @@
noisetorch.enable = true; noisetorch.enable = true;
}; };
environment.systemPackages = with pkgs; [ git zsh kitty steamtinkerlaunch ]; environment.systemPackages = with pkgs; [
git
zsh
kitty
steamtinkerlaunch
];
networking.networkmanager.enable = true; networking.networkmanager.enable = true;
@ -89,7 +103,9 @@
pulse.enable = true; pulse.enable = true;
jack.enable = true; jack.enable = true;
}; };
tailscale = { enable = true; }; tailscale = {
enable = true;
};
flatpak.enable = true; flatpak.enable = true;
avahi = { avahi = {
enable = true; enable = true;
@ -101,17 +117,13 @@
}; };
}; };
hardware = { hardware.opengl.driSupport = true;
pulseaudio.enable = false; hardware.opengl.driSupport32Bit = true;
opengl = {
driSupport = true;
driSupport32Bit = true;
};
};
security.polkit.enable = true; security.polkit.enable = true;
sound.enable = true; sound.enable = true;
hardware.pulseaudio.enable = false;
security.rtkit.enable = true; security.rtkit.enable = true;
time.hardwareClockInLocalTime = true; time.hardwareClockInLocalTime = true;
} }