Commit graph

36 commits

Author SHA1 Message Date
Toshiya Doi
4c4aeb5ec6 Return the latest PR belonging to the current branch 2020-03-13 09:49:20 +09:00
Alisson Santos
7a0a6658d5 avoid nested ifs 2020-03-05 18:52:27 +01:00
Alisson Santos
101d985a16 remove duplicate from pages 2020-03-05 18:10:00 +01:00
Alisson Santos
dcedacd4f7 Remove duplicates 2020-03-05 13:55:36 +01:00
Nate Smith
fdf940eeba
Merge pull request #530 from doi-t/issue-467
Ability to differentiate pull requests by their state
2020-03-02 16:12:55 -06:00
Mislav Marohnić
55b66feb42
Merge pull request #542 from Dasio/slice-initialization
Slice initialization
2020-02-26 20:02:06 +01:00
Toshiya Doi
5f152a349d Print merged and closed PRs of the current branch along with an opening PR 2020-02-27 00:07:48 +09:00
Toshiya Doi
8b31b283f5 Merge branch 'master' into issue-467 2020-02-26 15:37:32 +09:00
rista404
2a42f61d8d Use gray color for PR number if PR is a draft 2020-02-25 18:47:44 +01:00
Dasio
9289ab99f2 Use var syntax when empty struct is initialized 2020-02-24 22:33:22 +01:00
Dasio
327dae95a3 Use break label instead of goto 2020-02-24 21:18:34 +01:00
Toshiya Doi
9c44eaeb6e Define an order clause to sort PRs newest first 2020-02-25 01:27:19 +09:00
Toshiya Doi
b7893b1fd3 Query pullRequests of the current branch regardless of its state 2020-02-22 16:54:30 +09:00
Mislav Marohnić
a710893fc1 Rename to cli/cli 2020-01-24 16:08:52 +01:00
Mislav Marohnić
1f90579d2a Extract common interface for a GitHub Repository
Also define a handful of utility methods:
- `New(owner, repo)`
- `FullName`: the name slash owner pair
- `FromFullName`: parse the name slash owner pair
- `FromURL`: parse a GitHub.com URL
- `IsSame(r1, r2)`: compare two repositories
2020-01-22 22:44:46 +01:00
Mislav Marohnić
6c49614db7 Fix tests 2020-01-21 22:56:15 +01:00
Mislav Marohnić
7a614ce697 Support triangular git workflows in pr create
- The local git remotes are scanned and resolved to GitHub repositories
- The "base" repo is the first result resolved to its parent repo (if a fork)
- The name of the default branch is read from the base repo
- The "head" repo is the first repo that has push access
2020-01-21 18:26:08 +01:00
vilmibm
4925c3cf01 preview PRs and issues in the terminal with -p 2020-01-10 11:41:26 -06:00
Corey Johnson
4fcf13dac4 Make it work with PRs 2020-01-08 11:44:27 -08:00
Nate Smith
ade69a403c Merge pull request #178 from github/issues-disabled
Warn about repo issues disabled on `issue status/list/create`
2019-12-19 15:39:07 -06:00
Mislav Marohnić
9ddd50ffa9 Add tests for pr status reviews and checks output 2019-12-19 17:37:57 +01:00
Mislav Marohnić
66534e504b Warn about repo issues disabled on issue create 2019-12-19 15:44:20 +01:00
Corey Johnson
2979c5fc4c Use embeding 2019-12-12 11:27:22 -08:00
Corey Johnson
92642f4d53 Create NotFoundError 2019-12-11 10:58:59 -08:00
Corey Johnson
9b40efcad5 Add better gh pr view message 2019-12-10 16:03:10 -08:00
Corey Johnson
ee7f6339ae Return url for PRs 2019-12-05 09:54:30 -08:00
Mislav Marohnić
29de133ccf Accept PR URL or branch argument in pr checkout <pr> 2019-12-03 21:19:09 +01:00
Mislav Marohnić
f87680e804 Explain multiple code paths 2019-12-03 19:52:45 +01:00
Mislav Marohnić
6aa1efcf9f Support --base and --label in combination with pr list --assignee 2019-12-03 16:00:11 +01:00
Mislav Marohnić
51d570e141 Merge remote-tracking branch 'origin/master' into pr-list-assignee 2019-12-03 11:41:50 +01:00
Mislav Marohnić
3e06cfff0d Improve mapping current branch to a PR in pr status 2019-12-02 20:40:14 +01:00
Mislav Marohnić
aeb060e012 Allow pr list filtering of assignee + state 2019-11-27 18:25:01 +01:00
Mislav Marohnić
1bf28927f0 Support -a, --assignee in pr list
This is for symmetry with `issue list`.

The problem is that the `Repository.pullRequests` connection doesn't
support filtering by assignee, therefore we need to switch to search API
in case an assignee was specified. This is awkward, but I don't see
another way.
2019-11-27 18:15:07 +01:00
Mislav Marohnić
508f6787f0 Have PullRequestForBranch accept "owner:branch" value for forks
When on a `patch-1` branch locally, `gh pr view` would happily open the
first open PR it finds with "patch-1" as its head, even those coming
from forks.
2019-11-20 15:20:36 +01:00
Mislav Marohnić
c7a38b6331 Merge branch 'checks-crash' 2019-11-20 11:26:16 +01:00
Corey Johnson
89db5cbee6 Move to queries_pr 2019-11-19 14:59:17 -08:00
Renamed from api/queries.go (Browse further)