GitHub CLI, a tool for bringing full repo functionality to your terminal, has reached its first stable version after a very successful beta.
“Developers spend a lot of time in their terminals, and our CLI helps to mitigate the frequent context switching between your terminal and GitHub.com,” says Amanda Pinsker, Product Designer at GitHub.
“Command-line tools enable developers to script nearly any action and automate their workflows, which in turn allows developers to work faster and more productively.”
The initial beta of CLI was announced in February. GitHub says that users have created nearly 200,000 pull requests, performed over 350,000 merges, and created over 20,000 issues using the beta.
After such an impressive beta run, GitHub has decided today to release v1.0 of CLI.
Using GitHub CLI for your workflow
Start by cloning the repo you want to work with using `gh repo clone owner/repo`
Use `gh issue status` or `gh issue list –assignee billygriffin` to find the next thing you want to work on.
When you’re done with adding that feature or squashing that bug, you can use `gh pr create` to create your pull request on GitHub.
A teammate can review your pull request using `gh pr checkout 1337`, compare the differences with `gh pr diff`, and even provide a lightweight review using `gh pr review`.
Once the pull request is approved, you can ensure all your tests are passing with `gh pr checks`. If everything checks out, you can merge it right from your terminal with `gh pr merge`. GitHub CLI helps streamline the process further by offering to delete your branch locally and on GitHub.com post-merge.
When you’re ready to cut your next release, just use `gh release create [tag name]` and your creation will be published.
Practice what you preach
GitHub CLI itself is, naturally, open-source. The company says it’s had more than 100 community contributors who’ve helped to achieve CLI’s first stable release.
Some of the community contributions:
- Adding metadata to issue and pull request views (via @doi-t!)
- Allowing selection of blank templates (via @AliabbasMerchant!)
- Filtering issues by milestone, mentioned, and author (via @eddumelendez!)
- Aligning repo create to other create commands (via @ShubhankarKG!)
Based on feedback throughout GitHub CLI’s beta, the following features were added:
- create and view repositories
- configure GitHub CLI to use SSH and your preferred editor
- close, reopen, and add labels, assignees, and more to issues and pull requests, and
- view the diff, review, and merge pull requests
GitHub isn’t resting on its laurels with this release and has more features planned for the future.
GitHub CLI 1.0 can be downloaded for Windows, macOS, and Linux here.
Interested in hearing industry leaders discuss subjects like this? Attend the co-located 5G Expo, IoT Tech Expo, Blockchain Expo, AI & Big Data Expo, and Cyber Security & Cloud Expo World Series with upcoming events in Silicon Valley, London, and Amsterdam.