Commit graph

72 commits

Author SHA1 Message Date
Andy Feller
b77de0d458 Additional formatting changes
- gh help actions
  - highlight 3 commands to run for more information
- gh extension
  - wrapping url for online linking
  - fix install subcommand missing backtick formatting
- gh release create
  - fixing mixed indenting causing usage misalignment
- root help
  - backtick wrap help command for more info for consistency
- gh help environment
  - backtick wrap missed OWNER/REPO
- gh variable
  - brought consistency to output when deleting or setting variable
2023-12-01 09:08:51 -05:00
Yukai Chou
afbdb945bc Small docs tweaks 2023-11-23 07:14:38 +08:00
Arun Sathiya
5eff7a529a
fix(release create): Handle latest flag value when updating the release after assets are uploaded (#8207)
Signed-off-by: Arun <arun@arun.blog>
Co-authored-by: William Martin <williammartin@github.com>
2023-11-01 15:17:05 +01:00
Sam Coe
94fbbdf9b5
Cleanup release create around new --notes-from-tag flag (#8016) 2023-09-19 08:26:52 +00:00
Keith Bailey
be41a9bd20
moved remoteTagExists under if NotesFromTag exists and added three tests 2023-09-11 14:17:49 -04:00
Keith Bailey
5ccfbe9d7e
Add gh release create [<tag>] --notes-from-tag
Generates release notes from an annotated git tag noninteractively.
Fixes #6718
2023-08-17 23:17:29 -04:00
Harvey Sanders
f777bec798
release create: Trim spaces on interactive tag name input (#7759) 2023-07-27 09:18:51 -07:00
Benjamin Chadwick
82662685e3
Autocomplete branch flags (#6031)
Co-authored-by: Mislav Marohnić <mislav@github.com>
2023-03-29 16:09:44 +00:00
Nate Smith
aae4023cdc use t.Cleanup(m.Verify) 2023-03-09 16:43:48 -08:00
vilmibm
b5c3d982b1 new tooling for assertions about prompting 2023-03-09 16:40:27 -08:00
Mislav Marohnić
8cb312a620
Fix release assets upload retry logic
Enables up to 3 retries of uploading a single asset when encountering a network error or a HTTP 5xx error.

Bonus:
- simplifies ConcurrentUpload implementation
- support Go context cancellation
2022-12-14 21:25:09 +01:00
Mislav Marohnić
cbeed671dd
release create: clean up leftover draft release on upload/publish failure 2022-12-14 21:24:39 +01:00
vilmibm
6507d35f2f port release command to prompter 2022-12-09 15:06:26 -08:00
Luan Vieira
fad72b788d
Avoid duplicate remote tag lookups
Co-authored-by: Mislav Marohnić <hi@mislav.net>
2022-11-16 15:12:18 -05:00
Luan Vieira
f1a067ff18
Clarify --verify-tag flag description
Co-authored-by: Mislav Marohnić <hi@mislav.net>
2022-11-16 15:09:21 -05:00
Luan Vieira
11bef8c3b5
Add --verify-tag flag for release creation command
Fixes https://github.com/cli/cli/issues/6566

When running `gh release create <tag> --verify-tag`, we query <tag>
among repository tags via the GitHub API before creating the release,
and abort the command if the tag was not found.
2022-11-16 13:45:55 -05:00
Mislav Marohnić
6c8aaff919
Merge pull request #6538 from cli/release-make-latest
Support explicitly marking a Release as "Latest"
2022-11-03 11:31:10 +01:00
Mislav Marohnić
e8dc825c7c
Avoid duplicate release when creating a release with assets (#6493)
When publishing a release, we rely on server-side validation to abort the operation if an existing published release with the same tag name already exists.

However, then creating a release with assets, we first create a draft release, upload assets to it, then publish. If there was an existing release with the same tag name, the operation would fail but it would leave behind a temporary draft release with assets. This makes the operation fail earlier, before creating any records.
2022-11-01 19:03:03 +00:00
Mislav Marohnić
c63e3a094d
release create: support explicitly marking as "Latest" 2022-10-31 16:30:51 +01:00
Sam Coe
4294ee14a1
revert revert 57fbe4f317 (#6474) 2022-10-20 12:17:20 +00:00
Sam Coe
2cefb9fa59
Fix pr create regression (#6472)
* Revert "Refactor to use new git client (#6447)"

This reverts commit 57fbe4f317.

* Fix pr create regression
2022-10-20 12:46:23 +03:00
Sam Coe
57fbe4f317
Refactor to use new git client (#6447) 2022-10-19 21:11:36 +03:00
Sam Coe
2944f7c3ab
Create git client (#6354) 2022-10-14 07:47:03 +00:00
Sam Coe
e7102f9d84
Migrate to go-gh text package (#6236) 2022-09-14 09:23:55 +04:00
Bindu
9fddb07eab
Add --notes-start-tag flag for generating release notes in gh release create (#6107) 2022-09-06 16:06:18 +04:00
Sam Coe
45f1a71c8b
Remove all direct calls to shurcool-graphql 2022-08-18 21:40:41 +03:00
vilmibm
41385477c3 fix linting 2022-07-27 14:15:27 -05:00
vilmibm
d5334f4115 Revert "update linter checks"
This reverts commit 40ecb8c188.
2022-07-27 13:30:41 -05:00
vilmibm
40ecb8c188 update linter checks 2022-07-26 16:06:52 -05:00
casswedson
00bc550dc6 chore: typo hunting ft. codespell 2022-07-09 21:41:09 -05:00
Håvard Anda Estensen
58cb773e09
Replace ioutil with io and os (#5498) 2022-04-26 13:07:44 +02:00
Johannes Plunien
186e5ccfb2
Add release edit command (#5422)
Co-authored-by: Mislav Marohnić <mislav@github.com>
2022-04-13 14:51:49 +00:00
Christopher Nethercott
933a91e18e
Add "new" alias to "create" commands (#5388)
Co-authored-by: Mislav Marohnić <mislav@github.com>
2022-04-11 16:48:34 +02:00
Mislav Marohnić
5d36bcc4de Merge remote-tracking branch 'origin' into fix/release-discussion-category 2022-02-15 18:28:08 +01:00
Mislav Marohnić
72340076ae tests 2022-02-15 18:27:58 +01:00
Sam Coe
28d2b52769
release create: warn about unpushed local git tag (#5104)
If `gh release create <TAG>` was called and TAG exists locally but not on the remote, this warns about the unpushed tag to avoid recreating it on the remote. The user can pass a value for `--target` to silence the warning.
2022-02-15 16:36:37 +01:00
Mislav Marohnić
df21025133 Add tests for release create from commit log, annotated tag 2022-01-17 14:23:05 +01:00
Mislav Marohnić
7090922713 💅 release create tests 2022-01-17 14:05:01 +01:00
Mislav Marohnić
e54b29e9cf Merge remote-tracking branch 'origin' into bugfix/release/create/no-tag-when-generated-available 2022-01-17 13:27:47 +01:00
Mislav Marohnić
44775f87c8 Add nolint directives to allow-list current lint violations 2022-01-14 19:52:52 +01:00
Mislav Marohnić
ff072574f9 Port release create tests to the new ask stubber 2022-01-12 23:57:19 +01:00
keijun-kumagai
6bc0b69355 feat(http): supress linter 2022-01-13 00:33:07 +09:00
Spenser Black
e8dfa9e728
Fix tag message option hidden
This fixes the option in `gh release create` to generate release notes
from the tag message being hidden whenever generated notes are
available. This changes the behavior from hiding "generate from tag" and
"generate from commit log" being hidden to *only* the "generate from
commit log" option being hidden.

Fixes #5027
2022-01-12 09:36:29 -05:00
keijun-kumagai
015b9f7fea fix(release): discussion category with assets 2022-01-11 01:49:19 +09:00
Sergio Guzmán Mayorga
43ae0e5f87
Add interactive tag selector to create release (#4525) 2021-12-08 16:20:15 +04:00
Tomohiro Nishimura
a9d397be69
Add --generate-notes flag to gh release create command. (#4467) 2021-12-08 15:20:59 +04:00
Sam Coe
2135918c47
Turn survey options into variables so they can't accidentally become unsynced with default value 2021-10-19 08:55:30 -07:00
Tomohiro Nishimura
c7f79e8447
Set default publish action to draft if --draft option is set 2021-10-19 22:37:46 +09:00
Reto Hablützel
f6e9734f17 add more hints to docs 2021-09-25 08:38:26 +02:00
Mislav Marohnić
11fbb60ae7 Rename the module to "github.com/cli/cli/v2" 2021-08-25 12:41:30 +02:00