Skip to content

Feat: CLI wasm-bindgen-cli Installer#3335

Merged
jkelleyrtp merged 14 commits intoDioxusLabs:mainfrom
DogeDark:cli-bindgen-install
Dec 11, 2024
Merged

Feat: CLI wasm-bindgen-cli Installer#3335
jkelleyrtp merged 14 commits intoDioxusLabs:mainfrom
DogeDark:cli-bindgen-install

Conversation

@DogeDark
Copy link
Contributor

@DogeDark DogeDark commented Dec 11, 2024

This PR adds prebuilt binary (and fallback compile-from-source) installation of the wasm-bindgen CLI. This allows our CLI to build a project of any wasm-bindgen version as long as the installed wasm-bindgen-cli supports the required flags.

  • A temporary folder is used to store installation artifacts.
  • Installed binaries are stored in {data_local_dir}/dioxus/wasm-bindgen
  • Installed binaries are named wasm-bindgen-{version}{.exe}

The installer attempts to install in this order:

  1. Prebuilt release binaries on wasm-bindgen's GitHub
  2. cargo-binstall
  3. cargo-install

This could use testing on other platforms:

  • Windows
  • MacOS
  • Linux

image

@DogeDark DogeDark added enhancement New feature or request cli Related to the dioxus-cli program labels Dec 11, 2024
Copy link
Member

@jkelleyrtp jkelleyrtp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cleaned it a bit + merged main but looks good otherwise!

@jkelleyrtp jkelleyrtp merged commit ccf500c into DioxusLabs:main Dec 11, 2024
@DogeDark DogeDark deleted the cli-bindgen-install branch December 11, 2024 20:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli Related to the dioxus-cli program enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants