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

failed to find an installation of rustup in PATH, even with rustup is already installed #1015

Open
insinfo opened this issue Jun 17, 2021 · 3 comments

Comments

@insinfo
Copy link

insinfo commented Jun 17, 2021

🐛 Bug description

I set the environment variables, I installed "rustup" on my machine, then when I try to install "wasm-pack" this error appears

image
image

🤔 Expected Behavior

that install normally

🌍 Your environment

Windows 10 64bits
rustup --version
rustup 1.24.3 (ce5817a94 2021-05-31)
info: This is the version for the rustup toolchain manager, not the rustc compiler.
info: The currently active rustc version is rustc 1.52.1 (9bc8c42bb 2021-05-09)

RUSTUP_HOME => C:\rust\rustup
CARGO_HOME => C:\rust\cargo

cargo --version
cargo 1.52.0 (69767412a 2021-04-21)

@insinfo insinfo changed the title failed to find an installation of rustup in PATH, rustup is already installed failed to find an installation of rustup in PATH, even with rustup is already installed Jun 17, 2021
@insinfo
Copy link
Author

insinfo commented Jun 17, 2021

I managed to install on my Windows machine with this command

cargo install wasm-pack

When I ran the command "wasm-pack new test" I got an error:

wasm-pack new teste
[INFO]: Installing cargo-generate...
error: the `--vers` provided, `latest`, is not a valid semver version: cannot parse 'latest' as a semver

Error: Installing cargo-generate with cargo
Caused by: failed to execute `cargo install`: exited with exit code: 101
  full command: "cargo" "install" "--force" "cargo-generate" "--version" "latest" "--root" "C:\\Users\\isaque\\AppData\\Local\\.wasm-pack\\.cargo-generate-cargo-install-latest"

then searching can solve this, with this command

cargo install cargo-generate

@StefansArya
Copy link

If you already add C:\rust\rustup into system PATH and able to run rustup --version via CLI, you can also run the installer from the same CLI with "D:\path\to\wasm-pack-init.exe".

sLEuZP8ZJT

@LivingWithHippos
Copy link

Using the executable gave me this error even if rustup was in path as which rustup showed the executable. I ran ./wasm-pack-init.exe from the terminal instead of clicking on it and it worked

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

3 participants