Skip to content

Latest commit

History

History
55 lines (34 loc) 路 1.15 KB

File metadata and controls

55 lines (34 loc) 路 1.15 KB

opengit, saving you a few seconds

It will open your github project page from your terminal

Install

Instructions for Linux, OS X users should make the necessary substitutions, if any, I know nothing about OS X.

Create ~/bin

mkdir -p "$HOME/bin"

Add the directory to the beginning of the PATH variable inside .bashrc

echo 'PATH="$HOME/bin:$PATH"' >> "$HOME/.bashrc"

This way, every new instance of Bash will now check for executable scripts in your bin directory.

Now you save the file opengit inside the ~/bin directory and make the file executable with:

chmod +x opengit

If for some reason you don't want/can't grant the permissions, you can run it like this:

bash opengit

Usage

You can do this to open Github on the current branch

$ opengit

or specify the branch

$ opengit remote_branch

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-awesome-feature)
  3. Commit your changes (git commit -am 'Making it better')
  4. Push to the branch (git push origin my-awesome-feature)
  5. Create new Pull Request
  6. Wait for me 馃槃

Power to you my friend!