Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to Create a Git repository using github-cli? [duplicate]

How do you create a GitHub repository using GitHub CLI (vs having to go to github.com and creating a github repo from their GUI)?

like image 647
Zack Plauché Avatar asked May 16 '26 09:05

Zack Plauché


1 Answers

GitHub just released their CLI (command line interface), so now you can create GitHub repos from command line / terminal.

Step 1:

Download the client for your system here

Step 2:

Once it's installed, run gh auth login in your command prompt and follow the instructions to log in.

Step 3:

After you're logged in, in your command prompt go to a directory where you want to create the repository, run git init in the project directory to initialize it.

Then run the command gh repo create and follow the instructions.

like image 154
Zack Plauché Avatar answered May 18 '26 19:05

Zack Plauché



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!