2 Commits

Author SHA1 Message Date
0fdd9efff2 flatpak font workarounds 2025-01-06 17:59:14 -08:00
d7c234db82 updates: linux 6.12 2025-01-05 18:04:36 -08:00
15 changed files with 134 additions and 50 deletions

0
.gitignore vendored Normal file
View File

8
.idea/.gitignore generated vendored Normal file
View File

@@ -0,0 +1,8 @@
# Default ignored files
/shelf/
/workspace.xml
# Editor-based HTTP Client requests
/httpRequests/
# Datasource local storage ignored files
/dataSources/
/dataSources.local.xml

5
.idea/codeStyles/codeStyleConfig.xml generated Normal file
View File

@@ -0,0 +1,5 @@
<component name="ProjectCodeStyleConfiguration">
<state>
<option name="PREFERRED_PROJECT_CODE_STYLE" value="Default" />
</state>
</component>

View File

@@ -0,0 +1,6 @@
<component name="InspectionProjectProfileManager">
<profile version="1.0">
<option name="myName" value="Project Default" />
<inspection_tool class="Eslint" enabled="true" level="WARNING" enabled_by_default="true" />
</profile>
</component>

View File

@@ -0,0 +1,6 @@
<component name="InspectionProjectProfileManager">
<settings>
<option name="USE_PROJECT_PROFILE" value="false" />
<version value="1.0" />
</settings>
</component>

7
.idea/misc.xml generated Normal file
View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Black">
<option name="sdkName" value="Python 3.12" />
</component>
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.12" project-jdk-type="Python SDK" />
</project>

8
.idea/modules.xml generated Normal file
View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/nix-conf.iml" filepath="$PROJECT_DIR$/.idea/nix-conf.iml" />
</modules>
</component>
</project>

8
.idea/nix-conf.iml generated Normal file
View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="jdk" jdkName="Python 3.12" jdkType="Python SDK" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

7
.idea/vcs.xml generated Normal file
View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" />
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>

View File

@@ -24,33 +24,9 @@
boot.loader.timeout = 3; boot.loader.timeout = 3;
boot.loader.systemd-boot.configurationLimit = 5; boot.loader.systemd-boot.configurationLimit = 5;
boot.kernelPackages = pkgs.linuxKernel.packages.linux_6_12;
# boot.kernelPackages = pkgs.linuxKernel.kernels.linux_6_8;
# boot.kernelPackages = pkgs.linuxPackages_6_8;
# boot.kernelPackages = pkgs.linuxKernel.packages.linux_6_6;
boot.kernelPackages = pkgs.linuxKernel.packages.linux_zen;
# nix-prefetch-git --url https://github.com/zen-kernel/zen-kernel.git --rev v6.8.9-zen1 --fetch-submodules
# boot.kernelPackages = let
# version = "6.8.9";
# suffix = "zen1"; # use "lqx1" for linux_lqx
# in pkgs.linuxKernel.packagesFor (pkgs.linux_zen.override {
# inherit version suffix;
# modDirVersion = lib.versions.pad 3 "${version}-${suffix}";
# src = pkgs.fetchFromGitHub {
# owner = "zen-kernel";
# repo = "zen-kernel";
# rev = "v${version}-${suffix}";
# sha256 = "1wva92wk0pxii4f6hn27kssgrz8yy38kk38w2wm5hh1qyz3ij1vj";
# };
# });
boot.extraModulePackages = with config.boot.kernelPackages; [ zfs ]; boot.extraModulePackages = with config.boot.kernelPackages; [ zfs ];
# https://discourse.nixos.org/t/dev-zfs-has-the-wrong-permissions-after-rebooting/48737
# environment.etc."tmpfiles.d/zfs.conf".text = ''
# z /dev/zfs 0666 - - -
# '';
# https://nixos.wiki/wiki/Accelerated_Video_Playback # https://nixos.wiki/wiki/Accelerated_Video_Playback
hardware.graphics = { hardware.graphics = {
enable = true; enable = true;
@@ -58,7 +34,8 @@
intel-media-driver # LIBVA_DRIVER_NAME=iHD intel-media-driver # LIBVA_DRIVER_NAME=iHD
]; ];
}; };
# environment.sessionVariables = { LIBVA_DRIVER_NAME = "iHD"; }; # Force intel-media-driver
environment.etc.hosts.mode = "0644";
networking.hostName = "Yura-PC"; # Define your hostname. networking.hostName = "Yura-PC"; # Define your hostname.
networking.hostId = "110a2814"; # Required for ZFS. networking.hostId = "110a2814"; # Required for ZFS.
@@ -108,7 +85,7 @@
services.printing.enable = true; services.printing.enable = true;
# Enable sound with pipewire. # Enable sound with pipewire.
hardware.pulseaudio.enable = false; services.pulseaudio.enable = false;
security.rtkit.enable = true; security.rtkit.enable = true;
services.pipewire = { services.pipewire = {
enable = true; enable = true;
@@ -181,7 +158,6 @@
group = "cazzzer"; group = "cazzzer";
extraGroups = [ "networkmanager" "wheel" "docker" "wireshark" "geoclue" ]; extraGroups = [ "networkmanager" "wheel" "docker" "wireshark" "geoclue" ];
packages = with pkgs; [ packages = with pkgs; [
python312Packages.torch
kdePackages.kate kdePackages.kate
kdePackages.yakuake kdePackages.yakuake
@@ -196,24 +172,17 @@
nodejs_22 nodejs_22
pnpm pnpm
bun bun
# yin_yang deps, f*** this packaging s***
python312Packages.systemd
python312Packages.pyside6
python312Packages.dateutils
python312Packages.psutil
libnotify
# thunderbird
]; ];
}; };
hardware.bluetooth.enable = true; hardware.bluetooth.enable = true;
hardware.bluetooth.powerOnBoot = false; hardware.bluetooth.powerOnBoot = false;
# Install firefox. # Install firefox.
programs.firefox.enable = true; # programs.firefox.enable = true;
programs.kdeconnect.enable = true; programs.kdeconnect.enable = true;
programs.fish.enable = true; programs.fish.enable = true;
programs.git.enable = true; programs.git.enable = true;
programs.git.lfs.enable = true;
# https://nixos.wiki/wiki/Git # https://nixos.wiki/wiki/Git
programs.git.package = pkgs.git.override { withLibsecret = true; }; programs.git.package = pkgs.git.override { withLibsecret = true; };
programs.lazygit.enable = true; programs.lazygit.enable = true;
@@ -288,24 +257,28 @@
# "Noto Serif" # "Noto Serif"
# "DejaVu Serif" # "DejaVu Serif"
# ]; # ];
# fonts.fontconfig.defaultFonts.sansSerif = [
# "Noto Sans"
# "DejaVu Sans"
# ];
workarounds.flatpak.enable = true;
fonts.packages = with pkgs; [ nerd-fonts.fantasque-sans-mono ];
# fonts.fontDir.enable = true;
# fonts.fontconfig.allowBitmaps = false;
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
level-zero
oneDNN
python312Packages.torch
# zfs
# fish
bat bat
# bluez # bluez
# docker_27 darkman
# docker-compose
dust dust
efibootmgr efibootmgr
eza eza
fastfetch fastfetch
fd fd
ffmpeg
# flatpak # flatpak
host-spawn # for flatpaks
kdePackages.flatpak-kcm kdePackages.flatpak-kcm
kdePackages.filelight kdePackages.filelight
# git # git
@@ -318,6 +291,7 @@
# jetbrains.rust-rover # jetbrains.rust-rover
# jetbrains.pycharm-professional # jetbrains.pycharm-professional
# jetbrains.webstorm # jetbrains.webstorm
android-studio
mediainfo mediainfo
micro micro
mpv mpv
@@ -370,7 +344,7 @@
# services.openssh.enable = true; # services.openssh.enable = true;
# Open ports in the firewall. # Open ports in the firewall.
# networking.firewall.allowedTCPPorts = [ ... ]; networking.firewall.allowedTCPPorts = [ 8080 ];
# networking.firewall.allowedUDPPorts = [ ... ]; # networking.firewall.allowedUDPPorts = [ ... ];
# Or disable the firewall altogether. # Or disable the firewall altogether.
# networking.firewall.enable = false; # networking.firewall.enable = false;

6
flake.lock generated
View File

@@ -2,11 +2,11 @@
"nodes": { "nodes": {
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1734424634, "lastModified": 1735834308,
"narHash": "sha256-cHar1vqHOOyC7f1+tVycPoWTfKIaqkoe1Q6TnKzuti4=", "narHash": "sha256-dklw3AXr3OGO4/XT1Tu3Xz9n/we8GctZZ75ZWVqAVhk=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "d3c42f187194c26d9f0309a8ecc469d6c878ce33", "rev": "6df24922a1400241dae323af55f30e4318a6ca65",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@@ -13,6 +13,7 @@
Yura-PC = nixpkgs.lib.nixosSystem { Yura-PC = nixpkgs.lib.nixosSystem {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
./modules
./configuration.nix ./configuration.nix
]; ];
}; };

5
modules/default.nix Normal file
View File

@@ -0,0 +1,5 @@
{...}: {
imports = [
./workarounds
];
}

View File

@@ -0,0 +1,5 @@
{
imports = [
./flatpak.nix
];
}

View File

@@ -0,0 +1,44 @@
# https://github.com/knightpp/nixos-cfg/blob/main/modules/workarounds/flatpak.nix
{
pkgs,
config,
lib,
...
}: let
cfg = config.workarounds.flatpak;
in {
options = {
workarounds.flatpak = {
enable = lib.mkEnableOption "flatpak workaround";
};
};
config = lib.mkIf cfg.enable {
system.fsPackages = [pkgs.bindfs];
fileSystems = let
mkRoSymBind = path: {
device = path;
fsType = "fuse.bindfs";
options = ["ro" "resolve-symlinks" "x-gvfs-hide"];
};
aggregated = pkgs.buildEnv {
name = "system-fonts-and-icons";
paths = builtins.attrValues {
inherit (pkgs.libsForQt5) breeze-qt5;
inherit
(pkgs)
noto-fonts
noto-fonts-emoji
noto-fonts-cjk-sans
noto-fonts-cjk-serif
;
};
pathsToLink = ["/share/fonts" "/share/icons"];
};
in {
# Create an FHS mount to support flatpak host icons/fonts
"/usr/share/icons" = mkRoSymBind "${aggregated}/share/icons";
"/usr/share/fonts" = mkRoSymBind "${aggregated}/share/fonts";
};
};
}