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
Mislav Marohnić
8e89c0479e
Merge pull request #95 from github/rename-file
...
Rename PR query file
2019-11-20 10:17:00 +01:00
Amanda Pinsker
4340b643f6
Merge pull request #94 from github/help-copy-edits
...
Help copy edits
2019-11-19 15:16:18 -08:00
Corey Johnson
89db5cbee6
Move to queries_pr
2019-11-19 14:59:17 -08:00
Corey Johnson
1051ea420d
Merge pull request #90 from github/lables-on-issue-status
...
Add labels to `gh issue status`
2019-11-19 14:58:15 -08:00
Corey Johnson
c1ad55ba64
use const
2019-11-19 14:57:52 -08:00
Mislav Marohnić
7c731bc512
Avoid crash when parsing in-progress CheckRuns
...
Fixes `panic: unsupported status: ""`
This occurs when a CheckRun has status "IN_PROGRESS" (or any other than
"COMPLETED") and when its `conclusion` would be null. I previously
didn't account for this.
This adds support for parsing state of an in-progress CheckRun.
2019-11-19 09:42:59 +01:00
Amanda Pinsker
5e7557e8fa
Copy edits
2019-11-18 23:26:18 -08:00
Corey Johnson
20b47871a0
Add labels to the issues status
2019-11-18 14:56:15 -08:00
Corey Johnson
7bb2c38467
Merge pull request #65 from github/issue-update
...
Make `gh issue list` match the design spec
2019-11-18 11:17:15 -08:00
Corey Johnson
9aea93e5b2
Merge remote-tracking branch 'origin/master' into issue-update
2019-11-18 11:13:26 -08:00
Corey Johnson
e5af5be940
Merge remote-tracking branch 'origin/master' into issue-update
2019-11-18 11:09:00 -08:00
Corey Johnson
75a3496bf1
Test flags
2019-11-18 11:05:43 -08:00
Mislav Marohnić
b640a3027a
Merge pull request #80 from github/status-check-rollup
...
Strengthen PR Reviews+Checks GraphQL via `pe_mobile` feature flag
2019-11-18 20:00:25 +01:00
Corey Johnson
e8020077ae
Remove debut statement
2019-11-18 10:34:25 -08:00
Nate Smith
dc4820a27f
Merge pull request #87 from github/issue-status-open
...
Include open issues only in `issue status`
2019-11-18 12:13:27 -06:00
Corey Johnson
223651629a
Merge pull request #57 from github/add-release-notes
...
Add release instructions to readme
2019-11-18 10:12:05 -08:00
Nate Smith
06e491a190
Merge pull request #64 from github/pr-checkout
...
Add `pr checkout` command
2019-11-18 12:10:19 -06:00
Mislav Marohnić
e7fed2e39c
Include open issues only in issue status
2019-11-18 17:12:43 +01:00
Corey Johnson
a9ce81b139
bye bye
2019-11-15 13:26:27 -08:00
Corey Johnson
927b172135
Only add space to status issues
2019-11-15 13:23:05 -08:00
Corey Johnson
e4903fc7c0
Less pointless words
2019-11-15 13:20:13 -08:00
Corey Johnson
3e062589c5
Update README.md
2019-11-15 13:16:19 -08:00
Mislav Marohnić
be55f81e16
Add "review required" notice to PRs if applicable
2019-11-15 12:05:05 +01:00
Mislav Marohnić
6e894a0eab
Use reviewDecision internal GraphQL to simplify review state
...
Before, we've used the `reviews` connection to iterate through all
reviews chronologically and try to guess the final state of reviews.
This approach had several problems:
- it didn't handle dismissed reviews well,
- the conclusion would likely be wrong if the number of total reviews
exceeded the per-page limit.
The `pe_mobile` feature flag exposes the `reviewDecision` field that
handles all of this for us.
2019-11-15 12:00:13 +01:00
Mislav Marohnić
04f20ddb2b
Use statusCheckRollup internal GraphQL to simplify Statuses+Checks
...
With the old approach, we had to enumerate all StatusContexts and
CheckRuns to calculate whether a PR has passing or failing CI status.
Using `statusCheckRollup` which is behind the `pe_mobile` feature flag,
this is somewhat simpler because both StatusContexts and CheckRuns are
now behind the same connection.
Additionally, should we decide to *not* show the number of
passing/failing checks, this now approach allows us to consume the
`statusCheckRollup { state }` field and avoid paginated collections
and calculating the "winning" state altogether.
2019-11-15 11:43:00 +01:00
Mislav Marohnić
760fac906d
Merge remote-tracking branch 'origin/master' into pr-checkout
2019-11-15 09:31:11 +01:00
Mislav Marohnić
624c44efda
Merge pull request #63 from github/branch-from-fork
...
Use `OWNER:BRANCH` syntax for cross-repo PRs
2019-11-15 09:28:00 +01:00
Corey Johnson
761d29cf5e
Fix test
2019-11-14 12:40:48 -08:00
Mislav Marohnić
d8308b4c15
Allow pr checkout while not on any branch
2019-11-14 20:54:44 +01:00
Mislav Marohnić
4fab43a667
Cover more pr checkout test scenarios
2019-11-14 20:53:34 +01:00
Corey Johnson
f0e6ec2b5e
Nope
2019-11-14 11:46:31 -08:00
Corey Johnson
b4b0c37feb
show labels
2019-11-14 11:30:53 -08:00
Mislav Marohnić
1fc9c8f9d6
Test the scenario where the target branch already exists
2019-11-14 20:29:24 +01:00
Mislav Marohnić
2616da04c4
Only capture stderr of commands that don't have configured Stderr
2019-11-14 20:02:42 +01:00
Mislav Marohnić
dc0de147c9
Add pr checkout command
2019-11-14 19:59:42 +01:00
Mislav Marohnić
1479ff457a
Merge pull request #38 from github/pr-create
...
Add `pr create` command
Closes #59
2019-11-14 19:33:30 +01:00
Mislav Marohnić
135efda6d3
Avoid re-wrapping of "could not determine suitable remote" error
2019-11-14 19:31:33 +01:00
Billy Griffin
55ab2f6b6e
Merge pull request #62 from github/consistency-is-key
...
Swap "open in browser" to "view in browser" for view cmd
2019-11-14 08:59:14 -07:00
Mislav Marohnić
0c2d8879d1
Use OWNER:BRANCH syntax for cross-repo PRs
...
This affects `pr status` and `pr list`.
2019-11-14 16:46:59 +01:00
Corey Johnson
c7d275c520
Includ body in debug output
2019-11-13 13:57:48 -08:00
Corey Johnson
57afc2e69f
Add assignee
2019-11-13 13:55:24 -08:00
vilmibm
237fd04ad0
use errors.Wrap
2019-11-13 15:00:57 -06:00
Billy Griffin
e262e7283c
Swap "open in browser" to "view in browser" for view cmd
2019-11-13 13:59:32 -07:00
Mislav Marohnić
933086bae9
Merge remote-tracking branch 'origin/master' into pr-create
2019-11-13 19:31:02 +01:00
Mislav Marohnić
bb87f4a2fb
Add pr create test for git clean state
2019-11-13 19:25:02 +01:00
Mislav Marohnić
e3e8647760
Eliminate package-level flags
2019-11-13 19:24:58 +01:00
Nate Smith
f7074c17e6
Merge pull request #55 from github/pr-status-checks
...
Add checks, reviews info to `pr status`
2019-11-13 12:08:46 -06:00
Corey Johnson
44c7495bab
Add state
2019-11-12 14:31:24 -08:00