From 057ccac17f3a8e76c4297f15310ad942012306d8 Mon Sep 17 00:00:00 2001 From: K900 Date: Tue, 7 Jan 2025 09:21:42 +0300 Subject: [PATCH 01/30] flake.lock: Update MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Flake lock file updates: • Updated input 'nixpkgs': 'github:NixOS/nixpkgs/634fd46801442d760e09493a794c4f15db2d0cbb' (2024-12-27) → 'github:NixOS/nixpkgs/8f3e1f807051e32d8c95cd12b9b421623850a34d' (2025-01-04) --- flake.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/flake.lock b/flake.lock index a000b272..11e661ea 100644 --- a/flake.lock +++ b/flake.lock @@ -23,11 +23,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1735291276, - "narHash": "sha256-NYVcA06+blsLG6wpAbSPTCyLvxD/92Hy4vlY9WxFI1M=", + "lastModified": 1736012469, + "narHash": "sha256-/qlNWm/IEVVH7GfgAIyP6EsVZI6zjAx1cV5zNyrs+rI=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "634fd46801442d760e09493a794c4f15db2d0cbb", + "rev": "8f3e1f807051e32d8c95cd12b9b421623850a34d", "type": "github" }, "original": { From d41e1e88d45d72876cef87ccbf597ca5b99ab4bb Mon Sep 17 00:00:00 2001 From: K900 Date: Tue, 7 Jan 2025 09:22:06 +0300 Subject: [PATCH 02/30] modules: adjust for pulseaudio option renames --- modules/devices/steamdeck/sound.nix | 2 +- modules/steam/steam.nix | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/devices/steamdeck/sound.nix b/modules/devices/steamdeck/sound.nix index ada2fd45..9d2ca2c6 100644 --- a/modules/devices/steamdeck/sound.nix +++ b/modules/devices/steamdeck/sound.nix @@ -32,7 +32,7 @@ in extraEnv.ALSA_CONFIG_UCM2 = "${alsa-ucm-conf'}/share/alsa/ucm2"; in lib.mkIf cfg.enableSoundSupport { - hardware.pulseaudio.enable = false; + services.pulseaudio.enable = false; services.pipewire = { enable = true; diff --git a/modules/steam/steam.nix b/modules/steam/steam.nix index b801c0c5..6043ee11 100644 --- a/modules/steam/steam.nix +++ b/modules/steam/steam.nix @@ -46,7 +46,7 @@ in extraPackages32 = [ pkgs.pkgsi686Linux.gamescope-wsi ]; }; - hardware.pulseaudio.support32Bit = true; + services.pulseaudio.support32Bit = true; hardware.steam-hardware.enable = mkDefault true; environment.systemPackages = [ pkgs.gamescope-session pkgs.steamos-polkit-helpers pkgs.steamos-manager ]; From 43b9c31b2cbc40200389bb3eeae6d83756615500 Mon Sep 17 00:00:00 2001 From: K900 Date: Wed, 8 Jan 2025 12:34:09 +0300 Subject: [PATCH 03/30] jupiter-hw-support: 20241205.1 -> 20250107.1 --- pkgs/jupiter-hw-support/src.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/jupiter-hw-support/src.nix b/pkgs/jupiter-hw-support/src.nix index 76e992bd..0c114230 100644 --- a/pkgs/jupiter-hw-support/src.nix +++ b/pkgs/jupiter-hw-support/src.nix @@ -8,13 +8,13 @@ stdenv.mkDerivation rec { pname = "jupiter-hw-support-source"; - version = "20241205.1"; + version = "20250107.1"; src = fetchFromGitHub { owner = "Jovian-Experiments"; repo = "jupiter-hw-support"; rev = "jupiter-${version}"; - hash = "sha256-00QrJYTwIHN+ZDJyIv1jxwp+oWobmNFPfm3S7BehQTA="; + hash = "sha256-qrHQyECBvfBF5CdBKIJq8wxR2YTsEgtlxEqQMhUH0Ps="; }; patches = [ From fa094d2e1fa8e7da839f1960012f948bb7f99c97 Mon Sep 17 00:00:00 2001 From: K900 Date: Wed, 8 Jan 2025 12:35:20 +0300 Subject: [PATCH 04/30] manifest: update some things --- support/manifest/mappings.toml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/support/manifest/mappings.toml b/support/manifest/mappings.toml index 3ae6346d..d57b2976 100644 --- a/support/manifest/mappings.toml +++ b/support/manifest/mappings.toml @@ -32,7 +32,7 @@ alsa-ucm-conf.check = "1.2.12-1.1" atomupd-daemon.ignore = true # FIXME: has some not-yet-upstream patches, maybe we want them in nixpkgs? -bluez.check = "5.79-1.2" +bluez.check = "5.79-1.4" # more A/B stuff bmap-tools.ignore = true @@ -194,6 +194,9 @@ linux-neptune-rtw-debug.ignore = true # new kernel linux-neptune-68 = { map = "linux_jovian", pkgrel = 1 } +# very new kernel +linux-neptune-611.ignore = true + # we don't identify as SteamOS lsb-release.ignore = true @@ -309,7 +312,7 @@ steamos-media-creation-git.ignore = true # Allows switching between iwd and wpa_supplicant wifi backends from Steam # FIXME: doesn't seem to be wired up? -steamos-networking-tools.check = "1.1-1" +steamos-networking-tools.check = "1.1-2" # more A/B stuff steamos-repair-backend-git.ignore = true From 9a958cc0aa5241ea3badf44a063a4b0389dc0110 Mon Sep 17 00:00:00 2001 From: K900 Date: Thu, 9 Jan 2025 10:58:13 +0300 Subject: [PATCH 05/30] gamescope{,-session}: 3.15.15 -> 3.16.1 --- pkgs/gamescope-session/default.nix | 4 ++-- pkgs/gamescope/default.nix | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/gamescope-session/default.nix b/pkgs/gamescope-session/default.nix index d6aa6e7b..57f684ec 100644 --- a/pkgs/gamescope-session/default.nix +++ b/pkgs/gamescope-session/default.nix @@ -106,13 +106,13 @@ let }; in stdenv.mkDerivation(finalAttrs: { pname = "gamescope-session"; - version = "3.15.15-1"; + version = "3.16.1-1"; src = fetchFromGitHub { owner = "Jovian-Experiments"; repo = "PKGBUILDs-mirror"; rev = "jupiter-main/gamescope-${finalAttrs.version}"; - hash = "sha256-/Jpfg592UcQtlSVKInQyA5cT9EjVZ+XvpLMjIu/b4iU="; + hash = "sha256-vaUyDvCHseIYOQ7yQKLfa0QhiDt3nSPjEgidQRTj8v0="; }; patches = [ diff --git a/pkgs/gamescope/default.nix b/pkgs/gamescope/default.nix index b3db0fbc..adabad68 100644 --- a/pkgs/gamescope/default.nix +++ b/pkgs/gamescope/default.nix @@ -6,13 +6,13 @@ # version shipped by the vendor, ensuring feature level is equivalent. gamescope'.overrideAttrs(old: rec { - version = "3.15.15"; + version = "3.16.1"; src = fetchFromGitHub { owner = "ValveSoftware"; repo = "gamescope"; rev = version; fetchSubmodules = true; - hash = "sha256-FiPSGzfA3YH9TED8E5hpfpd+IQGthvwsxAFXZuqVZ4Q="; + hash = "sha256-+0QGt4UADJmZok2LzvL+GBad0t4vVL4HXq27399zH3Y="; }; }) From e5a5906fbef7666508f7dba3c120fb6988ef99b3 Mon Sep 17 00:00:00 2001 From: K900 Date: Fri, 10 Jan 2025 01:22:36 +0300 Subject: [PATCH 06/30] gamescope-session: 3.16.1-1 -> 3.16.1-2 --- pkgs/gamescope-session/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/gamescope-session/default.nix b/pkgs/gamescope-session/default.nix index 57f684ec..2ab677f5 100644 --- a/pkgs/gamescope-session/default.nix +++ b/pkgs/gamescope-session/default.nix @@ -106,13 +106,13 @@ let }; in stdenv.mkDerivation(finalAttrs: { pname = "gamescope-session"; - version = "3.16.1-1"; + version = "3.16.1-2"; src = fetchFromGitHub { owner = "Jovian-Experiments"; repo = "PKGBUILDs-mirror"; rev = "jupiter-main/gamescope-${finalAttrs.version}"; - hash = "sha256-vaUyDvCHseIYOQ7yQKLfa0QhiDt3nSPjEgidQRTj8v0="; + hash = "sha256-2WfNfD6Yyjlzfrce5ey3UGexveTrOvwPwdCswPkmEz4="; }; patches = [ From 913aa4de45bf13ac949e337f6246a54aa41fa826 Mon Sep 17 00:00:00 2001 From: K900 Date: Sat, 11 Jan 2025 10:29:48 +0300 Subject: [PATCH 07/30] mesa-radv-jupiter: sync with vendor pkgrel 2 --- pkgs/mesa-radv-jupiter/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/mesa-radv-jupiter/default.nix b/pkgs/mesa-radv-jupiter/default.nix index 4c277797..7e3401fa 100644 --- a/pkgs/mesa-radv-jupiter/default.nix +++ b/pkgs/mesa-radv-jupiter/default.nix @@ -46,5 +46,6 @@ in stdenv.mkDerivation { "-D valgrind=enabled" "-D intel-rt=disabled" "-D radv-build-id=da39a3ee5e6b4b0d3255bfef95601890afd80709" + "-D gpuvis=true" ]; } \ No newline at end of file From 1ddf0b3bfe076fa50b84244e42a55b9234f96083 Mon Sep 17 00:00:00 2001 From: K900 Date: Sat, 11 Jan 2025 10:29:56 +0300 Subject: [PATCH 08/30] manifest: update for python 3.13 rebuilds --- support/manifest/mappings.toml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/support/manifest/mappings.toml b/support/manifest/mappings.toml index d57b2976..a55d26f6 100644 --- a/support/manifest/mappings.toml +++ b/support/manifest/mappings.toml @@ -32,7 +32,7 @@ alsa-ucm-conf.check = "1.2.12-1.1" atomupd-daemon.ignore = true # FIXME: has some not-yet-upstream patches, maybe we want them in nixpkgs? -bluez.check = "5.79-1.4" +bluez.check = "5.79-1.5" # more A/B stuff bmap-tools.ignore = true @@ -50,7 +50,7 @@ casync.ignore = true ckbcomp.ignore = true # just disables tests -clang.check = "18.1.8-4.1" +clang.check = "18.1.8-4.2" # unused debos-git.ignore = true @@ -137,12 +137,12 @@ iwd.check = "3.0-1" jupiter-dock-updater-bin = { map = true, pkgrel = 1 } -jupiter-fan-control = { map = true, pkgrel = 3 } +jupiter-fan-control = { map = true, pkgrel = 4 } # we have our own, better one jupiter-firewall.ignore = true -jupiter-hw-support = { map = ["jupiter-hw-support", "steamdeck-hw-theme", "steamdeck-firmware", "steamos-polkit-helpers"], pkgrel = 1 } +jupiter-hw-support = { map = ["jupiter-hw-support", "steamdeck-hw-theme", "steamdeck-firmware", "steamos-polkit-helpers"], pkgrel = 2 } jupiter-legacy-support.check = "1.152-1" @@ -207,9 +207,9 @@ maliit-keyboard.check = "2.3.1-3.1" mangohud.check = "0.7.2.rc3.r11.g31f2ca5-2.3" # we take upstream patches and apply on top of our mesa -mesa.check = "24.0.5.183660.radeonsi_24.0.4-1.1" +mesa.check = "24.0.5.183660.radeonsi_24.0.4-1.2" -mesa-radv = { map = "mesa-radv-jupiter", pkgrel = "1", fixup = "mesa" } +mesa-radv = { map = "mesa-radv-jupiter", pkgrel = "3", fixup = "mesa" } # some old test thing mesa-unstable.ignore = true @@ -222,14 +222,14 @@ neptune-ctl.ignore = true # we don't actually apply any of this, but it's worth checking # FIXME? -networkmanager.check = "1.50.0-1.1" +networkmanager.check = "1.50.0-1.2" # Arch stuff pacman-contrib.ignore = true paru.ignore = true # we ship a newer version, but patches may be valuable -pipewire.check = "1:1.2.6-1.1" +pipewire.check = "1:1.2.6-1.2" # builds from master branch for Qt6 # FIXME: do we want this? @@ -335,7 +335,7 @@ ttf-twemoji-default.ignore = true umr.ignore = true # just disables tests, but may have stuff later -upower.check = "0.99.15.jupiter-1.3" +upower.check = "0.99.15.jupiter-1.4" # non-critical but would be nice to have # FIXME: package these @@ -347,7 +347,7 @@ vpower.ignore = true wakehook = { map = true, pkgrel = 1 } -wireplumber = { map = "wireplumber-jupiter", pkgrel = "1.3" } +wireplumber = { map = "wireplumber-jupiter", pkgrel = "1.4" } # ours is newer xdg-desktop-portal-gtk.ignore = true From d96a7214a71d3026870132656939c03965edb9f5 Mon Sep 17 00:00:00 2001 From: K900 Date: Sun, 12 Jan 2025 20:05:50 +0300 Subject: [PATCH 09/30] Revert "gamescope-session: 3.16.1-1 -> 3.16.1-2" This reverts commit e5a5906fbef7666508f7dba3c120fb6988ef99b3. --- pkgs/gamescope-session/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/gamescope-session/default.nix b/pkgs/gamescope-session/default.nix index 2ab677f5..57f684ec 100644 --- a/pkgs/gamescope-session/default.nix +++ b/pkgs/gamescope-session/default.nix @@ -106,13 +106,13 @@ let }; in stdenv.mkDerivation(finalAttrs: { pname = "gamescope-session"; - version = "3.16.1-2"; + version = "3.16.1-1"; src = fetchFromGitHub { owner = "Jovian-Experiments"; repo = "PKGBUILDs-mirror"; rev = "jupiter-main/gamescope-${finalAttrs.version}"; - hash = "sha256-2WfNfD6Yyjlzfrce5ey3UGexveTrOvwPwdCswPkmEz4="; + hash = "sha256-vaUyDvCHseIYOQ7yQKLfa0QhiDt3nSPjEgidQRTj8v0="; }; patches = [ From 54d7806eb668a28ab1dbdd25ee0caab6f8c62433 Mon Sep 17 00:00:00 2001 From: K900 Date: Sun, 12 Jan 2025 20:05:54 +0300 Subject: [PATCH 10/30] Revert "gamescope{,-session}: 3.15.15 -> 3.16.1" This reverts commit 9a958cc0aa5241ea3badf44a063a4b0389dc0110. Breaks a bunch of games, seemingly especially 32-bit ones? --- pkgs/gamescope-session/default.nix | 4 ++-- pkgs/gamescope/default.nix | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/gamescope-session/default.nix b/pkgs/gamescope-session/default.nix index 57f684ec..d6aa6e7b 100644 --- a/pkgs/gamescope-session/default.nix +++ b/pkgs/gamescope-session/default.nix @@ -106,13 +106,13 @@ let }; in stdenv.mkDerivation(finalAttrs: { pname = "gamescope-session"; - version = "3.16.1-1"; + version = "3.15.15-1"; src = fetchFromGitHub { owner = "Jovian-Experiments"; repo = "PKGBUILDs-mirror"; rev = "jupiter-main/gamescope-${finalAttrs.version}"; - hash = "sha256-vaUyDvCHseIYOQ7yQKLfa0QhiDt3nSPjEgidQRTj8v0="; + hash = "sha256-/Jpfg592UcQtlSVKInQyA5cT9EjVZ+XvpLMjIu/b4iU="; }; patches = [ diff --git a/pkgs/gamescope/default.nix b/pkgs/gamescope/default.nix index adabad68..b3db0fbc 100644 --- a/pkgs/gamescope/default.nix +++ b/pkgs/gamescope/default.nix @@ -6,13 +6,13 @@ # version shipped by the vendor, ensuring feature level is equivalent. gamescope'.overrideAttrs(old: rec { - version = "3.16.1"; + version = "3.15.15"; src = fetchFromGitHub { owner = "ValveSoftware"; repo = "gamescope"; rev = version; fetchSubmodules = true; - hash = "sha256-+0QGt4UADJmZok2LzvL+GBad0t4vVL4HXq27399zH3Y="; + hash = "sha256-FiPSGzfA3YH9TED8E5hpfpd+IQGthvwsxAFXZuqVZ4Q="; }; }) From 6ad0f1cd973048e2492d937e43c89a1983242e55 Mon Sep 17 00:00:00 2001 From: K900 Date: Sun, 12 Jan 2025 12:05:54 +0300 Subject: [PATCH 11/30] jovian-greeter: clean up type annotations --- pkgs/jovian-greeter/greeter.py | 54 ++++++++++++++++++---------------- 1 file changed, 28 insertions(+), 26 deletions(-) diff --git a/pkgs/jovian-greeter/greeter.py b/pkgs/jovian-greeter/greeter.py index 9f8b80fa..cefd19d4 100644 --- a/pkgs/jovian-greeter/greeter.py +++ b/pkgs/jovian-greeter/greeter.py @@ -11,7 +11,8 @@ import subprocess import sys from pathlib import Path -from typing import Any, Optional, Iterable, Mapping, List +from types import TracebackType +from typing import cast, override from systemd.journal import JournalHandler @@ -19,20 +20,20 @@ HELPER_PREFIX = Path('/run/current-system/sw/lib/jovian-greeter') class Session: - TYPE = 'tty' + TYPE: str = 'tty' def __init__(self, name: str, path: Path): - self.name = name + self.name: str = name with open(path, 'r') as f: - self.content = f.read() + self.content: str = f.read() - def get_command(self) -> Optional[List[str]]: + def get_command(self) -> list[str] | None: if command := self._get_property('Exec'): return command.split(' ') return None - def get_environment(self) -> List[str]: + def get_environment(self) -> list[str]: envs = [ f'XDG_SESSION_TYPE={self.TYPE}', f'XDG_SESSION_DESKTOP={self.name}', @@ -43,19 +44,20 @@ def get_environment(self) -> List[str]: return envs - def _get_property(self, property: str) -> Optional[str]: + def _get_property(self, property: str) -> str | None: if matches := re.search(f'^{property}=(.*)$', self.content, re.MULTILINE): return matches.group(1) return None class WaylandSession(Session): - TYPE = 'wayland' + TYPE: str = 'wayland' class XSession(Session): - TYPE = 'x11' + TYPE: str = 'x11' - def get_command(self) -> Optional[List[str]]: + @override + def get_command(self) -> list[str] | None: if command := super().get_command(): return [ 'startx', '/usr/bin/env' ] + command @@ -63,7 +65,7 @@ def get_command(self) -> Optional[List[str]]: class GreetdClient: def __init__(self, path: Path): - self.client = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM) + self.client: socket.socket = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM) self.client.connect(str(path)) def create_session(self, username: str): @@ -84,9 +86,9 @@ def create_session(self, username: str): raise RuntimeError('Bad response', response) - def start_session(self, command: List[str], environment: List[str]): + def start_session(self, command: list[str], environment: list[str]): try: - subprocess.check_call(["plymouth", "quit", "--retain-splash", "--wait"]) + _ = subprocess.check_call(["plymouth", "quit", "--retain-splash", "--wait"]) except Exception as ex: logging.debug("Failed to stop Plymouth", exc_info=ex) @@ -110,24 +112,24 @@ def start_session(self, command: List[str], environment: List[str]): raise RuntimeError('Bad response', response) - def _send(self, data: dict): + def _send(self, data: dict[str, str | list[str]]): payload = bytes(json.dumps(data), encoding='utf-8') self.client.sendall(struct.pack('=I', len(payload))) self.client.sendall(payload) - def _recv(self) -> Mapping[str, Any]: - length = self.client.recv(4, socket.MSG_WAITALL) - (length,) = struct.unpack('=I', length) - payload = self.client.recv(length, socket.MSG_WAITALL) - return json.loads(payload) + def _recv(self) -> dict[str, str]: + length_bytes = self.client.recv(4, socket.MSG_WAITALL) + length: tuple[int] = struct.unpack('=I', length_bytes) + payload = self.client.recv(length[0], socket.MSG_WAITALL) + return cast(dict[str, str], json.loads(payload)) class Context: def __init__(self, user: str, home: Path): - self.user = user - self.home = home - self.xdg_data_dirs = os.environ.get('XDG_DATA_DIRS', '').split(':') + self.user: str = user + self.home: Path = home + self.xdg_data_dirs: list[str] = os.environ.get('XDG_DATA_DIRS', '').split(':') - def next_session(self) -> Optional[Session]: + def next_session(self) -> Session | None: sessions = [ DEFAULT_SESSION ] if next_session := self._consume_session(): @@ -135,7 +137,7 @@ def next_session(self) -> Optional[Session]: return self._find_sessions(sessions) - def _consume_session(self) -> Optional[str]: + def _consume_session(self) -> str | None: helper = HELPER_PREFIX.joinpath('consume-session') if helper.exists(): logging.debug('Using pkexec helper') @@ -167,7 +169,7 @@ def _consume_session(self) -> Optional[str]: return next_session - def _find_sessions(self, sessions: Iterable[str]) -> Optional[Session]: + def _find_sessions(self, sessions: list[str]) -> Session | None: for data_dir in self.xdg_data_dirs + [ '/usr/share' ]: data_dir = Path(data_dir) for session in sessions: @@ -183,7 +185,7 @@ def _find_sessions(self, sessions: Iterable[str]) -> Optional[Session]: return None -def handle_exception(exc_type, exc_value, exc_traceback): +def handle_exception(exc_type: type[Exception], exc_value: Exception, exc_traceback: TracebackType): if issubclass(exc_type, KeyboardInterrupt): sys.__excepthook__(exc_type, exc_value, exc_traceback) return From f2da0647def2171c822b255d3e26f3b700344d04 Mon Sep 17 00:00:00 2001 From: K900 Date: Sun, 12 Jan 2025 12:15:36 +0300 Subject: [PATCH 12/30] jovian-greeter: just bring our own setuid wrapper No need for pkexec, also remove fallback path that basically never works --- modules/steam/autostart.nix | 19 ++----- pkgs/jovian-greeter/consume-session | 26 --------- .../jovian-greeter/consume-session/Cargo.lock | 46 +++++++++++++++ .../jovian-greeter/consume-session/Cargo.toml | 7 +++ .../consume-session/src/main.rs | 23 ++++++++ pkgs/jovian-greeter/default.nix | 19 +++++-- pkgs/jovian-greeter/greeter.py | 57 +++++++------------ 7 files changed, 113 insertions(+), 84 deletions(-) delete mode 100755 pkgs/jovian-greeter/consume-session create mode 100644 pkgs/jovian-greeter/consume-session/Cargo.lock create mode 100644 pkgs/jovian-greeter/consume-session/Cargo.toml create mode 100644 pkgs/jovian-greeter/consume-session/src/main.rs diff --git a/modules/steam/autostart.nix b/modules/steam/autostart.nix index 01a6f0c8..d906a28f 100644 --- a/modules/steam/autostart.nix +++ b/modules/steam/autostart.nix @@ -134,21 +134,12 @@ in ''; }; - environment = { - systemPackages = [ pkgs.jovian-greeter.helper ]; - pathsToLink = [ "lib/jovian-greeter" ]; + security.wrappers.jovian-consume-session = { + source = "${pkgs.jovian-greeter.helper}/bin/consume-session"; + owner = cfg.user; + group = "users"; + setuid = true; }; - security.polkit.extraConfig = '' - polkit.addRule(function(action, subject) { - if ( - action.id == "org.freedesktop.policykit.exec" && - action.lookup("program") == "/run/current-system/sw/lib/jovian-greeter/consume-session" && - subject.user == "jovian-greeter" - ) { - return polkit.Result.YES; - } - }); - ''; xdg.portal.configPackages = mkDefault [ pkgs.gamescope-session ]; }) diff --git a/pkgs/jovian-greeter/consume-session b/pkgs/jovian-greeter/consume-session deleted file mode 100755 index 7479fe5f..00000000 --- a/pkgs/jovian-greeter/consume-session +++ /dev/null @@ -1,26 +0,0 @@ -#!/usr/bin/env bash -set -euo pipefail - -if [[ "$#" != "1" ]]; then - >&2 echo "Usage: $0 " - exit 1 -fi - -user="$1" -uid=$(id -u "$user") -if [[ "$uid" -lt "1000" ]]; then - >&2 echo "UID $uid is too low" - exit 1 -fi - -home=$(eval echo ~"$user") -if ! [[ "$home" == /* ]]; then - >&2 echo "Invalid home directory" - exit 1 -fi - -session_file="$home/.local/state/steamos-session-select" -if [[ -e "$session_file" ]]; then - cat "$session_file" - rm "$session_file" -fi diff --git a/pkgs/jovian-greeter/consume-session/Cargo.lock b/pkgs/jovian-greeter/consume-session/Cargo.lock new file mode 100644 index 00000000..a8518a48 --- /dev/null +++ b/pkgs/jovian-greeter/consume-session/Cargo.lock @@ -0,0 +1,46 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 4 + +[[package]] +name = "bitflags" +version = "2.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1be3f42a67d6d345ecd59f675f3f012d6974981560836e938c22b424b85ce1be" + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "cfg_aliases" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724" + +[[package]] +name = "consume-session" +version = "0.1.0" +dependencies = [ + "nix", +] + +[[package]] +name = "libc" +version = "0.2.169" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" + +[[package]] +name = "nix" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "71e2746dc3a24dd78b3cfcb7be93368c6de9963d30f43a6a73998a9cf4b17b46" +dependencies = [ + "bitflags", + "cfg-if", + "cfg_aliases", + "libc", +] diff --git a/pkgs/jovian-greeter/consume-session/Cargo.toml b/pkgs/jovian-greeter/consume-session/Cargo.toml new file mode 100644 index 00000000..6db29b66 --- /dev/null +++ b/pkgs/jovian-greeter/consume-session/Cargo.toml @@ -0,0 +1,7 @@ +[package] +name = "consume-session" +version = "0.1.0" +edition = "2021" + +[dependencies] +nix = { version = "*", features = ["user"] } diff --git a/pkgs/jovian-greeter/consume-session/src/main.rs b/pkgs/jovian-greeter/consume-session/src/main.rs new file mode 100644 index 00000000..e49c7fa0 --- /dev/null +++ b/pkgs/jovian-greeter/consume-session/src/main.rs @@ -0,0 +1,23 @@ +use nix::unistd::{Uid, User}; +use std::{fs, io}; + +fn main() { + let uid = Uid::effective(); + let user = User::from_uid(uid) + .expect("Unable to get current user info") + .expect("Current user does not exist"); + let mut path = user.dir; + path.push(".local/state/steamos-session-select"); + + let session = fs::read_to_string(&path); + match session { + Ok(s) => { + print!("{}", s); + fs::remove_file(&path).expect("Failed to remove session file"); + }, + Err(e) => match e.kind() { + io::ErrorKind::NotFound => {} + _ => eprintln!("Error when reading session file: {:?}", e), + }, + } +} diff --git a/pkgs/jovian-greeter/default.nix b/pkgs/jovian-greeter/default.nix index 829e3da4..24c12c16 100644 --- a/pkgs/jovian-greeter/default.nix +++ b/pkgs/jovian-greeter/default.nix @@ -1,10 +1,8 @@ -{ lib, stdenv, python3, plymouth, shellcheck, nodePackages }: +{ lib, stdenv, python3, plymouth, shellcheck, nodePackages, rustPlatform }: stdenv.mkDerivation { name = "jovian-greeter"; - outputs = [ "out" "helper" ]; - src = ./.; nativeBuildInputs = [ python3.pkgs.wrapPython ]; @@ -19,7 +17,6 @@ stdenv.mkDerivation { checkPhase = '' runHook preCheck - shellcheck ./consume-session pyright *.py runHook postCheck @@ -31,8 +28,18 @@ stdenv.mkDerivation { install -Dm555 greeter.py $out/bin/jovian-greeter wrapPythonPrograms --prefix PATH : ${lib.makeBinPath [ plymouth ]} - install -Dm555 ./consume-session $helper/lib/jovian-greeter/consume-session - runHook postInstall ''; + + passthru.helper = rustPlatform.buildRustPackage { + pname = "jovian-consume-session"; + version = "0.0.1"; + + src = ./consume-session; + + cargoLock.lockFile = ./consume-session/Cargo.lock; + + # avoid a second rebuild + doCheck = false; + }; } diff --git a/pkgs/jovian-greeter/greeter.py b/pkgs/jovian-greeter/greeter.py index cefd19d4..21d5d8c9 100644 --- a/pkgs/jovian-greeter/greeter.py +++ b/pkgs/jovian-greeter/greeter.py @@ -17,7 +17,6 @@ from systemd.journal import JournalHandler DEFAULT_SESSION = 'gamescope-wayland' -HELPER_PREFIX = Path('/run/current-system/sw/lib/jovian-greeter') class Session: TYPE: str = 'tty' @@ -86,15 +85,20 @@ def create_session(self, username: str): raise RuntimeError('Bad response', response) - def start_session(self, command: list[str], environment: list[str]): + def start_session(self, session: Session): try: _ = subprocess.check_call(["plymouth", "quit", "--retain-splash", "--wait"]) except Exception as ex: logging.debug("Failed to stop Plymouth", exc_info=ex) - command = [ 'systemd-cat', '--identifier=jovian-session', '--' ] + command + session_command = session.get_command() + if not session_command: + raise RuntimeError('Session does not have a command') - logging.info("Starting session '%s'", DEFAULT_SESSION) + command = [ 'systemd-cat', '--identifier=jovian-session', '--' ] + session_command + environment = session.get_environment() + + logging.info("Starting session '%s'", session.name) logging.info("Command: %s", command) logging.info("Environment: %s", environment) self._send({ @@ -124,9 +128,8 @@ def _recv(self) -> dict[str, str]: return cast(dict[str, str], json.loads(payload)) class Context: - def __init__(self, user: str, home: Path): + def __init__(self, user: str): self.user: str = user - self.home: Path = home self.xdg_data_dirs: list[str] = os.environ.get('XDG_DATA_DIRS', '').split(':') def next_session(self) -> Session | None: @@ -138,31 +141,14 @@ def next_session(self) -> Session | None: return self._find_sessions(sessions) def _consume_session(self) -> str | None: - helper = HELPER_PREFIX.joinpath('consume-session') - if helper.exists(): - logging.debug('Using pkexec helper') - res = subprocess.run( - ['/run/wrappers/bin/pkexec', helper, self.user], - stdin=subprocess.DEVNULL, - capture_output=True, - check=True, - env={'SHELL': '/bin/sh'} - ) - next_session = res.stdout.decode('utf-8').strip() - - if not next_session: - return None - - return next_session - - next_session_file = self.home.joinpath(".local/state/steamos-session-select") - if not next_session_file.exists(): - return None - - with open(next_session_file, 'r') as f: - next_session = f.read().strip() - - next_session_file.unlink() + res = subprocess.run( + ['/run/wrappers/bin/jovian-consume-session'], + stdin=subprocess.DEVNULL, + capture_output=True, + check=True, + env={}, + ) + next_session = res.stdout.decode('utf-8').strip() if not next_session: return None @@ -206,18 +192,13 @@ def handle_exception(exc_type: type[Exception], exc_value: Exception, exc_traceb sys.exit(1) user = sys.argv[1] - home = os.path.expanduser(f'~{user}/') socket_path = os.environ.get('GREETD_SOCK') - if not home: - logging.error(f'Home directory for {user} not found') - sys.exit(1) - if not socket_path: logging.error("GREETD_SOCK must be set") sys.exit(1) - ctx = Context(user, Path(home)) + ctx = Context(user) client = GreetdClient(Path(socket_path)) client.create_session(user) @@ -235,4 +216,4 @@ def handle_exception(exc_type: type[Exception], exc_value: Exception, exc_traceb logging.error(".desktop file doesn't contain Exec=") sys.exit(1) - client.start_session(command, environment) + client.start_session(session) From 7cfe5da090df1735751fcae11a77676155ead88e Mon Sep 17 00:00:00 2001 From: K900 Date: Wed, 15 Jan 2025 11:04:47 +0300 Subject: [PATCH 13/30] manifest: some small noop bumps --- support/manifest/mappings.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/support/manifest/mappings.toml b/support/manifest/mappings.toml index a55d26f6..295f2e8e 100644 --- a/support/manifest/mappings.toml +++ b/support/manifest/mappings.toml @@ -32,7 +32,7 @@ alsa-ucm-conf.check = "1.2.12-1.1" atomupd-daemon.ignore = true # FIXME: has some not-yet-upstream patches, maybe we want them in nixpkgs? -bluez.check = "5.79-1.5" +bluez.check = "5.79-1.6" # more A/B stuff bmap-tools.ignore = true @@ -201,7 +201,7 @@ linux-neptune-611.ignore = true lsb-release.ignore = true # packaging changes, removes a heavy dependency -maliit-keyboard.check = "2.3.1-3.1" +maliit-keyboard.check = "2.3.1-4.1" # nixpkgs is ahead currently mangohud.check = "0.7.2.rc3.r11.g31f2ca5-2.3" From 6bbb19666e753c18ef8af35f590cbc3ba42dd0ca Mon Sep 17 00:00:00 2001 From: K900 Date: Thu, 16 Jan 2025 09:03:17 +0300 Subject: [PATCH 14/30] decky-loader: pin pnpm_9 pnpm_10 is now in master and breaks the FODs, AGAIN. --- pkgs/decky-loader/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/decky-loader/default.nix b/pkgs/decky-loader/default.nix index 9c521ea4..f1f000b9 100644 --- a/pkgs/decky-loader/default.nix +++ b/pkgs/decky-loader/default.nix @@ -1,7 +1,7 @@ { lib , fetchFromGitHub , nodejs -, pnpm +, pnpm_9 , python3 , coreutils , psmisc @@ -17,7 +17,7 @@ python3.pkgs.buildPythonPackage rec { hash = "sha256-PViSR4q3ZLo0pnrbqzWSOHgYy2QlkKKLWtQcflBIkdU="; }; - pnpmDeps = pnpm.fetchDeps { + pnpmDeps = pnpm_9.fetchDeps { inherit pname version src; sourceRoot = "${src.name}/frontend"; hash = "sha256-26p0RoMfuZRVgTnYWdWK2qJwEJXeGWsBkVhp5TQyfGw="; @@ -29,7 +29,7 @@ python3.pkgs.buildPythonPackage rec { nativeBuildInputs = [ nodejs - pnpm.configHook + pnpm_9.configHook ]; preBuild = '' From 27a0ddac1a14e10ba98530f59db728951495f2ce Mon Sep 17 00:00:00 2001 From: K900 Date: Fri, 17 Jan 2025 18:11:37 +0300 Subject: [PATCH 15/30] linux-jovian: fix config on latest nixpkgs --- pkgs/linux-jovian/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/linux-jovian/default.nix b/pkgs/linux-jovian/default.nix index f031d730..2c54826c 100644 --- a/pkgs/linux-jovian/default.nix +++ b/pkgs/linux-jovian/default.nix @@ -141,6 +141,7 @@ buildLinux (args // rec { DRM_AMD_DC_SI = lib.mkForce (option no); DRM_AMD_DC_DCN = lib.mkForce (option no); DRM_AMD_DC_HDCP = lib.mkForce (option no); + FB_HYPERV = lib.mkForce (option no); DRM_HYPERV = lib.mkForce (option no); DRM_VMWGFX_FBCON = lib.mkForce (option no); KVM_GUEST = lib.mkForce (option no); From 34101f23b196469ff87ba508702e2b9a9da5be7e Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:00:18 -0500 Subject: [PATCH 16/30] README: Drop options page linking for now It contains a lot of implementation details. It might be confusing. --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index a5ba2015..8c5e88b6 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,6 @@ Pointers to helpful pages - The [Getting Started](docs/getting-started.md) page may be your first stop. - The [Configuration](docs/configuration.md) page guides you into configuring your system. - - The [Options](docs/options.md) is good to know all that you can do.

From 4e9992e3a209f1f840ca84d5e65242114434777e Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 12:59:35 -0500 Subject: [PATCH 17/30] docs: Add notes on the options page --- docs/options.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/docs/options.md b/docs/options.md index 7212376d..af892060 100644 --- a/docs/options.md +++ b/docs/options.md @@ -2,9 +2,15 @@ Jovian-NixOS adds a set of extra options that can be used in your NixOS configurations under the `jovian` prefix. +Most of these options are implementation details, and likely are not needed to be changed. + +See the [Getting Started](docs/getting-started.md) page and the [Configuration](docs/configuration.md) page for the options that matter. + +* * * +
> [!NOTE] -> The options listing is available on the website. +> [The options listing is available on the website.](https://jovian-experiments.github.io/Jovian-NixOS/options.html)
From ffe50290449291313464dde4bc38961710580f60 Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:01:15 -0500 Subject: [PATCH 18/30] docs: Drop options from main menu (moved into in-depth) --- support/docs/template/main.erb | 1 - 1 file changed, 1 deletion(-) diff --git a/support/docs/template/main.erb b/support/docs/template/main.erb index 2301dd8a..3b04c285 100644 --- a/support/docs/template/main.erb +++ b/support/docs/template/main.erb @@ -28,7 +28,6 @@ #["FAQ", "FAQ"], ["getting-started", "Getting Started"], ["in-depth", "In Depth"], - ["options", "Options"], ["packages", "Packages"], ["contributing", "Contributing"], # NOTE: keep last From c84997bec28121e3eda6b722a06a4bd85a1fd4c0 Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:01:26 -0500 Subject: [PATCH 19/30] docs: Add options to in-depth --- docs/in-depth.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/in-depth.md b/docs/in-depth.md index f4f8a57b..099992ed 100644 --- a/docs/in-depth.md +++ b/docs/in-depth.md @@ -4,3 +4,4 @@ In-Depth Learn more about: - [Using Decky Loader](in-depth/decky-loader.md) + - [All the options](options.md) From d2ec995594364e92e5be5f7e6ea53a6c8b38e4b7 Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:13:17 -0500 Subject: [PATCH 20/30] docs: Add notes on the packages page --- docs/packages.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/docs/packages.md b/docs/packages.md index c25b52e7..f3160c88 100644 --- a/docs/packages.md +++ b/docs/packages.md @@ -1,10 +1,16 @@ # Packages -Jovian-NixOS adds a set of extra packages that can be used in your NixOS configurations. +Jovian-NixOS provides an overlay with a set of extra packages. + +Most of these packages are used implicitly from the Jovian NixOS configuration, and are an implementation detail. + +See the [Getting Started](docs/getting-started.md) page and the [Configuration](docs/configuration.md) page for the options that will end-up using or enabling them. + +* * *
> [!NOTE] -> The options listing is available on the website only. +> [The packages listing is available on the website only.](https://jovian-experiments.github.io/Jovian-NixOS/packages.html)
From d1b0c697b586d3b58399bd352e4d09edc3d53048 Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:16:14 -0500 Subject: [PATCH 21/30] docs: Drop packages from main menu (moved into in-depth) --- support/docs/template/main.erb | 1 - 1 file changed, 1 deletion(-) diff --git a/support/docs/template/main.erb b/support/docs/template/main.erb index 3b04c285..e29f6720 100644 --- a/support/docs/template/main.erb +++ b/support/docs/template/main.erb @@ -28,7 +28,6 @@ #["FAQ", "FAQ"], ["getting-started", "Getting Started"], ["in-depth", "In Depth"], - ["packages", "Packages"], ["contributing", "Contributing"], # NOTE: keep last ["search", "Search"], From cd7f39b1f4dd641639eb8a8fe75a3ac26b04d872 Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:16:40 -0500 Subject: [PATCH 22/30] docs: Add packages to in-depth --- docs/in-depth.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/in-depth.md b/docs/in-depth.md index 099992ed..239f4922 100644 --- a/docs/in-depth.md +++ b/docs/in-depth.md @@ -5,3 +5,4 @@ Learn more about: - [Using Decky Loader](in-depth/decky-loader.md) - [All the options](options.md) + - [All the packages](packages.md) From 1003079e1571357b39d2b9ca52e5f50f5d08565f Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:16:53 -0500 Subject: [PATCH 23/30] docs: Add FAQ to main menu Now that we removed two options... --- support/docs/template/main.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/support/docs/template/main.erb b/support/docs/template/main.erb index e29f6720..fb5df4ee 100644 --- a/support/docs/template/main.erb +++ b/support/docs/template/main.erb @@ -25,8 +25,8 @@
    <% [ - #["FAQ", "FAQ"], ["getting-started", "Getting Started"], + ["FAQ", "FAQ"], ["in-depth", "In Depth"], ["contributing", "Contributing"], # NOTE: keep last From 82bf69ba5cc118df46f3eb80ffaca1269e9c3b5e Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:06:13 -0500 Subject: [PATCH 24/30] docs: Update for pagefind deprecation notices MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 2 configuration warning(s): The `bundle-dir` option is deprecated as of Pagefind 1.0. Use either `output-subdir` or `output-path` instead: cli: --output-subdir config: output_subdir env: PAGEFIND_OUTPUT_SUBDIR └─ "Where to output the search files, relative to the processed site" cli: --output-path config: output_path env: PAGEFIND_OUTPUT_PATH └─ "Where to output the search files, relative to the working directory of the command" The `source` option is deprecated as of Pagefind 1.0. The `source` option has been renamed to `site`: cli: --site config: site env: PAGEFIND_SITE └─ "The location of your built static website" --- support/docs/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/support/docs/default.nix b/support/docs/default.nix index c52e655a..0074a7ef 100644 --- a/support/docs/default.nix +++ b/support/docs/default.nix @@ -87,10 +87,10 @@ let # https://pagefind.app/docs/hosting/#hosting-on-github-pages pagefind \ --verbose \ - --bundle-dir !pagefind \ + --output-subdir !pagefind \ --root-selector 'body > main' \ --keep-index-url \ - --source . + --site . for p in "''${OPT_OUT[@]}"; do mv -v $p.xxx $p.html From f3a52708472db2a4acf02e6a4506afd092331c43 Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:15:47 -0500 Subject: [PATCH 25/30] docs: Change "Volume-" to "Volume Down" The wording otherwise feels odd, now that I re-read it. --- docs/devices/valve-steam-deck/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/devices/valve-steam-deck/index.md b/docs/devices/valve-steam-deck/index.md index abed8a14..cad5c074 100644 --- a/docs/devices/valve-steam-deck/index.md +++ b/docs/devices/valve-steam-deck/index.md @@ -28,4 +28,4 @@ Connect to the dock via USB-C and run `jupiter-dock-updater` to update. Helpful Tips ------------ -To enter the boot menu, power off the Steam Deck then hold down `Volume-` and tap the `Power` button. +To enter the boot menu, power off the Steam Deck then hold down `Volume Down` and tap the `Power` button. From 0fbe80d84a48176a709e23bbcbe42d07c7aba96d Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:29:51 -0500 Subject: [PATCH 26/30] docs: Fix headings in FAQ --- docs/FAQ.md | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/docs/FAQ.md b/docs/FAQ.md index fd8f1503..5dc8943b 100644 --- a/docs/FAQ.md +++ b/docs/FAQ.md @@ -1,10 +1,10 @@ FAQ === -> **Jovian** +> **Jovian** > “Relating to [...] Jupiter or the class of [...] which Jupiter belongs.” -> What's Jupiter? +### What's Jupiter? [There's a disambiguation page that won't help you](https://en.wikipedia.org/wiki/Jupiter_(disambiguation)). It's not known *exactly* what it's the codename for. @@ -12,9 +12,7 @@ It is either the codename for the Steam Deck, or the codename for the new Steam Things get awfully murky with *Neptune* also being a thing, and it's unclear from the outside what it is. To the best of our knowledge, Jupiter is the OS. -* * * - -> What channels are supported? +### What channels are supported? Truthfully, no channel is *supported*, but the older the stable release was cut, the more likely the additions from Jovian NixOS won't work as expected. From 688f4a95c2830d3393ed7f9f163fd9d5e2d33661 Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:30:05 -0500 Subject: [PATCH 27/30] docs: De-prioritize section about options And fixup headings --- docs/configuration.md | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/docs/configuration.md b/docs/configuration.md index b71d1279..3f5b3a36 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -1,10 +1,7 @@ Configuration ============= -All available module options along with their descriptions can be found under `modules`. -The options are also listed on the [options page in the documentation](https://jovian-experiments.github.io/Jovian-NixOS/options.html). - -### Using the Steam Deck UI +## Using the Steam Deck UI To use the Steam Deck UI, set `jovian.steam.enable = true;` in your configuration. @@ -13,7 +10,7 @@ This will only enable the Steam Deck UI tooling. The Steam Deck UI can be used in different manners. -#### Autostart +### Autostart (*This is the preferred way to use the Steam Deck interface*) @@ -28,14 +25,14 @@ If you want the *Switch to Desktop* menu option to switch to another session, yo Configure it with the name of the X11 or Wayland session of your choosing. The session name semantics are the same as for the `services.displayManager.defaultSession` NixOS option. -#### As a user session +### As a user session Select the *Gaming Mode* sesssion in your Display Manager, or run `start-gamescope-session` in a VT. The *Switch to Desktop* option will not work as intended, instead it will close Steam. -#### As a *nested* window +### As a *nested* window Run `gamescope-session` within an existing desktop session. @@ -44,3 +41,12 @@ This will run [gamescope](https://github.com/ValveSoftware/gamescope) in nested Usage as a *nested* window is less tested, and may have other undesirable idiosyncrasies. The *Switch to Desktop* option will not work as intended, instead it will close Steam. + + +## Going further + +This is a NixOS system, you can do much more. +[All the usual NixOS options are available](https://search.nixos.org/options?channel=unstable). + +In addition to that, all the Jovian NixOS options, including internal implementation details, +are listed on the [options page in the documentation](https://jovian-experiments.github.io/Jovian-NixOS/options.html). From b862b7b03eb9e78ae36027dbc23ac160a4b7a825 Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:30:36 -0500 Subject: [PATCH 28/30] docs: Fix `code` in links (looked weird) --- support/docs/styles/common/layout.less | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/support/docs/styles/common/layout.less b/support/docs/styles/common/layout.less index 01d65029..ad16e793 100644 --- a/support/docs/styles/common/layout.less +++ b/support/docs/styles/common/layout.less @@ -117,6 +117,11 @@ code, pre { border-radius: 0.5*@gutter; line-height: @line-height - (0.2); // border should not make line bigger } +a > code { + background: unset; + border: unset; + padding: unset; +} // Some page generators use that DOM layout. pre code { From 362ca520068f53402f1aa5b939910553f53797ae Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Sat, 18 Jan 2025 13:46:19 -0500 Subject: [PATCH 29/30] docs: Add note about CEF debugging for Decky Loader --- docs/in-depth/decky-loader.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/docs/in-depth/decky-loader.md b/docs/in-depth/decky-loader.md index b7ccf2ba..6a4c4a35 100644 --- a/docs/in-depth/decky-loader.md +++ b/docs/in-depth/decky-loader.md @@ -13,3 +13,12 @@ To enable *Decky Loader* in your configuration: }; } ``` + + +## It doesn't work + +There is a known issue where Decky Loader relies on CEF debugging to work, but enabling/disabling it *correctly* is awkward. + +See [the workaround in #460](https://github.com/Jovian-Experiments/Jovian-NixOS/issues/460#issuecomment-2599835660). + +Make sure you also enable CEF debugging imperatively. From 0f84a18f279916e8105b87d110613654c841be96 Mon Sep 17 00:00:00 2001 From: K900 Date: Wed, 22 Jan 2025 14:17:49 +0300 Subject: [PATCH 30/30] linux-jovian: 6.8.12-valve7 -> 6.8.12-valve11-jovian1 Revert the wake on BT commits as those seem to break resume on LCD Decks. --- pkgs/linux-jovian/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/linux-jovian/default.nix b/pkgs/linux-jovian/default.nix index 2c54826c..f7675182 100644 --- a/pkgs/linux-jovian/default.nix +++ b/pkgs/linux-jovian/default.nix @@ -4,8 +4,8 @@ let inherit (lib) versions; kernelVersion = "6.8.12"; - vendorVersion = "valve7"; - hash = "sha256-B0x40FuHeoE+9YBe3N3o2Hzz54hreCa6gQ0HFl7FzPU="; + vendorVersion = "valve11-jovian1"; + hash = "sha256-MBp504pWVynZUS3I3tnL8kfkrkH1+KXgWjBcru1y/7E="; in buildLinux (args // rec { version = "${kernelVersion}-${vendorVersion}";