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

cargo xtask - no such subcommand: xtask #4158

Closed
neilsarkar opened this issue Sep 20, 2023 · 3 comments · Fixed by #4160
Closed

cargo xtask - no such subcommand: xtask #4158

neilsarkar opened this issue Sep 20, 2023 · 3 comments · Fixed by #4160

Comments

@neilsarkar
Copy link
Contributor

neilsarkar commented Sep 20, 2023

Description
On trunk, cargo xtask is not found, but it is referenced in multiple places including https://github.com/gfx-rs/wgpu/wiki/Running-on-the-Web-with-WebGPU-and-WebGL

Repro steps

git clone https://github.com/gfx-rs/wgpu.git
cd wgpu
cargo xtask run-wasm --bin cube

Expected vs observed behavior

Expected to build and see the cube example running in browser. Instead got this:

$ cargo xtask run-wasm --bin cube
error: no such subcommand: `xtask`

	Did you mean `apk`?

	View all installed commands with `cargo --list`

Extra materials

It appears that the .cargo/config.toml that supports xtask was removed here: #4107

For beginners, the missing .cargo/config.toml can be hard to debug, especially since the project doesn't use the workspace setup suggested by https://github.com/matklad/cargo-xtask

Was this intentional? If so I can raise a separate issue about updating the documentation to reflect the removal of the xtask alias.

Platform

rustc 1.65.0 (897e37553 2022-11-02)
Mac OS Ventura 13.5.2
@cwfitzgerald
Copy link
Member

That absolutely doesn't seem intentional. cc @OptimisticPeach

We'd absolutely accept a PR to re-add it.

@neilsarkar neilsarkar mentioned this issue Sep 20, 2023
3 tasks
@neilsarkar
Copy link
Contributor Author

thanks! submitted a pr reversing that deletion ^

@OptimisticPeach
Copy link
Contributor

Oops, yup, I 100% didn't intend on deleting that -- I was using .cargo/config.toml to temporarily let CLion know that I'm compiling with WASM as the target, so removing that was part of my cleanup however apparently I forgot to notice that there were extra things in that file, other than the config I was adding 😅.

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 a pull request may close this issue.

3 participants