Граф коммитов

393 Коммитов

Автор SHA1 Сообщение Дата
Mislav Marohnić 35ca65b907 Merge pull request #1425 from pocket7878/add-plan9port-rc-support
Add plan9port rc shell support
2017-06-28 11:41:12 +02:00
Mislav Marohnić 9a0c525b42 Merge pull request #1327 from wesbland/delete_release
Add ability to delete releases
2017-06-26 23:44:43 +02:00
Mislav Marohnić c6425bfc38 Fix `git --(exec|html|man|info)-path`
When any of these global flags are passed, don't try to decorate the
output as if `git help` was invoked.

Fixes https://github.com/github/hub/issues/1446
2017-06-26 20:22:11 +02:00
Mislav Marohnić 01c3099abe Fix crash in `WorkdirName` when within bare git repo
`git rev-parse --show-toplevel` returns an empty string with success
status when inside a bare git repo.

This avoids the go crash and also tweaks `hub issue` and `hub
pull-request` to work even if current working directory name couldn't be
obtained because it's only used for looking up issue/PR templates, which
isn't critical functionality.

Fixes https://github.com/github/hub/issues/1331
2017-06-26 20:22:11 +02:00
Josh Betz c5bf224992 Fix test data for newly sorted help text 2017-06-23 11:52:51 -05:00
Mislav Marohnić e3ad4ef7e5 Fix requesting pull request reviewers
The expected HTTP status code is 201

Fixes #1463
2017-05-18 13:19:02 +02:00
Mislav Marohnić 6a48391668 Merge pull request #1475 from eljobe/feature/go1.8
Upgrade to Go 1.8
2017-05-17 13:37:46 +02:00
Mislav Marohnić b13006826a Merge pull request #1472 from eljobe/fix/bash-completion-test
Fix bash completion test on MacOS X
2017-05-11 10:26:16 +02:00
Pepper Lebeck-Jobe 71fa8dad8f
Upgrade to Go 1.8
The only thing that has substansively changed is that Go 1.8 handles
redirect logic more safely than previous versions. This means we can
drop our special handling to avoid following redirects to other
domains. We were only doing that to protect against the possibility
of leaking auth headers. With Go 1.8, the auth headers are not
forwarded when following a redirect to another domain, so we don't
need our special handling any more.

As long as people are attempting to build with the Makefile, the new
check_go_version script should cause the build to stop if our
collaborators aren't using at least version 1.8 of go.
2017-05-11 13:24:04 +09:00
Pepper Lebeck-Jobe 3b04080f94
Remove unneeded assignment
The useless assignment was causing the cucumber test suite to fail
even when the completion scenarios were skipped.
2017-05-09 21:08:26 +09:00
Pepper Lebeck-Jobe 078583db0c
Fix bash completion test on MacOS X
However my git installation was run, it installed the
git-completion.{bash,zsh} scripts under
"${GIT_PREFIX}/contrib/completion/" instead of any of the paths that
this test case was expecting.

To make matters worse, the only way to know that this was the problem
was that each scenaro failed with a message about timing out while
waiting for completion to happen in tmux. Just in case there are
other paths out there where the git-distributed completion scripts
may live, I've also added some detection logic to raise an exception
during the "Given" clause of the scenario if we cannot find the
git-distributed bash completion scripts in any of the places we're
looking for them. This would have made it a lot easier to diagonse
the failures.
2017-05-09 20:50:27 +09:00
Pepper Lebeck-Jobe 2591ca4588
Allow the unsorted expansion for the fish shell
Before this change, the `pu` would sometimes expand to `pull
pull-request push` if the order isn't important, we should take this
fix.

However, if the order is important, we should probably switch the
expectation such that the options are presented alphabetically as
observed.
2017-05-09 20:10:57 +09:00
Mislav Marohnić 9a929485e8 Merge remote-tracking branch 'origin/master' into tomasv-request-reviewers-2 2017-04-24 17:57:37 +02:00
Mislav Marohnić d38f71b5eb Fixes to `Accept` header expectations in tests 2017-04-24 17:53:52 +02:00
Mislav Marohnić 39bd77179d Opt into "black-cat-preview" for all API requests
This allows us to access extra functionality around PR reviews.
2017-04-24 17:45:05 +02:00
Mislav Marohnić 76631ce551 Merge pull request #1403 from walles/walles/hub-review
Add a "hub pr checkout" command
2017-04-18 12:03:31 +02:00
Tomas Varneckas 0fad51944f
Add support for review requests in pull-request command 2017-04-17 18:34:54 +03:00
Mislav Marohnić 629d13908f Merge branch 'no-prerelease' 2017-04-10 23:09:52 +02:00
Mislav Marohnić acc85a0aa9 Make it `release --exclude-prereleases` (plural)
This is for consistency with `--include-drafts` (also plural).
2017-04-10 23:09:11 +02:00
Mislav Marohnić 6be9d54fc2 Reuse most logic betwen `checkout` and `pr` commands 2017-04-08 22:17:18 +02:00
Mislav Marohnić 19a5167d1a Simplify remote lookup in `fork` 2017-04-08 20:57:37 +02:00
Johan Walles cb9888d58d Don't expect any -f or -q options
We don't support them, and we don't expect them to show up.
2017-04-08 10:43:48 +02:00
Johan Walles 1aa529397f Remove unhelpful test
With "hub checkout" you had to write the complete URL to the PR, which
made it possible to type the wrong owner/repo there. This check covers
that case.

Nowadays, when you only enter the PR number you can't mess up that way
any more, and this test lacks meaning.
2017-04-08 10:43:48 +02:00
Johan Walles f9e49847c6 Pass the first cucumber test! 2017-04-08 10:43:48 +02:00
Johan Walles 625bee326f Add missing PR URL in Github responses 2017-04-08 10:43:48 +02:00
Johan Walles 915db7a06b Add missing PR URL 2017-04-08 10:43:48 +02:00
Johan Walles bcfce1b580 Cucumber: Add to Background that we're already authenticated 2017-04-08 10:43:48 +02:00
Johan Walles dcccc204f9 Add missing Background for "pr" feature
We need to be in a git repo for the tests to work.
2017-04-08 10:43:48 +02:00
Johan Walles 7f5c0fa627 Remove more instances of -f and -q 2017-04-08 10:43:48 +02:00
Johan Walles a8ac70757d Don't expect "hub pr checkout" to support -f or -q 2017-04-08 10:43:48 +02:00
Johan Walles 55a6794a68 Add tests for hub pr checkout
Next step is to actually run these tests...
2017-04-08 10:43:48 +02:00
Marc Abramowitz 031bf45142 Address comments from @mislav 2017-03-23 09:33:31 -07:00
Marc Abramowitz 33f2eb64d8 Update No origin git remote found error msg 2017-03-08 22:27:41 -08:00
Marc Abramowitz 0b6cf8a456 Add scenario for fork with --remote-name
Scenario: Fork the repository with new remote name specified
2017-03-08 22:15:42 -08:00
Marc Abramowitz 8a4d8dd0eb fork: Add --remote-name option
Allows the user to choose the remote name for their fork instead of
always using their GitHub username. This is useful for workflows where
folks name the remote for their private fork origin `origin` and
the upstream repo remote is named `upstream`. We happen to use this
workflow at work, because it makes the remote names more predictable and
easy to manage (you always push your new commits to `origin` rather than
a remote name that is dependent on your username).

```
$ git remote -v
upstream	git@github.com:github/hub (fetch)
upstream	git@github.com:github/hub (push)

$ ./bin/hub fork --remote-name=origin
Updating origin
From ssh://github.com/github/hub
 * [new branch]      1.11-stable     -> origin/1.11-stable
 * [new branch]      1.12-stable     -> origin/1.12-stable
 * [new branch]      2.2-stable      -> origin/2.2-stable
 * [new branch]      code-coverage   -> origin/code-coverage
 * [new branch]      gh-pages        -> origin/gh-pages
 * [new branch]      master          -> origin/master
 * [new branch]      travis-packages -> origin/travis-packages
new remote: origin

$ git remote -v
origin	git@github.com:msabramo/hub.git (fetch)
origin	git@github.com:msabramo/hub.git (push)
upstream	git@github.com:github/hub (fetch)
upstream	git@github.com:github/hub (push)
```

I haven't written tests yet, but I can if this is a feature that the
maintainers are amenable to merging...
2017-03-04 10:05:55 -08:00
Pocket7878 efa376225f Add rc alias support 2017-03-02 10:16:24 +09:00
Mislav Marohnić 34081973ea Merge pull request #1413 from vermiculus/show-pulls-again
Add option to show pull requests again
2017-02-15 17:11:02 +01:00
Juan Ignacio Donoso cdd7a65e05 Add a `--org` flag to `hub fork` 2017-02-15 10:20:03 -05:00
Sean Allred 037e068933 Add tests for --include-pulls 2017-02-15 07:38:27 -06:00
Mislav Marohnić 3d3facba2c Merge branch 'master' of https://github.com/github/hub 2017-02-06 15:29:57 +01:00
Mislav Marohnić 13b87db65a Add automated tests for fish completion 2017-02-06 15:20:17 +01:00
Mislav Marohnić 7c892ca99f Merge pull request #1396 from nex3/checkout-set-remote
Set merge configuration on checkout.

Fixes #1376, fixes #821
2017-02-05 12:18:39 +01:00
Natalie Weizenbaum f93e53798f Code review changes. 2017-02-03 15:54:44 -08:00
Natalie Weizenbaum 93df826636 Set merge configuration on checkout.
When checking out a pull request that doesn't match an existing remote,
this sets the branch's remote and merge configuration fields. If the
pull request is modifiable by the maintainer, it uses the SSH URL to
that you can push to the pull request.
2017-02-02 23:53:44 -08:00
Michihito Shigemura 6089677173 Preserve description 2017-01-26 00:49:09 +09:00
Michihito Shigemura 22edf59710 Fix fish alias and testing
cannot find hub completion when using git alias
2017-01-24 22:45:50 +09:00
Tomas Edwardsson e1fe86ffbc Add clipboard copy (-c) to browse command
The -c parameter will put the url into the clipboard instead of
opening in the browser.
2017-01-06 13:34:16 +00:00
Natalie Weizenbaum fb40cab7fd Add --set-upstream to git push commands.
This ensures that a branch pushed using "hub pull-request" has its
upstream branch set to the target of the push.
2016-12-07 13:47:46 -08:00
Mislav Marohnić 1a3a934714 Fix issue/PR template lookup when in a subdirectory
Always start template lookup from the toplevel directory of the repo.

Fixes #1242
2016-11-21 13:00:57 +01:00
Mislav Marohnić 3021e584ee Merge branch 'akshatgoel-issue1305'
Closes #1332, fixes #1305
2016-11-07 14:39:00 +01:00