Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the same profile name for both Cargo and wasm-pack #1489

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

srussvoll
Copy link

When running wasm-pack with a custom profile (wasm-pack build . --profile custom_profile_name), the Cargo profile with name custom_profile_name will be used, but wasm-pack will use a profile called custom.

More concisely,
Cargo will use [profile.custom_profile_name], whereas
wasm-pack will use [package.metadata.wasm-pack.profile.custom]

This PR makes wasm-pack use the custom profile name provided with the --profile option so that
wasm-pack will now use [package.metadata.wasm-pack.profile.custom_profile_name].

Closes #1488.

Make sure these boxes are checked! 📦✅

  • You have the latest version of rustfmt installed
$ rustup component add rustfmt
  • You ran cargo fmt on the code base before submitting
  • You reference which issue is being closed in the PR text

✨✨ 😄 Thanks so much for contributing to wasm-pack! 😄 ✨✨

@srussvoll
Copy link
Author

To my knowledge the custom profile is currently undocumented, and the feature has not yet been released. But since some users is likely using the git repository to install wasm-pack, I added a deprecation warning for the custom profile. Is this desirable?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

wasm-pack profile name doesn't match the cargo profile name
1 participant