Document and enforce that just recipe arguments are positional - #442
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
just --listprints each recipe as a signature (build profile="debug"), which reads like call syntax. Typingjust build profile=releasetherefore passes the literal stringprofile=releaseas the positional argument.Verified behavior against just 1.45.0 with a scratch justfile:
just say releaseword=[release]just say word=releaseword=[word=release](positional, not an override)just word=release sayerror: Variable \word` overridden on the command line but not present in justfile`just greeting=yo saygreeting=[yo](real override, before the recipe name)just say greeting=yoword=[greeting=yo](even a real variable name is consumed positionally)Documentation
defaultrecipe output, immediately above the recipe list where the signatures appear.docs/development/dev-tools.md, next to its existingjust build releaseexample.Diagnostic fixes
python-ci-coreandpython-ci-smokedelegated profile validation to their build dependency, so a bad profile recommended the dependency's name (just python-ci-build-test release) instead of the recipe the user invoked. Both now validate directly.benchchecked each slot only against its own parameter name, sojust bench release pattern=fooboundpattern=footofeaturesand reached cargo as--features pattern=foo. Each slot now rejects every parameter name.All cases exercised:
Not changed:
just julia-build rustflags="-C ..."putsrustflags=...in the profile slot, which already fails loud withUnknown profile: rustflags=-C .... No silently-wrong behavior there.