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

Allow disabling background check for updates #1413

Open
orhun opened this issue Jul 25, 2024 · 0 comments
Open

Allow disabling background check for updates #1413

orhun opened this issue Jul 25, 2024 · 0 comments

Comments

@orhun
Copy link

orhun commented Jul 25, 2024

💡 Feature description

Hey, I'm maintaining the wasm-pack package for Arch Linux and I would like to have a way of disabling the background check for updates. This has the following advantages for distro packages:

  • Ensures all users have the same version (avoiding compatibility issues and maintaining uniformity)
  • Less resource usage (no API call to crates.io)

💻 Basic example

We can simply add a feature flag as follows:

[features]
default = ["check-for-updates"]

Then we can annotate the related functions with #[cfg(feature = "check-for-updates")]. The users who would like to disable this will have to build wasm-pack with --no-default-features flag.

I'm happy to raise a PR if you think this is applicable. 🐻

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

No branches or pull requests

1 participant