Master GitHub CLI 1.0: Install, Commands, and Workflow Tips
GitHub CLI 1.0, now officially released, lets developers manage repositories, pull requests, and issues directly from the terminal with simple commands, offers cross‑platform installation options, and supports custom aliases and enterprise connections for faster, scriptable workflows.
Release
After more than six months of development, GitHub CLI (gh) reached its 1.0 stable release, making the full‑featured command‑line client generally available.
Key Features
Execute complete GitHub workflows from the terminal, including issue management, pull‑request handling, and package publishing.
Script any GitHub API action and assign custom aliases to commands, similar to shell alias.
Connect to both GitHub.com and self‑hosted GitHub Enterprise instances.
Installation
Debian/Ubuntu : Install the official package repository and install the gh binary.
# Add the GitHub CLI apt repository
curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | sudo dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg
sudo apt-add-repository https://cli.github.com/packages
sudo apt update
sudo apt install ghmacOS : Use Homebrew or download the binary.
# Homebrew
brew install ghWindows : Install via winget or download the MSI installer.
# winget
winget install --id GitHub.cliBasic Usage
All commands start with the gh prefix followed by a noun such as repo, pr, issue, etc. gh repo clone <owner/repo> – clone a repository. gh repo create – create a new repository (interactive prompts). gh repo fork <owner/repo> – fork a repository. gh pr create – open a new pull request. gh pr checkout <number|url> – check out a pull request locally. gh pr diff <number|url> – view the diff of a pull request. gh pr review <number|url> --approve – approve a pull request.
Custom Aliases
Aliases are defined in the ~/.config/gh/aliases.yml file and work like shell aliases. Example:
# ~/.config/gh/aliases.yml
bugs: "issue list --label bug"After adding the alias, gh bugs lists all issues labeled bug, streamlining maintenance tasks.
For advanced scenarios, consult the official manual.
Open‑source repository: https://github.com/cli/cli
Official documentation: https://cli.github.com/manual/
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
ITPUB
Official ITPUB account sharing technical insights, community news, and exciting events.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
