Git Clone & Push From Command Line

Git Clone & Push From Command Line

Why use a heavy electron app for nothing?

I’ve used Github Desktop before using the command line. Today I’ve tried using git from terminal and seems I’ve got this.

Here are the usual command one should care about mostly:

  • Let’s clone a repository first!
git clone https://github.com/user/repo
  • Change directory to project folder
cd repo
  • Make changes to files as usual.
  • Add all the files to local git.
git add .
  • Add your name and email.
git config user.email "[email protected]"
git config user.name "username"
  • Add a commit message.
git commit -m "message"
  • Push to Github.
git push

This article was so useful. Cover image is from Wired.