You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
how would i go about combining shells? I tried the below but it doesn't work, why? Should I use modules?
For example I'd like to do:
devshells={default={devshell={name="My main shell";packagesFrom=[config.devShells.haskellconfig.devShells.utils];};};utils={devshell.name="My subproject shell";commands=[{name="my-util";command="${pkgs.utils}/bin/my-util";}];};}
defining an utils shell with the devshell module and combining it with a classical derivation based shell config.devShells.haskell that for example is created by some library code and I don't define it by myself.
Or combine two or more shells of whatever flavor together, best getting information about conflicts.
In the example above, the resulting default shell indeed has all the commands coming from the haskell shell, but the my-util commad is missing from it. Why?
Given that devshells use module system, it's possible to share devshells by sharing modules. BUT I would like to understand why the above doesn't include my-utils inside shell? Together with #310 where I ask about the packages argument.
Activity
zmrocze commentedon May 17, 2024
PS: Ah, also, with traditional devShells I can use mergeShells and merge not only inputs but also
shellHooks.It would be cool to have a matching solution with devshells, so that it's matter of setting a single option instead of the two:
What do you guys think?
zmrocze commentedon May 17, 2024
PS: Merging by module import is not that straightforward, because on options like
namethere's always going to be conflicts.So: how to combine shells?
micharied commentedon Jan 8, 2025
Hey are there any news on this. I would love to combine my shell created by haskellPackages.shellFor with devshells