Git Product home page Git Product logo

github-issue-cli's Introduction

Note: there is other scripts in this repo you may or may not be interested with, only GitHub Issue CLI is generic enough to use Note: sorry for the horrible code but this came out from a couple of curl commands to shell script to python code and never got to clean this up, but works at least

Github Issue CLI

Simple CLI to create issues on the Command Line,

Created it because I could not find any that was doign the job the way I wanted,

Installation

  • Install Python3
  • Install PyGithub pip3 install pygithub
  • Copy script somewhere in your path.
  • Set your oauth.token in the github in your gitconfig to your personal token, this should be setup by default by hub with easy.

Usage

Basic usage :

% github-issue-cli org/repo

This is will open your editor (whatever you specified in $EDITOR or vim if not) where the first line would be the title and the third line will be the body of the issue.

If you are in vim or emacs the buffer/file will be setup with the markdown mode. Note that the first line is the title and it start from the third line. Every lines that starts with a # and a space will be ignored

You can add labels in there separated by comma like so :

Labels: bug, urgent, critical

which will add all of those to the newly created issue if it exists.

Same goes for assignee if you fill this up with github username and they have access to this repo then it will be assigned to them.

Assignee: user1, user2

The special variable me will be expander to your username.

There is various command line switch to override those, where some of the options like label and assignee can be specified multiple time on the command line, i.e:

% github-issue-cli -a user1 -a user2 -l label1 -l label2 org/repo

This will show when editing in the template tags,

One niceties is with the -b option which allows you to set the body, you can feed a file name into it when prefixing the @ character, for example :

% github-issue-cli -b@/tmp/commit_message org/repo

will insert /tmp/commit_message as the body of your commit message.

Tokens are get from the gitconfig section github variable oauth-token, for example like this :

[github]
	user = me
	oauth-token = token

you can override this with the --token option or with the GITHUB_TOKEN environment variable.

See --help for more options.

SEE ALSO

hub issue -- https://hub.github.com/hub-issue.1.html

AUTHORS

Chmouel Boudjnah -- [email protected]

LICENSE

Apache License 2.0

github-issue-cli's People

Contributors

chmouel avatar

Stargazers

Daniel Helfand avatar Tristan de Cacqueray avatar andrea denisse avatar Vincent Demeester avatar Chiaki Yokoo avatar Rupali Behera avatar  avatar Sunil Thaha avatar Kishan Sagathiya avatar

Watchers

James Cloos avatar  avatar

Forkers

sthaha

github-issue-cli's Issues

"Debian package from ppa is not reporting properly the released version

chmouel@thebond ๐Ÿฑ ~% dpkg -l tektoncd-cli|tee
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version      Architecture Description
+++-==============-============-============-====================================================
ii  tektoncd-cli   0.13.1-0     amd64        A command line interface for interacting with Tekton
chmouel@thebond ๐Ÿฑ ~% tkn version
Client version: 2020-10-21T10:47:53Z

/kind bug

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.