diff --git a/flake.lock b/flake.lock index dc9dc201..90c571bf 100644 --- a/flake.lock +++ b/flake.lock @@ -598,27 +598,6 @@ "type": "github" } }, - "home-manager_2": { - "inputs": { - "nixpkgs": [ - "zen-browser", - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1752603129, - "narHash": "sha256-S+wmHhwNQ5Ru689L2Gu8n1OD6s9eU9n9mD827JNR+kw=", - "owner": "nix-community", - "repo": "home-manager", - "rev": "e8c19a3cec2814c754f031ab3ae7316b64da085b", - "type": "github" - }, - "original": { - "owner": "nix-community", - "repo": "home-manager", - "type": "github" - } - }, "ida-pro-overlay": { "inputs": { "nixpkgs": [ @@ -1452,8 +1431,7 @@ "systems": "systems_2", "tree": "tree", "treefmt-nix": "treefmt-nix", - "wezterm": "wezterm", - "zen-browser": "zen-browser" + "wezterm": "wezterm" } }, "rust": { @@ -1925,27 +1903,6 @@ "type": "github" } }, - "zen-browser": { - "inputs": { - "home-manager": "home-manager_2", - "nixpkgs": [ - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1759900726, - "narHash": "sha256-DXgznNT8CA50WUIlQkI5BsEqNcbPDFF+26PPRYeB3sA=", - "owner": "0xc000022070", - "repo": "zen-browser-flake", - "rev": "8ce7d926dbec820ab5686d599bc6a1bd19ed1273", - "type": "github" - }, - "original": { - "owner": "0xc000022070", - "repo": "zen-browser-flake", - "type": "github" - } - }, "zlib": { "flake": false, "locked": { diff --git a/flake.nix b/flake.nix index 7ca22bce..42df50b0 100644 --- a/flake.nix +++ b/flake.nix @@ -94,10 +94,6 @@ nixpkgs.follows = "nixpkgs"; }; }; - zen-browser = { - url = "github:0xc000022070/zen-browser-flake"; - inputs.nixpkgs.follows = "nixpkgs"; - }; nixpkgs-xr = { url = "github:nix-community/nixpkgs-xr"; inputs = { diff --git a/home/environments/niri/autostart.nix b/home/environments/niri/autostart.nix index 7fd9cbfc..7c144d91 100644 --- a/home/environments/niri/autostart.nix +++ b/home/environments/niri/autostart.nix @@ -101,20 +101,5 @@ in { "--enable-wayland-ime" ]; } - { - command = [ - "thunderbird" - ]; - } - { - command = [ - "obsidian" - ]; - } - { - command = [ - "zen-beta" - ]; - } ]; } diff --git a/home/environments/niri/niri.nix b/home/environments/niri/niri.nix index f2d7d0c3..78b61bbe 100644 --- a/home/environments/niri/niri.nix +++ b/home/environments/niri/niri.nix @@ -70,7 +70,7 @@ in { }; }; debug = { - honor-xdg-activation-with-invalid-serial = {}; + #honor-xdg-activation-with-invalid-serial = {}; #strict-new-window-focus-policy = {}; #deactivate-unfocused-windows = {}; }; diff --git a/home/environments/niri/window-rules.nix b/home/environments/niri/window-rules.nix index c07b924c..af5e4661 100644 --- a/home/environments/niri/window-rules.nix +++ b/home/environments/niri/window-rules.nix @@ -20,7 +20,7 @@ _: { at-startup = true; } { - app-id = "^zen-beta$"; + app-id = "^librewolf$"; at-startup = true; } { diff --git a/home/profiles/common/nix.nix b/home/profiles/common/nix.nix index a1bdd742..156063fe 100644 --- a/home/profiles/common/nix.nix +++ b/home/profiles/common/nix.nix @@ -7,6 +7,10 @@ _: { persistent = true; }; }; - # adds to nixpkgs.overlay, made irrelevant due to `home-manager.useGlobalPkgs` - #chaotic.nyx.overlay.enable = false; + services.home-manager.autoExpire = { + enable = true; + frequency = "weekly"; + store.cleanup = true; + timestamp = "-7 days"; + }; } diff --git a/home/profiles/graphical/firefox/config.nix b/home/profiles/graphical/librewolf/config.nix similarity index 99% rename from home/profiles/graphical/firefox/config.nix rename to home/profiles/graphical/librewolf/config.nix index f3c93630..116daa2c 100644 --- a/home/profiles/graphical/firefox/config.nix +++ b/home/profiles/graphical/librewolf/config.nix @@ -1,5 +1,5 @@ _: { - programs.zen-browser.profiles.main.settings = { + programs.librewolf.profiles.main.settings = { "browser.tabs.allow_transparent_browser" = true; "zen.welcome-screen.seen" = true; diff --git a/home/profiles/graphical/firefox/containers.nix b/home/profiles/graphical/librewolf/containers.nix similarity index 92% rename from home/profiles/graphical/firefox/containers.nix rename to home/profiles/graphical/librewolf/containers.nix index a33324e0..d7069280 100644 --- a/home/profiles/graphical/firefox/containers.nix +++ b/home/profiles/graphical/librewolf/containers.nix @@ -1,5 +1,5 @@ _: { - programs.zen-browser.profiles.main = { + programs.librewolf.profiles.main = { containersForce = true; containers = { main = { diff --git a/home/profiles/graphical/firefox/main.nix b/home/profiles/graphical/librewolf/main.nix similarity index 91% rename from home/profiles/graphical/firefox/main.nix rename to home/profiles/graphical/librewolf/main.nix index d041249f..8846dca7 100644 --- a/home/profiles/graphical/firefox/main.nix +++ b/home/profiles/graphical/librewolf/main.nix @@ -6,9 +6,12 @@ home.sessionVariables = { BROWSER = "zen"; }; - #stylix.targets.zen-browser.profileNames = ["main"]; + stylix.targets.librewolf = { + colorTheme.enable = true; + profileNames = ["main"]; + }; home.packages = [pkgs.ff2mpv-rust]; - programs.zen-browser = { + programs.librewolf = { nativeMessagingHosts = [ pkgs.ff2mpv-rust ]; diff --git a/home/profiles/graphical/firefox/mtab.nix b/home/profiles/graphical/librewolf/mtab.nix similarity index 98% rename from home/profiles/graphical/firefox/mtab.nix rename to home/profiles/graphical/librewolf/mtab.nix index b386476f..1abab187 100644 --- a/home/profiles/graphical/firefox/mtab.nix +++ b/home/profiles/graphical/librewolf/mtab.nix @@ -1,5 +1,5 @@ {nur, ...}: { - programs.zen-browser.profiles.main.extensions = { + programs.librewolf.profiles.main.extensions = { packages = with nur.repos.rycee.firefox-addons; [ mtab ]; diff --git a/home/profiles/graphical/firefox/tst.old b/home/profiles/graphical/librewolf/tst.nix similarity index 97% rename from home/profiles/graphical/firefox/tst.old rename to home/profiles/graphical/librewolf/tst.nix index 130040f0..0eb3b066 100644 --- a/home/profiles/graphical/firefox/tst.old +++ b/home/profiles/graphical/librewolf/tst.nix @@ -1,5 +1,5 @@ {nur, ...}: { - programs.zen-browser.profiles.main = { + programs.librewolf.profiles.main = { extensions = { packages = with nur.repos.rycee.firefox-addons; [ tree-style-tab diff --git a/home/profiles/graphical/firefox/ublock.nix b/home/profiles/graphical/librewolf/ublock.nix similarity index 95% rename from home/profiles/graphical/firefox/ublock.nix rename to home/profiles/graphical/librewolf/ublock.nix index 4b6b5239..2cd96a86 100644 --- a/home/profiles/graphical/firefox/ublock.nix +++ b/home/profiles/graphical/librewolf/ublock.nix @@ -1,5 +1,5 @@ {nur, ...}: { - programs.zen-browser.profiles.main.extensions = { + programs.librewolf.profiles.main.extensions = { packages = with nur.repos.rycee.firefox-addons; [ ublock-origin ]; diff --git a/home/profiles/graphical/firefox/yomitan.nix b/home/profiles/graphical/librewolf/yomitan.nix similarity index 75% rename from home/profiles/graphical/firefox/yomitan.nix rename to home/profiles/graphical/librewolf/yomitan.nix index 6493e3ce..95c21fc3 100644 --- a/home/profiles/graphical/firefox/yomitan.nix +++ b/home/profiles/graphical/librewolf/yomitan.nix @@ -1,5 +1,5 @@ _: { - programs.zen-browser.profiles.main.extensions = { + programs.librewolf.profiles.main.extensions = { #settings."{6b733b82-9261-47ee-a595-2dda294a4d08}".settings = { # options = builtins.toJSON { # showGuide = false; diff --git a/home/profiles/graphical/zen.nix b/home/profiles/graphical/zen.nix deleted file mode 100644 index abf8b9c4..00000000 --- a/home/profiles/graphical/zen.nix +++ /dev/null @@ -1,5 +0,0 @@ -_: { - programs.zen-browser = { - enable = true; - }; -} diff --git a/nixos/profiles/gaming/lutris.nix b/nixos/profiles/gaming/lutris.nix deleted file mode 100644 index 92235571..00000000 --- a/nixos/profiles/gaming/lutris.nix +++ /dev/null @@ -1,45 +0,0 @@ -{pkgs, ...}: { - hardware.graphics = { - enable32Bit = true; - extraPackages32 = with pkgs; [ - driversi686Linux.mesa - ]; - }; - programs.gamescope = { - enable = true; - package = pkgs.gamescope; - }; - environment.systemPackages = with pkgs; [ - protonplus - gamescope-wsi - (lutris.override { - extraPkgs = _pkgs: [ - #pkgs.gamescope - #pkgs.libnghttp2 - #pkgs.winetricks - #pkgs.jansson - #pkgs.samba - #pkgs.gvfs - #pkgs.mangohud - #pkgs.vkbasalt - #pkgs.umu-launcher - #pkgs.xdg-desktop-portal - ]; - extraLibraries = _pkgs: [ - #pkgs.libunwind - #pkgs.xdg-desktop-portal - #pkgs.gvfs - #pkgs.jansson - #pkgs.samba - #pkgs.xz - ]; - }) - - wine - wine64 - vkbasalt - mangohud - umu-launcher - winetricks - ]; -} diff --git a/nixos/profiles/gaming/reactos_cmd.exe b/nixos/profiles/gaming/reactos_cmd.exe new file mode 100644 index 00000000..aaa88520 Binary files /dev/null and b/nixos/profiles/gaming/reactos_cmd.exe differ diff --git a/nixos/profiles/gaming/vn_script.bat b/nixos/profiles/gaming/vn_script.bat new file mode 100644 index 00000000..5b1ffa94 --- /dev/null +++ b/nixos/profiles/gaming/vn_script.bat @@ -0,0 +1,17 @@ +@echo off +set VN_DIR=%1 +set VN_EXE=%2 +set VN_ARCH=%3 + +echo "Setting UTF-8..." +chcp 65001 > nul + +echo "Launching VN..." +cd /d %VN_DIR% +start %VN_EXE% + +echo Launching Textractor... +cd /d "C:\users\steamuser\Desktop\Textractor\%VN_ARCH%" +start Textractor.exe + +exit diff --git a/nixos/profiles/gaming/wine.nix b/nixos/profiles/gaming/wine.nix index 3377ded7..e2aa7225 100644 --- a/nixos/profiles/gaming/wine.nix +++ b/nixos/profiles/gaming/wine.nix @@ -1,80 +1,74 @@ { pkgs, inputs, + lib, ... }: let + inherit (lib.meta) getExe; + inherit (lib.attrsets) mapAttrs; environment = { PROTON_CACHYOS = "${inputs.chaotic.packages.${pkgs.system}.proton-cachyos_x86_64_v3.out}/bin"; PROTON_GE = "${inputs.chaotic.packages.${pkgs.system}.proton-ge-custom.out}/bin"; - #PROTON_WC3 = "/home/kat/.local/share/Steam/compatibilitytools.d/GE-Proton10-1"; - #PROTON_WC3 = "/home/kat/.local/share/Steam/compatibilitytools.d/Proton-Tkg-2367"; - #PROTON_WC3 = "/home/kat/.local/share/Steam/steamapps/common/Proton - Experimental"; + }; + games = { + # + # Proton / contemporary video games + # + + gw = "Guild Wars"; + gw2 = "Guild Wars 2"; + battlenet = "Battle.net"; + sc = "Starcraft: Remastered"; + sc2 = "Starcraft 2"; + + wcr = "Warcraft: Remastered"; + wc2r = "Warcraft 2: Remastered"; + wc = "Warcraft Orcs & Humans"; + wc2 = "Warcraft 2: Battle.net Edition"; + # https://lutris.net/games/install/25450/view + # Dissection: + # * nvapi disables, + # * registry key for Win7 in version + wc3 = "Warcraft 3: Reforged"; + + # + # Visual Novels + # + + hanahira = "Hanahira"; + kanon = "Kanon"; }; in { - systemd.user.services.gw = { - description = "Guild Wars"; - serviceConfig = { - ExecStart = "${pkgs.katwine}/bin/katwine gw"; - Type = "simple"; - }; - inherit environment; + hardware.graphics = { + enable32Bit = true; + extraPackages32 = with pkgs; [ + driversi686Linux.mesa + ]; }; - systemd.user.services.gw2 = { - description = "Guild Wars 2"; - serviceConfig = { - ExecStart = "${pkgs.katwine}/bin/katwine gw2"; - Type = "simple"; - }; - inherit environment; + programs.gamescope = { + enable = true; + package = pkgs.gamescope; }; - systemd.user.services.battlenet = { - description = "Battle.net"; - serviceConfig = { - ExecStart = "${pkgs.katwine}/bin/katwine bnet"; - Type = "simple"; - }; - inherit environment; - }; - systemd.user.services.sc = { - description = "Starcraft"; - serviceConfig = { - ExecStart = "${pkgs.katwine}/bin/katwine sc"; - Type = "simple"; - }; - inherit environment; - }; - systemd.user.services.sc2 = { - description = "Starcraft 2"; - serviceConfig = { - ExecStart = "${pkgs.katwine}/bin/katwine sc2"; - Type = "simple"; - }; - inherit environment; - }; - # https://lutris.net/games/install/25450/view - # Dissection: - # * nvapi disables, - # * registry key for Win7 in version - systemd.user.services.wc3 = { - description = "Warcraft 3"; - serviceConfig = { - ExecStart = "${pkgs.katwine}/bin/katwine wc3"; - Type = "simple"; - }; - inherit environment; - }; - systemd.user.services.kanon = { - description = "Kanon"; - serviceConfig = { - ExecStart = "${pkgs.katwine}/bin/katwine kanon"; - Type = "simple"; - }; - }; - systemd.user.services.hanahira = { - description = "Hanahira"; - serviceConfig = { - ExecStart = "${pkgs.katwine}/bin/katwine hanahira"; - Type = "simple"; - }; + environment.systemPackages = with pkgs; [ + protonplus + gamescope-wsi + mangohud + vkbasalt + ]; + systemd.user.services = + mapAttrs (k: v: { + description = v; + serviceConfig = { + ExecStart = "${getExe pkgs.katwine} ${k}"; + Type = "simple"; + }; + inherit environment; + }) + games; + + home-manager.users.kat.home.file = { + # https://learnjapanese.moe/vn-linux/ + "Games/VNs/drive_c/script.bat".source = ./vn_script.bat; + "Games/VNs/drive_c/cmd.exe".source = ./reactos_cmd.exe; }; } diff --git a/packages/katwine/script.sh b/packages/katwine/script.sh index ecd891b9..fccf909f 100755 --- a/packages/katwine/script.sh +++ b/packages/katwine/script.sh @@ -80,11 +80,16 @@ battlenet() { WINEPREFIX="${GAMES_DIR}/battlenet" GAMEDIR="${WINEPREFIX}/drive_c/Program Files (x86)/Battle.net" GAME_EXE="${GAMEDIR}/Battle.net.exe" + GAME_LAUNCHER_EXE="${GAMEDIR}/Battle.net Launcher.exe" system_conf proton_conf dxvk_conf caches_conf + # Start the battley net thing + proton_runner "$GAME_LAUNCHER_EXE" & if [ "$#" -ge 1 ]; then + # wait a little bit for it to warm up + sleep 5 case $1 in (sc1|s1|sc) proton_runner "$GAME_EXE" "--in-process-gpu" "--exec=\"launch S1\"" @@ -92,16 +97,29 @@ battlenet() { (sc2|s2) proton_runner "$GAME_EXE" "--in-process-gpu" "--exec=\"launch S2\"" ;; + (wc1|w1) + proton_runner "$GAME_EXE" "--in-process-gpu" "--exec=\"launch W1\"" + ;; + (wc2|w2) + proton_runner "$GAME_EXE" "--in-process-gpu" "--exec=\"launch W2\"" + ;; + (wc1r|w1r|wcr) + proton_runner "$GAME_EXE" "--in-process-gpu" "--exec=\"launch W1R\"" + ;; + (wc2r|w2r) + proton_runner "$GAME_EXE" "--in-process-gpu" "--exec=\"launch W2R\"" + ;; (wc3|w3) # TODO: build and ship a custom patched wine for this... jfc + # https://lutris.net/games/install/25450/view + # Dissection: + # * nvapi disables, + # * registry key for Win7 in version export STAGING_SHARED_MEMORY=1 export __GL_SHADER_DISK_CACHE_SKIP_CLEANUP=1 proton_runner "$GAME_EXE" "--in-process-gpu" "--exec=\"launch W3\"" - #proton_runner "${WINEPREFIX}/drive_c/Program Files (x86)/Warcraft III/_retail_/x86_64/Warcraft III.exe" "-launch" ;; esac - else - proton_runner "$GAME_EXE" fi } diff --git a/tree.nix b/tree.nix index 06e521e4..7a2064dc 100644 --- a/tree.nix +++ b/tree.nix @@ -114,7 +114,6 @@ chaotic.homeManagerModules.default spicetify-nix.homeManagerModules.spicetify nix-flatpak.homeManagerModules.nix-flatpak - zen-browser.homeModules.default stylix.homeModules.stylix ] ++ (with (import (inputs.arcexprs + "/modules")).home-manager; [