This repository has been archived by the owner on Nov 22, 2022. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 163
feat(command/issue): allow issue URL as argument #546
Merged
Merged
Conversation
This file contains 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
Allow issue argument to be a URL
profclems
added
cmd: issue
Related to issues management
enhancement
New feature or request
labels
Jan 9, 2021
5 tasks
I will fix the tests early in the morning... Gotta have some rest |
allows using multiple `-l` and splitting by `,`
profclems
force-pushed
the
feat-issue-url-arg
branch
from
January 10, 2021 01:21
b50e75d
to
c177751
Compare
Codecov Report
@@ Coverage Diff @@
## trunk #546 +/- ##
==========================================
- Coverage 60.88% 60.41% -0.47%
==========================================
Files 86 86
Lines 5913 5965 +52
==========================================
+ Hits 3600 3604 +4
- Misses 1979 2015 +36
- Partials 334 346 +12
Continue to review full report at Codecov.
|
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
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.
Description
This PR enables issue URL to be passed as argument.
The user can now specify an issue by either the ID or URL.
Supports:
HOST/OWNER/REPO/issues/ID
HOST/GROUP/NAMESPACE/issues/ID
HOST/OWNER/REPO/-/issues/ID
HOST/GROUP/NAMESPACE/-/issues/ID
eg:
glab issue close https://gitlab.com/profclems/glab/issues/277
glab issue close 277
glab issue close https://gitlab.com/profclems/glab/-/issues/277
glab issue close https://salsa.debian.org/GROUP/NAMESPACE/REPO/issues/123
Also adds support for IDs prefixed with '#'
glab issue reopen "#277"
Related Issue
None
How Has This Been Tested?
Manually tested on gitlab.com/profclems/glab, private group repo and a few repos on salsa.debian.org
TODO: add unit tests
Screenshots (if appropriate):
Types of changes