Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cyppan/docker-octohub
Dockerised Octohub CLI
https://github.com/cyppan/docker-octohub
Last synced: about 1 month ago
JSON representation
Dockerised Octohub CLI
- Host: GitHub
- URL: https://github.com/cyppan/docker-octohub
- Owner: cyppan
- Created: 2015-05-01T15:06:50.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-05-01T15:19:39.000Z (over 9 years ago)
- Last Synced: 2024-10-13T10:29:18.217Z (2 months ago)
- Size: 109 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# OctoHub: Low level Python and CLI interface to GitHub
This image is basically a wrapper around the octohub CLI command.
Look at the repository description at: https://github.com/turnkeylinux/octohubYou can override the following environment variables when running the container:
* OCTOHUB_LOGLEVEL (default to ERROR)
* OCTOHUB_TOKEN (when you want to interact with non-public infos)## Example uses:
**Print Octohub help**
`docker run -ti --rm octohub````
Syntax: octohub method uri [arg=val...]
OctoHub: GitHub API CLIArguments:
method Request HTTP method (e.g., GET, POST, DELETE, ...)
uri Request URI (e.g., /user/issues)
key=val Request params key=value pairs (e.g., filter=assigned)Options:
--input Path to json encoded file for data (- for stdin)
--max-pages Maximum pagination calls (only GET method supported)
For all pages, specify 0Environment:
OCTOHUB_TOKEN GitHub personal access token
OCTOHUB_LOGLEVEL Log level debugging sent to stderrExample usage:
octohub GET /users/:user
octohub GET /user/issues filter=assigned labels=bug
octohub GET /repos/:owner/:repo/issues
octohub GET /repos/:owner/:repo/issues sort=updated --max-pages=3
octohub POST /repos/:owner/:repo/issues --input=issue.json
octohub POST /user/repos --input=repo.json
cat repo.json | octohub POST /orgs/:org/repos --input=-http://developer.github.com/v3/
```**Get the master HEADS commit from the public turnkeylinux/octohub repository**
`docker run -ti --rm octohub GET /repos/turnkeylinux/octohub/git/refs/heads/master`
```
{
"url": "https://api.github.com/repos/turnkeylinux/octohub/git/refs/heads/master",
"object": {
"url": "https://api.github.com/repos/turnkeylinux/octohub/git/commits/49f4e1a1e399cdecc458beed2f1169875a7269f2",
"sha": "49f4e1a1e399cdecc458beed2f1169875a7269f2",
"type": "commit"
},
"ref": "refs/heads/master"
}
```