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

Multiple test_args when checking for installed crate #252

Closed
roblabla opened this issue Jun 18, 2019 · 2 comments
Closed

Multiple test_args when checking for installed crate #252

roblabla opened this issue Jun 18, 2019 · 2 comments
Assignees
Milestone

Comments

@roblabla
Copy link
Contributor

roblabla commented Jun 18, 2019

Features Description
To test if cargo-travis is installed, the user is supposed to run cargo doc-upload --help. This doesn't work with cargo-make however, because it is impossible to pass multiple arguments (test_arg is passed as a single argument).

Simply using cargo-doc-upload --help wouldn't work because it exits with an error, leading to cargo-make thinking it should update it.

Describe the solution you'd like
Add a new key to install_crate, test_args, an array of arguments to pass to the binary. Example:
install_crate = { crate_name = "cargo-travis", binary = "cargo", test_args = ["doc-upload", "--help" }

Code Sample

[tasks.deploy-doc]
workspace = false
install_crate = { crate_name = "cargo-travis", binary = "cargo", test_arg = "doc-upload --help" }
install_crate_args = ["--git", "https://github.com/roblabla/cargo-travis", "--rev", "doc-upload-target"]
description = "Upload this project's documentation on github pages. Should only run on CI."
command = "cargo"
args = ["doc-upload", "--clobber-index"]

This will always cause cargo-make to reinstall cargo-travis.

@sagiegurari
Copy link
Owner

thanks, will check it out

@sagiegurari
Copy link
Owner

your PR is now officially released. thanks a lot!!!

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

No branches or pull requests

2 participants