Skip to content

Conversation

@Andy3153
Copy link

@Andy3153 Andy3153 commented Jan 22, 2025

This way, nothing changes in the configuration if you add the module to it and do nothing else.

My usecase (1 2) is that I want a "Steam Deck UI" specialisation in my configuration, because the configuration is for a computer that I use for other things too, so I want to sometimes go into the Deck UI mode, accessible through an entry in my bootloader (basically how speicialisations work), and I don't want this module's overlay to apply globally, I only want it applying to the packages under the specific specialisation.

Plus AFAIK it's bad practice to do something upon just importing a module and not setting any options.

@K900
Copy link
Contributor

K900 commented Jan 23, 2025

Does the overlay actually cause any issues for you? It should be additive only.

@Andy3153
Copy link
Author

Didn't even rebuild with the upstream module. I only used it after I made the fork to create the option to make this pull request. So I am not sure it will ever cause any issues. But it's better if modules don't do anything if they are just imported, and I guess it's an extra choice if someone wants to have it

@K900
Copy link
Contributor

K900 commented Jan 23, 2025

Well building with this will just break everyone, because all the other modules assume the packages to be there.

@Andy3153
Copy link
Author

The default of the jovian.overlay.enable option is jovian.steam.enable, so it's enabled whenever Steam is. So it should cause no issues. Please do tell me if it needs to be enabled whenever any other option is enabled so I can make a change.

@K900
Copy link
Contributor

K900 commented Jan 23, 2025

I don't think we want to support this, honestly, unless you force-enable it in every single possible module that relies on the packages.

@Andy3153
Copy link
Author

Sure thing. I'll do that later today, then. Can you tell me where else it needs enabling in the meanwhile? Or, I'll just look at it later today

@K900
Copy link
Contributor

K900 commented Jan 23, 2025

Basically everywhere. You can go through the list and check for references to the packages added in the overlay.

This way, nothing changes in the configuration if you add the module to it and
do nothing else
@Andy3153
Copy link
Author

Here you go, I did it. My bad for not commenting earlier, I finished it but didn't have time to test it until now.

@K900 K900 requested a review from samueldr January 27, 2025 08:03
@sg-qwt
Copy link
Contributor

sg-qwt commented Feb 2, 2025

Since you're using flake, another way to achieve this is by leveraging readOnlyPkgs and passing pkgs explicitly on your own control.
That way you can just choose whether to pass normal pkgs or jovian overlayed one like (pkgs.extend jovian.overlays.default) for example. Of course, this case overlays are not enabled by default, you can decide when to apply them on demand.

@Andy3153
Copy link
Author

Andy3153 commented Feb 5, 2025

True, but, again, it's good for modules to not do anything upon just importing them

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants