Luke
1102de89be
add quotes around @me in documentation to ensure examples work on powershell
2021-08-30 09:13:43 -05:00
Heath Stewart
e2973453b5
Add helper template functions for rendering tables ( #3519 )
...
Co-authored-by: Mislav Marohnić <mislav@github.com>
2021-08-23 21:00:25 +02:00
Heath Stewart
88af63d36f
Re-enable label colors for issue list ( #4106 )
...
* Re-enable label colors for issue list
* Drop parentheses wrapping issue labels
* Support ANSI escape codes in TablePrinter cells
* Switch to a Truncate implementation that correctly measures ANSI escape codes
* Only output RGB color if terminal has truecolor capabilities
* Enable `ENABLE_VIRTUAL_TERMINAL_PROCESSING` on Windows - fixes wrapping issues with full lines and allows truecolor rendering
Co-authored-by: Mislav Marohnić <mislav@github.com>
2021-08-23 19:55:12 +02:00
Mislav Marohnić
930ee60ac5
Disable colorizing labels in issue list output
...
- Labels with dark color are not visible on a dark background
- "Raw" `issue view` output should never output color, not even with
CLICOLOR_FORCE=1
2021-08-03 16:02:16 +02:00
Mislav Marohnić
db8204dc56
Allow space to be added after completing issue/pr list --state values
...
The "nospace" directive instructs the shell completion logic to avoid
adding a space after completing the word. However, this feature was
broken in an older Cobra, and users still saw a space character added.
In most case we want the space because we anticipate that the user might
want to add extra arguments to the command.
2021-07-21 16:12:38 +02:00
bchadwic
47314a6bbc
modified HexToRGB to check whether terminal and gh have color enabled, as well as created tests for HexToRGB
2021-07-03 17:09:25 -07:00
bchadwic
af2499cb69
renamed func RGB to HexToRGB
2021-06-29 22:35:23 -07:00
bchadwic
4c412bc88c
Added in label rgb functionality for both prs and issues
2021-06-29 22:26:41 -07:00
Sam Coe
1302b71fa7
linter
2021-06-22 11:41:22 -07:00
Sam Coe
e0468dbb29
whitespace
2021-06-22 11:39:47 -07:00
autopp
0179651dc3
Add shell completion for the --state flag
2021-06-20 20:03:21 +09:00
Mislav Marohnić
606deaf134
Allow setting empty body via editor in issue/pr create
2021-06-04 21:50:51 +02:00
jack1142
184149b844
Add missing new line
2021-06-01 23:53:58 +02:00
jack1142
42333bb2d1
Update issue non-tty view formatting and its tests
2021-05-29 04:44:48 +02:00
jack1142
979ec9298d
Update issue tty view formatting and its tests
2021-05-29 04:44:48 +02:00
Gowtham Munukutla
e160dd3eae
fix listing of PRs when merged ones are searched ( #3730 )
...
Co-authored-by: Mislav Marohnić <mislav@github.com>
2021-05-28 10:11:12 +00:00
Mislav Marohnić
4425365004
Add release view --json support
2021-05-18 19:40:28 +02:00
Mislav Marohnić
42155c7d2d
Export more IDs in issue/pr JSON payload
2021-05-18 18:19:28 +02:00
Mislav Marohnić
e758f30073
Fix preloading of pr reviews, checks, and issue/pr comments
2021-05-18 17:13:27 +02:00
Mislav Marohnić
5f0301c990
Have Exporter.Write automatically call ExportData on given data structure
2021-05-12 17:05:15 +02:00
Cristian Dominguez
2f94adabb2
Use T.TempDir for temporary dirs in tests ( #3580 )
2021-05-07 12:21:26 +02:00
Cristian Dominguez
6b49e21295
Improve issue status detection
2021-04-28 00:30:21 -03:00
Mislav Marohnić
a2ff97d73f
Fix issue create --web
2021-04-20 13:50:44 +02:00
Mislav Marohnić
516ea8691e
Fix whitespace formatting of issue/pr view help text
2021-04-14 20:04:47 +02:00
Mislav Marohnić
3ad41e3e65
Change JSON Exporter to an interface
2021-04-14 18:15:52 +02:00
Mislav Marohnić
a516ee6833
Add issue status --json support
2021-04-13 21:26:26 +02:00
Mislav Marohnić
abe452bb19
Add --json export flag for issues and pull requests
...
The `--json` flag accepts a list of GraphQL fields to query for and
output in JSON format. To get the list of available flags, run the
command with a blank value for `--json`. Additional `--jq` and
`--template` flags are available just like in `gh api`.
2021-04-13 20:29:31 +02:00
Mislav Marohnić
19ea49b5a9
Move issue list queries to under the issue/list package
2021-04-13 19:25:19 +02:00
Mislav Marohnić
79219c7741
Merge pull request #3271 from cristiand391/disable-preview-long-url
...
Disable preview option in prompts if URL size is too long
2021-03-30 19:34:28 +02:00
Mislav Marohnić
57536e7b0d
💅 cleanup URL length checking
2021-03-30 19:12:31 +02:00
Cristian Dominguez
fb39c38c85
Disable preview option in prompts if URL size is too long
2021-03-30 19:12:31 +02:00
Mislav Marohnić
43dac8fc09
💅 cleanup issue transfer
2021-03-30 18:42:34 +02:00
Gowtham Munukutla
5db62046fd
Add issue transfer command
2021-03-30 18:42:34 +02:00
Mislav Marohnić
d22e72a373
Fix tests broken by incompatible merges
2021-03-30 18:39:37 +02:00
Mislav Marohnić
44ae7ae3cf
Merge pull request #3279 from cli/browser-refactor
...
Pass web browser to each individual command
2021-03-30 16:54:59 +02:00
Mislav Marohnić
63a47d0334
Merge pull request #3295 from cli/labels-and-combinator
...
BREAKING: lookup all issue/PR labels with "AND" instead of "OR"
2021-03-30 16:52:14 +02:00
Mislav Marohnić
2fa8a85813
Unify checking whether search filters were passed by the user
2021-03-24 18:11:21 +01:00
Mislav Marohnić
949df38d49
BREAKING: lookup all issue/PR labels with "AND" instead of "OR" combinator
...
This switches to the Search API whenever labels are specified in `issue
list` or `pr list`. This ensures that the results match those that would
be returned in the web UI.
2021-03-24 18:04:25 +01:00
Mislav Marohnić
01bbb15b57
Add pr list --search
2021-03-24 16:46:45 +01:00
Gowtham Munukutla
70d4873914
add generic search naming for issues and PRs @samcoe
2021-03-23 18:10:46 +01:00
Mislav Marohnić
80035aa686
💅 cleanup switching to search mode in issue list
2021-03-23 18:08:14 +01:00
Gowtham Munukutla
f791bbdbcb
add search feature in listing issues
2021-03-23 18:08:14 +01:00
Mislav Marohnić
e53d02b680
Add back isolated tests for issue/PR lookup by argument
2021-03-22 12:55:04 +01:00
Mislav Marohnić
111e8dbcf2
Pass web browser to each individual command
...
This removes sensitivity to the BROWSER environment variable in tests
and makes it easier to verify the URL that the browser was invoked with
without having to stub sub-processes.
2021-03-19 21:22:37 +01:00
Nate Smith
2ab073d599
Refactor use of glamour to allow style overrides ( #3243 )
...
* Refactor use of glamour to allow style overrides
* leave the things the way they were and just expose the ability to set overrides
2021-03-19 16:29:32 +00:00
Mislav Marohnić
d5fb817dfc
Remove unnecessary BodyFile field
2021-03-15 15:12:41 +01:00
Cristian Dominguez
8bfe64d593
Accept --body-file flag if --body is supported
2021-03-15 15:12:41 +01:00
Mislav Marohnić
e96d974331
Merge pull request #3023 from cli/cancel-error-status
...
Issue/pr create: exit with nonzero status code when "Cancel" was chosen
2021-03-04 13:45:11 +01:00
Mislav Marohnić
2ebdde1ddd
Exit with status code "2" on user cancellation errors
...
This also stops printing "interrupt" after Ctrl-C is pressed.
2021-03-02 13:48:44 +01:00
Mislav Marohnić
3efa764305
Avoid the issue/pr recovery mechanism handling Ctrl-C keypress in prompts
...
Either InterruptErr or SilentErr will be present when the user has
chosen "Cancel" or pressed Ctrl-C in prompts. We don't want the recovery
mechanism to kick in these cases because the cancellation was likely
willingly initiated by the user.
2021-02-23 20:09:03 +01:00