DEV Community 👩‍💻👨‍💻

Beatrice
Beatrice

Posted on

Create a new repo from your command line

Assumptions

  • You have the Github CLI installed
  • You've set up your Github username, password, SSH keys etc on your machine

Command

curl -u USERNAME:PASSWORD https://api.github.com/user/repos -d '{"name":"REPO NAME"}'
Enter fullscreen mode Exit fullscreen mode

That's it! You can create a new repository in your command line this way. Then, perform git remote add origin git@github.com:USERNAME/REPONAME.git like you always do, and push your work. :)

Top comments (0)

Hey 😍

Want to help the DEV Community feel more like a community?

Head over to the Welcome Thread and greet some new community members!

It only takes a minute of your time, and goes a long way!