2018-06-07 20:28:17 -07:00
2018-06-07 19:22:58 -07:00
2018-06-07 19:22:58 -07:00
2018-06-07 19:22:58 -07:00
2018-05-26 08:47:01 -07:00
2018-03-29 21:07:01 -07:00
2018-06-07 20:27:36 -07:00
2018-05-20 19:41:43 -07:00
2018-05-26 15:27:07 -07:00
2018-05-26 14:53:27 -07:00
2018-06-07 19:27:55 -07:00

ghorg

Go Report Card License GoDoc

GitHub search is terrible. The idea with ghorg is to quickly clone all org repos into a single directory and use something like ack to search.

When running ghorg a second time, all local changes in your *_ghorg directory will be overwritten by whats on GitHub. If you are working out of this directory, make sure you rename it before running a second time.

Setup

Homebrew

$ brew tap gabrie30/utils
$ brew install ghorg

Golang

$ go get -u github.com/gabrie30/ghorg
$ cd $HOME/go/src/github.com/gabrie30/ghorg
$ cp .env-sample .env
# update your .env, if needed
# If GHORG_GITHUB_TOKEN is not set in .ghorg, defaults to keychain, see below
$ make install
$ go install

Use

$ ghorg org

ghorg defaults to master however, for gitflows you can run on develop by setting GHORG_BRANCH=develop or similar

Default GitHub Token Used

$ security find-internet-password -s github.com  | grep "acct" | awk -F\" '{ print $4 }'

If running this does not return the correct key you will need to generate a token via GithHub and add it to your $HOME/.ghorg

To view all other default environment variables see .env-sample

Auth through SSO

  • If org is behind SSO a normal token will not work. You will need to add SSO to the Github token

Troubleshooting

  • You may need to increase your ulimits if cloning a large org
  • Other issues can most likely be resolved by adding a .ghorg to your users home directory and setting the necessary values defined in the .env-sample
Description
No description provided
Readme Apache-2.0 12 MiB
Languages
Go 71.1%
Shell 27.2%
Dockerfile 0.7%
Ruby 0.5%
Makefile 0.2%
Other 0.3%