Skip to content

Instantly share code, notes, and snippets.

@ederchrono
Last active October 19, 2021 14:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ederchrono/7a304f3d1a12c3207c9384129dbac044 to your computer and use it in GitHub Desktop.
Save ederchrono/7a304f3d1a12c3207c9384129dbac044 to your computer and use it in GitHub Desktop.
Github CLI config

Eder's Github CLI setup and preferences

  1. Install the Github CLI
  2. Optionally install gitopen to go to your repo's remote, this works even on non Github repos
  3. Optionally run the following line to set an alias for new PRs: gh alias set newpr 'pr create', I like this more than the default

Usage

If you want to go to the web of your repo run:

gitopen

You committed and pushed your changes and are ready to create a PR? Run

gh newpr
# if you didn't set the alias: "gh pr create"

After a while if you want to check if your PR was reviewed:

gh pr status

There are way more Github CLI commands you can use but this is for me the bread and butter of everyday, so it saves a lot of time in the long run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment