Quote the gh api PUT URL in the ruleset caveat example - #130
Merged
Conversation
The placeholder URL had unquoted <owner>/<repo>/<id>, which a shell would parse as redirections; quote it to match the other gh api examples in this section.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes a shell-correctness issue in the documentation by quoting the gh api -X PUT URL in the ruleset caveat example, preventing shells from misinterpreting <owner>, <repo>, and <id> as redirection tokens.
Changes:
- Quote the
repos/<owner>/<repo>/rulesets/<id>argument in thegh api -X PUTexample to make the command shell-safe. - Align the PUT example style with the other quoted
gh api "repos/<owner>/<repo>/..."examples in the same section.
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.
Shell-correctness nit from Copilot on the promotion PR: the inline
gh api -X PUT repos/<owner>/<repo>/rulesets/<id>example had an unquoted URL, so a shell would interpret<owner>/<repo>/<id>as redirections. Quoted it to match the othergh api "repos/<owner>/<repo>/..."examples in the same section.