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

38 Коммитов

Автор SHA1 Сообщение Дата
Mislav Marohnić f8feb335bc Don't choke on literal `%` output from `--format` use
In general, avoid using Printf without a static format string.
2018-12-20 18:01:20 +01:00
Mislav Marohnić d5761b714b Add `--format=<FORMAT>` functionality to `issue show`, `release show` 2018-10-30 23:19:53 +01:00
Mislav Marohnić 5285804c41 Code style 2018-10-30 23:19:53 +01:00
royels 6b5997f974 Add the command `hub issue view <NUMBER>`
This commit adds the subcommand hub issue view, which displays an issue as well as
lists its comments underneath.
2018-10-30 23:19:53 +01:00
Mislav Marohnić b15d8de5e4 Ensure consistent sort direction when listing issues, PRs
The default direction when sorting by `created` date (the default) is
descending. However, the default on the API backend changes to ascending
when the sort key is something different than `created`:
https://developer.github.com/v3/pulls/#list-pull-requests

This ensures that the default `direction: "desc"` is always passed to
API queries, regardless of the sort key, unless `--sort-ascending` was used.

Ref. https://github.com/github/hub/issues/1815#issuecomment-433222344
2018-10-26 14:37:47 +02:00
Mislav Marohnić 5e2d072a9a Handle case of `.github/ISSUE_TEMPLATE` directory
Ignore the directory of multiple issue templates for now. In the future,
there might be a way to pick a specific template from the list; this
change is just to prevent crashes.

Fixes #1822
2018-08-23 15:38:34 +02:00
Darren Wee d7906101aa Fix oopsie in test case.
Forgot to change expected result after changing labels functionality.
2018-01-31 00:40:32 +08:00
Darren Wee 15d3ac848e Fix oopsie (added extra newline by accident) 2018-01-30 19:45:04 +08:00
Darren Wee 8edd49eaaf Fix expected test case (pre-colorization) 2018-01-30 19:39:15 +08:00
Darren Wee 672dcc9b05 Merge label.feature into issue.feature. 2018-01-30 18:33:25 +08:00
Mislav Marohnić a2fb6670bb Smarter `per_page` HTTP query when limiting results
If the result limit is N, the default `per_page` will be `N + N/2`
instead of the default 100. This aims to achieve faster API requests for
relatively low values of N.
2018-01-29 23:41:23 +01:00
Mislav Marohnić 31ab5e5147 Fix limiting number of results from `release`, `issue`
- Stops HTTP pagination once the limit has been reached
- Cleans up client implementation by passing around a filter block
2018-01-29 23:30:41 +01:00
Mislav Marohnić 420d2121ed Merge remote-tracking branch 'origin/master' into limit-flags 2018-01-29 22:54:30 +01:00
Mislav Marohnić 0ef312ec03 Support use of `-m '' --edit` combination 2018-01-23 17:35:42 +01:00
Michael Kaiser d2de3094a0 Add limit flag for issue and release commands 2017-10-14 23:50:39 +02:00
Sean Allred 037e068933 Add tests for --include-pulls 2017-02-15 07:38:27 -06: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ć b972284fba Merge pull request #1245 from pcorpet/sort-issues
Add sorting options to `hub issue`.
2016-09-14 01:40:34 +02:00
Pascal Corpet 245e767614 Rename scenario, simplify checks for output and check that sort and directions params are not sent to GitHub by default. 2016-09-13 23:41:49 +02:00
Mislav Marohnić 3ab56f59b5 Fix assigning labels/assignees without the other
The GitHub API doesn't seem to like receiving `"assignees": null`.

Fixes #1240
2016-09-08 23:27:32 +02:00
Pascal Corpet 0b7a95dccd Add sorting options to `hub issue`. 2016-08-27 22:09:50 +02:00
Mislav Marohnić ca10058884 Cleanup in cukes 2016-08-21 13:23:26 +02:00
Pascal Corpet 99a0d87819 label => labels, time => date, simpler tests 2016-08-19 21:04:40 +02:00
Pascal Corpet f03978c3e8 Display only issues updated at or after a certain time. 2016-08-19 16:49:01 +02:00
Pascal Corpet 5ddce90357 Display only issues with certain labels. 2016-08-19 16:49:01 +02:00
Pascal Corpet 5bec748452 Display only issues mentioning a user. 2016-08-19 16:49:01 +02:00
Pascal Corpet 948b19f6a3 Display only issues created by <CREATOR>. 2016-08-19 16:49:01 +02:00
Pascal Corpet a6611a1758 Filter issues list by assigned milestones. 2016-08-19 16:49:01 +02:00
Mislav Marohnić 83bdc60dfa Fix listing assignees in `hub issue` 2016-08-19 15:32:58 +02:00
Mislav Marohnić 28f872978a Have `issue` command fetch all pages of API results 2016-08-16 17:29:41 +02:00
Mislav Marohnić 15b86379bc Refactor some `--format` placeholders
Renamed some existing placeholders and added new ones such as milestone
number/title, raw labels, comma-separated assignees, and number of comments.
2016-08-16 17:29:40 +02:00
Mislav Marohnić ac9ff97891 Add `issue create --browse` support to reflect `pull-request` 2016-08-15 15:34:03 +02:00
Mislav Marohnić 4c02e6a817 Add assignees & milestone support to `issue create` 2016-08-15 14:08:44 +02:00
Pascal Corpet 9531c266f4 Fix integration test and add one more 2016-05-12 15:58:51 +02:00
Mislav Marohnić 8563e678d2 Reimplement `hub issues` commands using simpleApi
- `hub issue` now displays color based on issue open/closed state
- `hub issue` no longer displays HTML URL since it was noisy
- `hub issue` no longer lists pull requests
- `hub issue create` tweaks for compatibility with `hub release create`
2016-02-03 23:05:06 +11:00
Dennis Cornwell 556a9452d3 Collapse unnecessary step into feature definition 2016-02-01 12:25:10 -05:00
Dennis Cornwell fd145adbaf Make assignee comparisson case insensitive 2016-02-01 12:18:48 -05:00
Dennis Cornwell ffaa3ecb37 Filter issues by assignee
* Use -a or --assignee to filter repo issues list by assignee
* Makes it easier to find pull requests and issues you've been
  assigned to address
2016-01-31 21:12:56 -05:00