gaming updates, font sizes and encrypted usb

This commit is contained in:
chaos 2024-07-17 20:13:22 +01:00
parent 33b4258193
commit 27628dd254
No known key found for this signature in database
6 changed files with 14 additions and 12 deletions

View file

@ -1 +1,3 @@
{pkgs, ...}: {home.packages = with pkgs; [lutris];} {pkgs, ...}: {
home.packages = with pkgs; [(lutris.override {extraPkgs = pkgs: with pkgs; [gamescope];}) wineWowPackages.staging];
}

View file

@ -11,7 +11,7 @@
}; };
font = { font = {
name = "Comic Code"; name = "Comic Code";
size = 16; size = 12;
package = pkgs.comic-code; package = pkgs.comic-code;
}; };
}; };

View file

@ -12,14 +12,10 @@
homeManagerLib = inputs.home-manager.lib.hm; homeManagerLib = inputs.home-manager.lib.hm;
fontSizesAll = { fontSizesAll = {
"lappy-t495" = { default = {
small = "10"; small = "10";
medium = "12"; medium = "12";
}; };
default = {
small = "14";
medium = "16";
};
}; };
fontSizes = fontSizes =

View file

@ -36,6 +36,7 @@
home.programming.languages.nix home.programming.languages.nix
home.gaming.platforms.steam home.gaming.platforms.steam
home.gaming.platforms.lutris
]; ];
home.stateVersion = "24.05"; home.stateVersion = "24.05";
}; };

View file

@ -4,4 +4,5 @@
remotePlay.openFirewall = true; remotePlay.openFirewall = true;
dedicatedServer.openFirewall = true; dedicatedServer.openFirewall = true;
}; };
hardware.opengl.driSupport32Bit = true;
} }

View file

@ -2,16 +2,18 @@
encryptedUSB = import ../data/drives/encryptedUSB.nix; encryptedUSB = import ../data/drives/encryptedUSB.nix;
encUSBMount = pkgs.writeShellScriptBin "enc_usb_mount" '' encUSBMount = pkgs.writeShellScriptBin "enc_usb_mount" ''
export MAPPER_NAME=''${MAPPER_NAME:-${encryptedUSB.mapperName}}
set -x set -x
${encUSBUnmount}/bin/enc_usb_unmount ${encUSBUnmount}/bin/enc_usb_unmount
cat /secrets/usb_encryption_passphrase | cryptsetup luksOpen ${encryptedUSB.encryptedPath} ${encryptedUSB.mapperName} - cat /secrets/usb_encryption_passphrase | cryptsetup luksOpen ${encryptedUSB.encryptedPath} $MAPPER_NAME -
mount ${encryptedUSB.mapperPath} -o rw ${encryptedUSB.mountpoint} mount /dev/mapper/$MAPPER_NAME -o rw ${encryptedUSB.mountpoint}
''; '';
encUSBUnmount = pkgs.writeShellScriptBin "enc_usb_unmount" '' encUSBUnmount = pkgs.writeShellScriptBin "enc_usb_unmount" ''
set -x export MAPPER_NAME=''${MAPPER_NAME:-${encryptedUSB.mapperName}}
umount -flR ${encryptedUSB.mountpoint} || true set -x
cryptsetup close ${encryptedUSB.mapperName} || true umount -flR ${encryptedUSB.mountpoint} || true
cryptsetup close $MAPPER_NAME || true
''; '';
in { in {
environment.systemPackages = [encUSBMount encUSBUnmount]; environment.systemPackages = [encUSBMount encUSBUnmount];