Open stuzenz opened 1 month ago
Related to this question - is there a way to call a different template on the devenv init command? Or at the very least a way to modify the standard init file template?
@Bullish-Design can you say more what you'd like, to provide your own template or just have a better default collection?
@domenkozar - I'm looking for the ability to provide my own template - ideally different templates via the CLI init command. I tend to have similar project setups, so it would be handy to be able to call a standard "Python-Data" template for one project, then a "Rust-Backend" for the next.
A public template repository accessible from the CLI could work well.
Maybe not a high priority, thought it would be worth noting another possible UX/DX opportunity.
As much as the current workflow and API to declare environments using devenv is great, I feel that a nice counterpart for
devenv init
could be adevenv scaffold
command where you might even have some auto-suggest/completion working with itThe end result would be something like what we have in the examples folder of the devenv project where the devenv.yaml and devenv.nix config is declared based on the scaffold request.
It would only be for a starting point to further work with - but it could be a nice opinionated way to provide a starting position for the devenv.nix that goes beyond the empty slate start currently provided by
devenv init
.Thinking out loud here, the naming conventions for the scaffolding options could closely align with the existing schema. However, if an auto-suggest feature were integrated into the terminal, it could significantly enhance usability.
For example, the command might look like this:
devenv scaffold languages.python venv pkgs.pip languages.rust cargo services.postgres
Or even continuing with the same
devenv init
command, but parse it for additional options.devenv init languages.python venv pkgs.pip languages.rust cargo services.postgres
I think the scaffolding idea aligns with the thinking behind devenv - that it would reduce some friction from a DX perspective in setting up environments.