This commit converts all of the places using ColorScheme.Gray and ColorScheme.Grayf to Muted and Mutedf.
There is a little extra tidying up with local variable names or converting code to use Mutedf format.
After discussing this with the team, the `gh config` changes to display `accessible_colors` have been removed from this branch being outside of acceptance criteria. This will be moved to a separate issue along with any other work needed to finalize the public preview such as `gh help` entries for `GH_ACCESSIBLE_COLORS` environment variable.
List commands that use ColorScheme.Gray have been updated to use ColorScheme.Muted.
* Separate partitioning from globbing in cmdutil/args package and consumers
In the previous commit, GlobPaths was overloaded, containing logic
specific to command use-cases. This commit removes that functionality from
GlobPaths and back into the commands that have the special use-cases.
To do this, I've introduced a new Partition util in cmdutil/args.go that
will separate a slice into two slices given a predicate. This functionality
is leveraged by both the special use-cases described above to separate the
command-specific syntax from the globable filepaths.
* Add test to validate that the order of '-' in gh gist create args doesn't matter
Latest Glamour has slightly changed logic in line length / wrapping,
resulting test failures due to string mismatch. Update tests and bump
dependency to v0.8.0, and others to the bare minimal level as generated
by `go mod tidy`.
This was detected then building the GitHub cli package `gh` in Debian
started to fail with src:golang-github-charmbracelet-glamour 0.8.0-1.
Closes: #10179
Refactor the logic for checking `workflow` scope checking in releases to be in the positive - check if the scope is there, not check if it isn't there. Then, when the function is called we invert it.
Also update comments to be more imperative.
This refactor also incorporates @andyfeller's suggestion to use `slices`.
Co-Authored-By: Andy Feller <andyfeller@github.com>
Changing to `release-notes.md` from `changelog.md` may help users better contextually understand usage.
Co-authored-by: Tyler McGoffin <jtmcg@github.com>
Found with
rg '(^ | \t|\t )' -g '*.go' -g '!*_test.go'
Mixed indent exceptions:
- wrapped long list items with extra 2-space indent
- code snippets using space indent
- commented code lines having "\t*// \t+" prefix
The formatting verb is used incorrectly and produces a misleading
help text for this command:
```
To define a display label for an asset, append text starting with %#% after the file name.
```
instead of the expected:
```
To define a display label for an asset, append text starting with `#` after the file name.
```