system-manager icon indicating copy to clipboard operation
system-manager copied to clipboard

feat: nixpkgs-ify and unflake-ify system-manager

Open soupglasses opened this issue 1 year ago • 4 comments

Make it easier to use system-manager as a flake-library.

Will remove from all dependents at least 230 lines worth of locks from this project (Example), while still keeping the same library.

Further adds flexibility to calling the libraries and package adding the possibility to use default.nix or invoking the files directly. (Example)

Note differences in calling lib.nix directly, the removal of the flake layout of default.nix being a breaking change, and most importantly the packages.nix only having a single wrapped binary output called system-manager instead of the four previous ones. Open to change anything here (like adding back packages).

Thanks for this project! :tada:

soupglasses avatar Sep 30 '24 23:09 soupglasses

Note, using system-manager outside of a flake.nix is entirely untested currently.

soupglasses avatar Sep 30 '24 23:09 soupglasses

Realize i removed treefmt, which could be added back.

soupglasses avatar Oct 02 '24 12:10 soupglasses

Added back treefmt support :+1:

soupglasses avatar Oct 02 '24 12:10 soupglasses

TODO: Should add in aliases for the removed packages? Possibly re-add them? Unsure if they are meant to be used outside of system-manager's development cycle.

soupglasses avatar Oct 09 '24 07:10 soupglasses

Seems #136 got squashed into feat: add overlay, not what i intended but its there.

soupglasses avatar Oct 29 '24 10:10 soupglasses

Fixed the incorrect squash :+1:

soupglasses avatar Oct 29 '24 10:10 soupglasses

Tried to find a better way to expose the nix-vm-test project, but i cannot really find a good way to let it auto update but also not propagate as a dev dependency to all users of system-manager.

We could eye out moving all the nix libraries in here to a system-manager-modules as well as making a PR to nixpkgs to add a system-manager based upon the work here. Then it would become a lot simpler to use system-manager, and there wouldn't be a need to simply the developer nix flake here. Only add a new input for inputs.system-manager-modules for the modules.

But it is annoying to have to split it up like this however.

soupglasses avatar Oct 29 '24 11:10 soupglasses

Another way is to create a ./dev flake, we do this in a couple of projects. It allows hiding the dev dependencies from the user's flake.lock. You can find an example of it in https://github.com/nix-community/srvos. This would make the management of the nix-vm-test input easier.

But this is good enough to be merged already.

zimbatm avatar Oct 30 '24 20:10 zimbatm