Do a TON of organising into seperate files
This commit is contained in:
parent
b42afdda7e
commit
823361a999
20 changed files with 396 additions and 116 deletions
18
nixos/common/corectrl.nix
Normal file
18
nixos/common/corectrl.nix
Normal file
|
@ -0,0 +1,18 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
nix-your-shell,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
programs.corectrl = {
|
||||
enable = true;
|
||||
gpuOverclock = {
|
||||
enable = true;
|
||||
ppfeaturemask = "0xffffffff";
|
||||
};
|
||||
};
|
||||
}
|
36
nixos/common/steam.nix
Normal file
36
nixos/common/steam.nix
Normal file
|
@ -0,0 +1,36 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
nix-your-shell,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
programs.steam = {
|
||||
enable = true;
|
||||
package = pkgs.steam.override {
|
||||
extraPkgs = (
|
||||
pkgs:
|
||||
with pkgs;
|
||||
with unstable;
|
||||
[
|
||||
gamemode
|
||||
unstable.mangohud
|
||||
# additional packages...
|
||||
# e.g. some games require python3
|
||||
]
|
||||
);
|
||||
};
|
||||
|
||||
remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play
|
||||
dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server
|
||||
localNetworkGameTransfers.openFirewall = true; # Open ports in the firewall for Steam Local Network Game Transfers
|
||||
};
|
||||
programs.steam.gamescopeSession.enable = true;
|
||||
programs.steam.protontricks.enable = true;
|
||||
hardware.steam-hardware.enable = true;
|
||||
programs.gamescope.enable = true;
|
||||
programs.gamemode.enable = true;
|
||||
}
|
12
nixos/common/template.nix
Normal file
12
nixos/common/template.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
nix-your-shell,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
|
||||
}
|
15
nixos/common/video-capture.nix
Normal file
15
nixos/common/video-capture.nix
Normal file
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
nix-your-shell,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
programs.gpu-screen-recorder = {
|
||||
enable = true;
|
||||
package = unstable.gpu-screen-recorder;
|
||||
};
|
||||
}
|
17
nixos/common/virtualisation.nix
Normal file
17
nixos/common/virtualisation.nix
Normal file
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
nix-your-shell,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
virtualisation.docker.enable = true;
|
||||
virtualisation.docker.storageDriver = "btrfs";
|
||||
# virtualisation.docker.rootless = {
|
||||
# enable = true;
|
||||
# setSocketVariable = true;
|
||||
# };
|
||||
}
|
4
nixos/flake.lock
generated
4
nixos/flake.lock
generated
|
@ -327,11 +327,11 @@
|
|||
"locked": {
|
||||
"lastModified": 1,
|
||||
"narHash": "sha256-rADqSJu492bURPi5fmvPyeG1B5bV3k2hfGR+VfHn1Ig=",
|
||||
"path": "/nix/store/0xvl9qqlmfb4vr5c7kd4rd94df9qwnxp-source/nixos/programs/shadps4",
|
||||
"path": "/nix/store/waqwlk8xamf15iybdy26hll1s1bj4nk6-source/nixos/programs/shadps4",
|
||||
"type": "path"
|
||||
},
|
||||
"original": {
|
||||
"path": "/nix/store/0xvl9qqlmfb4vr5c7kd4rd94df9qwnxp-source/nixos/programs/shadps4",
|
||||
"path": "/nix/store/waqwlk8xamf15iybdy26hll1s1bj4nk6-source/nixos/programs/shadps4",
|
||||
"type": "path"
|
||||
}
|
||||
},
|
||||
|
|
|
@ -75,8 +75,13 @@
|
|||
|
||||
};
|
||||
modules = [
|
||||
./universal.nix
|
||||
./nix-ld.nix
|
||||
./common/universal.nix
|
||||
./common/nix-ld.nix
|
||||
./common/steam.nix
|
||||
./common/virtualisation.nix
|
||||
./common/corectrl.nix
|
||||
./common/video-capture.nix
|
||||
|
||||
./hosts/nixos/configuration.nix
|
||||
./hosts/nixos/services.nix
|
||||
|
||||
|
@ -106,8 +111,9 @@
|
|||
|
||||
};
|
||||
modules = [
|
||||
./universal.nix
|
||||
./nix-ld.nix
|
||||
./common/universal.nix
|
||||
./common/nix-ld.nix
|
||||
./common/corectrl.nix
|
||||
./hosts/low-power-laptop/configuration.nix
|
||||
|
||||
home-manager.nixosModules.home-manager
|
||||
|
|
|
@ -13,6 +13,12 @@
|
|||
./nixos/services.nix
|
||||
|
||||
./packages/gamedev.nix
|
||||
./packages/gaming.nix
|
||||
./packages/game-extras.nix
|
||||
./packages/emulation.nix
|
||||
./packages/wine.nix
|
||||
./packages/video-capture.nix
|
||||
./packages/video-prod.nix
|
||||
|
||||
./packages/common-cli.nix
|
||||
./packages/common-desktop.nix
|
||||
|
|
|
@ -9,12 +9,6 @@
|
|||
|
||||
{
|
||||
|
||||
home.file."jdks/zulujdk8".source = pkgs.zulu8;
|
||||
home.file."jdks/zulujdk17".source = pkgs.zulu17;
|
||||
home.file."jdks/zulujdk23".source = pkgs.zulu23;
|
||||
|
||||
home.file."bin/wine".source = unstable.wineWowPackages.waylandFull;
|
||||
|
||||
# The home.packages option allows you to install Nix packages into your
|
||||
# environment.
|
||||
home.packages =
|
||||
|
@ -26,26 +20,6 @@
|
|||
pkgs.monero-gui
|
||||
unstable.kiwix
|
||||
|
||||
# pkgs.protonplus
|
||||
unstable.pcsx2
|
||||
pkgs.rpcs3
|
||||
unstable.ryubing
|
||||
unstable.torzu
|
||||
pkgs.heroic-unwrapped
|
||||
unstable.ludusavi
|
||||
inputs.shadps4-git.packages."x86_64-linux".default
|
||||
|
||||
unstable.wineWowPackages.waylandFull
|
||||
unstable.winetricks
|
||||
steamtinkerlaunch
|
||||
|
||||
# === Minecraft ===
|
||||
pkgs.prismlauncher
|
||||
# pkgs.zulu8
|
||||
# pkgs.zulu17
|
||||
# pkgs.zulu23
|
||||
# === Minecraft ===
|
||||
|
||||
# === CLI ===
|
||||
pkgs.rrsync
|
||||
pkgs.poop # Compare the performance of multiple commands with a colorful terminal user interface
|
||||
|
@ -65,23 +39,13 @@
|
|||
pkgs.imagemagick
|
||||
# === Image CLI ===
|
||||
|
||||
# === Game perf ===
|
||||
unstable.mangojuice
|
||||
unstable.goverlay
|
||||
# === Game perf ===
|
||||
|
||||
# === Dev tooling ===
|
||||
# pkgs.rustup
|
||||
# === Dev tooling ===
|
||||
|
||||
# pkgs.polychromatic
|
||||
|
||||
pkgs.lazydocker
|
||||
pkgs.distrobox
|
||||
pkgs.boxbuddy
|
||||
|
||||
unstable.gpu-screen-recorder-gtk
|
||||
gsr-ui.gpu-screen-recorder-ui
|
||||
|
||||
# # You can also create simple shell scripts directly inside your
|
||||
# # configuration. For example, this adds a command 'my-hello' to your
|
||||
|
@ -91,25 +55,6 @@
|
|||
# '')
|
||||
];
|
||||
|
||||
programs.mangohud = {
|
||||
enable = true;
|
||||
enableSessionWide = true;
|
||||
package = unstable.mangohud;
|
||||
};
|
||||
|
||||
programs.obs-studio = {
|
||||
enable = true;
|
||||
plugins = with pkgs.obs-studio-plugins; [
|
||||
wlrobs
|
||||
obs-vkcapture
|
||||
obs-pipewire-audio-capture
|
||||
obs-teleport
|
||||
obs-source-record
|
||||
obs-source-clone
|
||||
obs-composite-blur
|
||||
];
|
||||
};
|
||||
|
||||
# === ssh ===
|
||||
programs.ssh.matchBlocks = {
|
||||
"*" = {
|
||||
|
|
32
nixos/home-manager/packages/emulation.nix
Normal file
32
nixos/home-manager/packages/emulation.nix
Normal file
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
withExtraPackages =
|
||||
pkg: extraPackages:
|
||||
pkgs.runCommand "${pkg.name}-wrapped" { nativeBuildInputs = [ pkgs.makeWrapper ]; } ''
|
||||
for exe in ${lib.getBin pkg}/bin/*; do
|
||||
makeWrapper $exe $out/bin/$(basename $exe) --prefix PATH : ${lib.makeBinPath extraPackages}
|
||||
done
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
||||
home.packages =
|
||||
with unstable;
|
||||
with inputs;
|
||||
[
|
||||
unstable.pcsx2
|
||||
unstable.rpcs3
|
||||
unstable.ryubing
|
||||
unstable.torzu
|
||||
inputs.shadps4-git.packages."x86_64-linux".default
|
||||
];
|
||||
}
|
||||
|
32
nixos/home-manager/packages/game-extras.nix
Normal file
32
nixos/home-manager/packages/game-extras.nix
Normal file
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
withExtraPackages =
|
||||
pkg: extraPackages:
|
||||
pkgs.runCommand "${pkg.name}-wrapped" { nativeBuildInputs = [ pkgs.makeWrapper ]; } ''
|
||||
for exe in ${lib.getBin pkg}/bin/*; do
|
||||
makeWrapper $exe $out/bin/$(basename $exe) --prefix PATH : ${lib.makeBinPath extraPackages}
|
||||
done
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
||||
home.packages =
|
||||
with unstable;
|
||||
with inputs;
|
||||
[
|
||||
# === Factorio related ===
|
||||
unstable.yafc-ce
|
||||
unstable.pactorio
|
||||
unstable.factoriolab
|
||||
# === Factorio related ===
|
||||
];
|
||||
}
|
||||
|
51
nixos/home-manager/packages/gameing.nix
Normal file
51
nixos/home-manager/packages/gameing.nix
Normal file
|
@ -0,0 +1,51 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
withExtraPackages =
|
||||
pkg: extraPackages:
|
||||
pkgs.runCommand "${pkg.name}-wrapped" { nativeBuildInputs = [ pkgs.makeWrapper ]; } ''
|
||||
for exe in ${lib.getBin pkg}/bin/*; do
|
||||
makeWrapper $exe $out/bin/$(basename $exe) --prefix PATH : ${lib.makeBinPath extraPackages}
|
||||
done
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
||||
# === Java versions for MC ===
|
||||
home.file."jdks/zulujdk8".source = pkgs.zulu8;
|
||||
home.file."jdks/zulujdk17".source = pkgs.zulu17;
|
||||
home.file."jdks/zulujdk23".source = pkgs.zulu23;
|
||||
# === Java versions for MC ===
|
||||
|
||||
home.packages =
|
||||
with unstable;
|
||||
with inputs;
|
||||
[
|
||||
# === Minecraft related ===
|
||||
unstable.modrinth-app
|
||||
unstable.prismlauncher
|
||||
# === Minecraft related ===
|
||||
|
||||
unstable.steamtinkerlaunch
|
||||
pkgs.heroic-unwrapped
|
||||
unstable.ludusavi
|
||||
|
||||
# === Game perf ===
|
||||
unstable.mangojuice
|
||||
unstable.goverlay
|
||||
# === Game perf ===
|
||||
];
|
||||
|
||||
programs.mangohud = {
|
||||
enable = true;
|
||||
enableSessionWide = true;
|
||||
package = unstable.mangohud;
|
||||
};
|
||||
}
|
28
nixos/home-manager/packages/template.nix
Normal file
28
nixos/home-manager/packages/template.nix
Normal file
|
@ -0,0 +1,28 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
withExtraPackages =
|
||||
pkg: extraPackages:
|
||||
pkgs.runCommand "${pkg.name}-wrapped" { nativeBuildInputs = [ pkgs.makeWrapper ]; } ''
|
||||
for exe in ${lib.getBin pkg}/bin/*; do
|
||||
makeWrapper $exe $out/bin/$(basename $exe) --prefix PATH : ${lib.makeBinPath extraPackages}
|
||||
done
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
||||
home.packages =
|
||||
with unstable;
|
||||
with inputs;
|
||||
[
|
||||
|
||||
];
|
||||
|
||||
}
|
42
nixos/home-manager/packages/video-capture.nix
Normal file
42
nixos/home-manager/packages/video-capture.nix
Normal file
|
@ -0,0 +1,42 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
withExtraPackages =
|
||||
pkg: extraPackages:
|
||||
pkgs.runCommand "${pkg.name}-wrapped" { nativeBuildInputs = [ pkgs.makeWrapper ]; } ''
|
||||
for exe in ${lib.getBin pkg}/bin/*; do
|
||||
makeWrapper $exe $out/bin/$(basename $exe) --prefix PATH : ${lib.makeBinPath extraPackages}
|
||||
done
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
||||
home.packages =
|
||||
with unstable;
|
||||
with inputs;
|
||||
[
|
||||
unstable.gpu-screen-recorder-gtk
|
||||
gsr-ui.gpu-screen-recorder-ui
|
||||
];
|
||||
|
||||
programs.obs-studio = {
|
||||
enable = true;
|
||||
plugins = with pkgs.obs-studio-plugins; [
|
||||
wlrobs
|
||||
obs-vkcapture
|
||||
obs-pipewire-audio-capture
|
||||
obs-teleport
|
||||
obs-source-record
|
||||
obs-source-clone
|
||||
obs-composite-blur
|
||||
];
|
||||
};
|
||||
|
||||
}
|
32
nixos/home-manager/packages/video-prod.nix
Normal file
32
nixos/home-manager/packages/video-prod.nix
Normal file
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
withExtraPackages =
|
||||
pkg: extraPackages:
|
||||
pkgs.runCommand "${pkg.name}-wrapped" { nativeBuildInputs = [ pkgs.makeWrapper ]; } ''
|
||||
for exe in ${lib.getBin pkg}/bin/*; do
|
||||
makeWrapper $exe $out/bin/$(basename $exe) --prefix PATH : ${lib.makeBinPath extraPackages}
|
||||
done
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
||||
home.packages =
|
||||
with unstable;
|
||||
with inputs;
|
||||
[
|
||||
unstable.svt-av1-psy
|
||||
unstable.ffmpeg-full
|
||||
unstable.ab-av1
|
||||
unstable.whisper-cpp-vulkan
|
||||
unstable.video-compare
|
||||
];
|
||||
|
||||
}
|
30
nixos/home-manager/packages/virtualisation.nix
Normal file
30
nixos/home-manager/packages/virtualisation.nix
Normal file
|
@ -0,0 +1,30 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
withExtraPackages =
|
||||
pkg: extraPackages:
|
||||
pkgs.runCommand "${pkg.name}-wrapped" { nativeBuildInputs = [ pkgs.makeWrapper ]; } ''
|
||||
for exe in ${lib.getBin pkg}/bin/*; do
|
||||
makeWrapper $exe $out/bin/$(basename $exe) --prefix PATH : ${lib.makeBinPath extraPackages}
|
||||
done
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
||||
home.packages =
|
||||
with unstable;
|
||||
with inputs;
|
||||
[
|
||||
pkgs.lazydocker
|
||||
pkgs.distrobox
|
||||
pkgs.boxbuddy
|
||||
];
|
||||
|
||||
}
|
31
nixos/home-manager/packages/wine.nix
Normal file
31
nixos/home-manager/packages/wine.nix
Normal file
|
@ -0,0 +1,31 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
unstable,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
withExtraPackages =
|
||||
pkg: extraPackages:
|
||||
pkgs.runCommand "${pkg.name}-wrapped" { nativeBuildInputs = [ pkgs.makeWrapper ]; } ''
|
||||
for exe in ${lib.getBin pkg}/bin/*; do
|
||||
makeWrapper $exe $out/bin/$(basename $exe) --prefix PATH : ${lib.makeBinPath extraPackages}
|
||||
done
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
||||
home.packages =
|
||||
with unstable;
|
||||
with inputs;
|
||||
[
|
||||
home.file."bin/wine".source = unstable.wineWowPackages.waylandFull;
|
||||
|
||||
unstable.wineWowPackages.waylandFull
|
||||
unstable.winetricks
|
||||
];
|
||||
|
||||
}
|
|
@ -123,41 +123,6 @@
|
|||
|
||||
programs.thunderbird.enable = true;
|
||||
|
||||
|
||||
programs.gpu-screen-recorder = {
|
||||
enable = true;
|
||||
package = unstable.gpu-screen-recorder;
|
||||
};
|
||||
|
||||
programs.corectrl = {
|
||||
enable = true;
|
||||
gpuOverclock = {
|
||||
enable = true;
|
||||
ppfeaturemask = "0xffffffff";
|
||||
};
|
||||
};
|
||||
|
||||
programs.steam = {
|
||||
enable = true;
|
||||
package = pkgs.steam.override {
|
||||
extraPkgs = (pkgs: with pkgs; with unstable; [
|
||||
gamemode
|
||||
unstable.mangohud
|
||||
# additional packages...
|
||||
# e.g. some games require python3
|
||||
]);
|
||||
};
|
||||
|
||||
remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play
|
||||
dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server
|
||||
localNetworkGameTransfers.openFirewall = true; # Open ports in the firewall for Steam Local Network Game Transfers
|
||||
};
|
||||
programs.steam.gamescopeSession.enable = true;
|
||||
programs.steam.protontricks.enable = true;
|
||||
hardware.steam-hardware.enable = true;
|
||||
programs.gamescope.enable = true;
|
||||
programs.gamemode.enable = true;
|
||||
|
||||
programs.alvr.enable = true;
|
||||
|
||||
programs.noisetorch.enable = true;
|
||||
|
@ -180,11 +145,6 @@
|
|||
amdgpu_top
|
||||
# unstable.mangohud
|
||||
|
||||
unstable.svt-av1-psy
|
||||
unstable.ffmpeg-full
|
||||
unstable.ab-av1
|
||||
unstable.whisper-cpp-vulkan
|
||||
|
||||
# unstable.openrazer-daemon # Broken, enable again in a few days?
|
||||
|
||||
rustc
|
||||
|
@ -217,17 +177,6 @@
|
|||
# enableSSHSupport = true;
|
||||
# };
|
||||
|
||||
# List services that you want to enable:
|
||||
|
||||
# Enable the OpenSSH daemon.
|
||||
|
||||
virtualisation.docker.enable = true;
|
||||
virtualisation.docker.storageDriver = "btrfs";
|
||||
# virtualisation.docker.rootless = {
|
||||
# enable = true;
|
||||
# setSocketVariable = true;
|
||||
# };
|
||||
|
||||
# Open ports in the firewall.
|
||||
# networking.firewall.allowedTCPPorts = [ ... ];
|
||||
# networking.firewall.allowedUDPPorts = [ ... ];
|
||||
|
@ -247,8 +196,6 @@
|
|||
];
|
||||
};
|
||||
|
||||
|
||||
|
||||
# environment.variables = {
|
||||
# };
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue