
How to set up GitHub CLI and authenticate your account The two operate the same way, but if you switch between WSL and PowerShell you'll need to have it installed in both locations. curl -fsSL | sudo dd of=/usr/share/keyrings/githubcli-archive-keyring.gpgecho 'deb stable main' | sudo tee /etc/apt//github-cli.list > /dev/nullsudo apt updatesudo apt install ghĪs with Git, the WSL installation of the GitHub CLI is separate from the Windows installation you would use in PowerShell. Since most people using WSL are likely to have Ubuntu or Debian installed as they're officially distributed through the Microsoft Store, you can use the following commands in your WSL terminal to install it. On WSL, the process is a little more involved, but GitHub has full documentation you can follow. Alternatively, it's available through the Scoop and Chocolately package managers, too, where you'll simply need to install gh To install the GitHub CLI on Windows you can use the Windows Package Manager again by entering winget install github.cli For one, it gets around using personal access tokens with Git to push local repositories up to GitHub, as you can use the GitHub CLI application to authenticate your whole system.


The GitHub CLI tool is an official GitHub application, and if you're going to be using GitHub, it's well worth having. Source: Windows Central (Image credit: Source: Windows Central)
