gay ming it works soooo goood but looks are bad will make clean
This commit is contained in:
@@ -29,6 +29,7 @@ in
|
||||
./system/hardware.nix
|
||||
./system/fonts.nix
|
||||
inputs.home-manager.nixosModules.home-manager
|
||||
inputs.jovian.nixosModules.default
|
||||
#inputs.niri.nixosModules.niri
|
||||
];
|
||||
|
||||
@@ -61,6 +62,7 @@ in
|
||||
"docker"
|
||||
"libvirt"
|
||||
"input"
|
||||
"seat"
|
||||
];
|
||||
packages = with pkgs; [ ];
|
||||
};
|
||||
@@ -77,25 +79,31 @@ in
|
||||
"docker"
|
||||
"libvirt"
|
||||
"input"
|
||||
"seat"
|
||||
];
|
||||
packages = with pkgs; [ ];
|
||||
};
|
||||
|
||||
users.game = {
|
||||
isNormalUser = true;
|
||||
description = "Dedicated gaming user (auto-login in Steam specialisation)";
|
||||
shell = pkgs.bash;
|
||||
createHome = true;
|
||||
password = ""; # no password
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"video"
|
||||
"render"
|
||||
"input"
|
||||
"seat"
|
||||
"networkmanager"
|
||||
];
|
||||
home = "/home/game";
|
||||
};
|
||||
groups.libvirtd.members = [
|
||||
"mrfluffy"
|
||||
"work"
|
||||
];
|
||||
};
|
||||
# greetd + tuigreet
|
||||
services.greetd = {
|
||||
enable = true;
|
||||
restart = true;
|
||||
useTextGreeter = true;
|
||||
settings.default_session = {
|
||||
command = "${lib.getExe pkgs.tuigreet} --window-padding 1 --time --time-format '%R - %F' --remember --remember-session --asterisks";
|
||||
user = "greeter";
|
||||
};
|
||||
};
|
||||
##############################################################################
|
||||
# Home-Manager
|
||||
##############################################################################
|
||||
@@ -104,6 +112,7 @@ in
|
||||
users = {
|
||||
mrfluffy = import ./home/mrfluffy.nix;
|
||||
work = import ./home/work.nix;
|
||||
game = import ./home/game.nix;
|
||||
};
|
||||
};
|
||||
|
||||
@@ -141,6 +150,21 @@ in
|
||||
permittedInsecurePackages = [ ];
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# decky
|
||||
##############################################################################
|
||||
nixpkgs.overlays = [
|
||||
inputs.jovian.overlays.default
|
||||
];
|
||||
jovian.decky-loader = {
|
||||
enable = true;
|
||||
user = "game"; # Run as your gaming user
|
||||
stateDir = "/home/game/.local/share/decky"; # Store plugins/data in user's home (adjust if preferred)
|
||||
# Optional: Add extra packages if needed for specific plugins
|
||||
# extraPackages = with pkgs; [ some-package ];
|
||||
# extraPythonPackages = ps: with ps; [ some-python-package ];
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# State version
|
||||
##############################################################################
|
||||
@@ -149,36 +173,64 @@ in
|
||||
specialisation = {
|
||||
"01-steam" = {
|
||||
configuration = {
|
||||
|
||||
boot = {
|
||||
kernelParams = lib.mkForce [ "ipv6e=1" "quiet" "splash"];
|
||||
plymouth = {
|
||||
enable = true;
|
||||
themePackages = [ pkgs.adi1090x-plymouth-themes ];
|
||||
theme = "abstract_ring_alt";
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
# ── HDMI-CEC: Turn on TV when Steam specialisation starts ─────────────────────
|
||||
services.udev.packages = [ pkgs.libcec ]; # ensures cec-utils is in PATH
|
||||
services.blueman.enable = true;
|
||||
services.seatd.enable = true;
|
||||
|
||||
# A user service that runs once the graphical session (Steam/GameScope) is ready
|
||||
systemd.user.services.cec-tv-on = {
|
||||
description = "Turn on TV via HDMI-CEC when entering Steam specialisation";
|
||||
wantedBy = [ "graphical-session.target" ];
|
||||
after = [ "graphical-session.target" ];
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
RemainAfterExit = true;
|
||||
ExecStart = toString (
|
||||
pkgs.writeShellScript "cec-tv-on.sh" ''
|
||||
# Wait a moment for the HDMI link to settle
|
||||
sleep 3
|
||||
#systemd.user.services.cec-tv-on = {
|
||||
# description = "Turn on TV via HDMI-CEC when entering Steam specialisation";
|
||||
# wantedBy = [ "graphical-session.target" ];
|
||||
# after = [ "graphical-session.target" ];
|
||||
# serviceConfig = {
|
||||
# Type = "oneshot";
|
||||
# RemainAfterExit = true;
|
||||
# ExecStart = toString (
|
||||
# pkgs.writeShellScript "cec-tv-on.sh" ''
|
||||
# # Wait a moment for the HDMI link to settle
|
||||
# sleep 3
|
||||
|
||||
# Turn on the TV and set it as active source (most TVs understand this)
|
||||
${pkgs.libcec}/bin/cec-client -s -d 1 <<EOF
|
||||
on 0
|
||||
as
|
||||
EOF
|
||||
# # Turn on the TV and set it as active source (most TVs understand this)
|
||||
# ${pkgs.libcec}/bin/cec-client -s -d 1 <<EOF
|
||||
# on 0
|
||||
# as
|
||||
# EOF
|
||||
|
||||
# Alternative one-liner if the above somehow fails:
|
||||
# echo 'on 0' | ${pkgs.libcec}/bin/cec-client -s -d 1
|
||||
# echo 'as' | ${pkgs.libcec}/bin/cec-client -s -d 1
|
||||
''
|
||||
);
|
||||
# # Alternative one-liner if the above somehow fails:
|
||||
# # echo 'on 0' | ${pkgs.libcec}/bin/cec-client -s -d 1
|
||||
# # echo 'as' | ${pkgs.libcec}/bin/cec-client -s -d 1
|
||||
# ''
|
||||
# );
|
||||
# };
|
||||
#};
|
||||
|
||||
# THIS is the important part – direct boot into the Gamescope Steam session
|
||||
services.greetd = {
|
||||
enable = true;
|
||||
restart = true;
|
||||
settings = {
|
||||
# Tell greetd to auto-start the official gamescope steam session immediately
|
||||
default_session = {
|
||||
command = "${pkgs.gamescope}/bin/gamescope --prefer-outpu HDMI-A-2 --hdr-enabled --steam --mangoapp -- steam -pipewire-dmabuf -gamepadui -steamos3 > /dev/null 2>&1";
|
||||
user = "game";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# Auto-login the game user (no password prompt ever)
|
||||
services.getty.autologinUser = "game";
|
||||
# Make sure the user service starts automatically
|
||||
systemd.user.targets.graphical-session = {
|
||||
# This target already exists, we just ensure it’s active
|
||||
@@ -192,9 +244,10 @@ in
|
||||
systemPackages = with pkgs; [
|
||||
mangohud
|
||||
gamemode
|
||||
gamescope-wsi
|
||||
];
|
||||
variables = {
|
||||
LIBSEAT_BACKEND = "logind";
|
||||
#LIBSEAT_BACKEND = "logind";
|
||||
};
|
||||
|
||||
};
|
||||
@@ -213,14 +266,10 @@ in
|
||||
gamescope
|
||||
mangohud
|
||||
gamemode
|
||||
gamescope-wsi
|
||||
];
|
||||
gamescopeSession = {
|
||||
enable = true;
|
||||
args = [
|
||||
"--prefer-output"
|
||||
"HDMI-A-2"
|
||||
"--hdr-enabled"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
@@ -239,6 +288,17 @@ in
|
||||
#inputs.niri.nixosModules.niri
|
||||
];
|
||||
|
||||
# greetd + tuigreet
|
||||
services.greetd = {
|
||||
enable = true;
|
||||
restart = true;
|
||||
useTextGreeter = true;
|
||||
settings.default_session = {
|
||||
command = "${lib.getExe pkgs.tuigreet} --window-padding 1 --time --time-format '%R - %F' --remember --remember-session --asterisks";
|
||||
user = "greeter";
|
||||
};
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# Desktop / WM
|
||||
##############################################################################
|
||||
@@ -266,7 +326,7 @@ in
|
||||
# Hyprland
|
||||
programs.hyprland = {
|
||||
enable = useHypr;
|
||||
package = inputs.hyprland.packages.${pkgs.system}.hyprland;
|
||||
package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
|
||||
};
|
||||
|
||||
# X11 base (kept enabled for keymap + DM if needed)
|
||||
|
||||
Reference in New Issue
Block a user