dioxus icon indicating copy to clipboard operation
dioxus copied to clipboard

Added `dx create` options to skip user interaction

Open Andrew15-5 opened this issue 1 year ago • 3 comments

This PR is being made with the help from @ealmloff in the https://discord.com/channels/899851952891002890/1200469217884000288.

Closes #1871.

Andrew15-5 avatar Jan 27 '24 18:01 Andrew15-5

The CLI command that works is dx create -n name -y -o platform=web -o router=true -o styling=Vanilla.

The problem we discovered is that it looks like cargo-generate doesn't support "using default values" with silent (yet). https://github.com/cargo-generate/cargo-generate/issues/1114 (can be considered blocking)

Andrew15-5 avatar Jan 27 '24 20:01 Andrew15-5

This is a blocking issue: https://github.com/DioxusLabs/dioxus-template/issues/23. It needs to be resolved first to avoid breaking changes. Since you only can create cargo project interactively, the changes will not break anything, IMO.

I also want to create other similar small issues, to streamline the cargo-generate.toml to work nicely with the new dx CLI options.

Andrew15-5 avatar Jan 28 '24 10:01 Andrew15-5

Now that default options are working, sub templates ware added to the template...aaand there default sub template is not working: https://github.com/cargo-generate/cargo-generate/issues/1181. :/

But you can still manually select it. When that issue will be resolved, ideally, just updating the cargo-generate version should fix it in dx. So, not really a blocker.

Andrew15-5 avatar Apr 29 '24 22:04 Andrew15-5