-
-
Notifications
You must be signed in to change notification settings - Fork 12.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
nixos/steam: add protontricks submodule #309585
Conversation
FYI in the PR adding that it was explicitly asked to not expose that globally: see #189398 (comment) |
I see. @Atemu what do you think now that it has become an issue? Creating a module for everything that relies on it would be tedious both for me and the user, I think a global variable is the way. |
I don't think there's all that many tools which require steam-specific things. I'd be in favour of adding options for the one or two tools which actually need this. I honestly can't think of much else than As a general rule, one should never pollute the global namespace with env vars that only concern a handful of programs. As an escape hatch, you can also always run the tool inside steam-run. |
In that case, should I create a submodule like |
540eb19
to
2b8b941
Compare
Tested, how is this? Also, please point out formatting mistakes, not sure about this one. |
1f7cc6c
to
febf2d7
Compare
There we go, tested too, I'm still unsure about formatting however. |
I'll take a closer look later but I don't see any obvious formatting issues. Unless you're doing something utterly weird that doesn't fit into the rest of Nixpkgs, there aren't any strict rules yet until NixOS/rfcs#166 is implemented. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
febf2d7
to
32dc026
Compare
What is that ofborg error and where is the request change that's blocking the merge? |
It's an internal error that someone who maintains ofBorg will have to take a look at and manually remove at some point. It doesn't block the merge though, that's just my review. It'll stop blocking it as soon as I approve after I've taken a proper look or another committer comes around and dismisses it. |
bbf2920
to
50ab32c
Compare
Resolved conflicts, tested. |
@Atemu have you had a chance to look? It would be great if we could get this in before the next unstable merge. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Two minor things, otherwise LGTM.
nixos/modules/programs/steam.nix
Outdated
@@ -139,6 +146,11 @@ in { | |||
Load the extest library into Steam, to translate X11 input events to | |||
uinput events (e.g. for using Steam Input on Wayland) | |||
''; | |||
|
|||
protontricks = { | |||
enable = lib.mkEnableOption "Protontricks"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please consider users who may not know what protontricks is. The option to enable it should offer at least a little information on it.
We could also pull it from the package's meta like this:
enable = lib.mkEnableOption "Protontricks"; | |
enable = lib.mkEnableOption "protontricks, ${cfg.protontricks.package.meta.description}"; |
50ab32c
to
95a1183
Compare
Looks like your suggestion fails the documentation CI (and not just the CI, my system config errors too), apparently option descriptions can't rely on config/pkgs. |
95a1183
to
fcaec6b
Compare
Welp, adding it manually is the best I can come up with. |
Ah, indeed it makes sense; we don't have access to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Diff LGTM and the NixOS part appears to be working but I'm not sure protontricks is as it's giving me:
protontricks (ERROR): Could not find configured Proton installation!
protontricks (ERROR): Active Proton installation could not be found automatically.
Proton installation could not be found!
Though I'm also getting the same error when I steam-run
it which worked before?
Is it working on your end @diniamo?
Ah, wait I had to select a compat tool for the game once it seems; now it works flawlessly. |
Thanks! |
Nice, thanks |
…s-var nixos/steam: add protontricks submodule
Description of changes
The title is self-explanatory, as for the reason: other programs also rely on this variable to find proton versions, for example protontricks.
Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.