Skip to content

Instantly share code, notes, and snippets.

@alexpaul
Last active June 5, 2019 20:19
Show Gist options
  • Save alexpaul/5f4f4ceeb5afe3399ee0c396bf7fff3e to your computer and use it in GitHub Desktop.
Save alexpaul/5f4f4ceeb5afe3399ee0c396bf7fff3e to your computer and use it in GitHub Desktop.
Git commands

Git Commands

Command Summary
git init initializes (creates) a git repository in the current directory
ls -a list hidden files
git status show status of your local repository
git add README.md add the untrack file to be committed
git commit -m "initial commit" commit and include a message about your commit
git remote add origin <repo url> configure the remote repository
git push --set-upstream origin master (done on initial setup) push your changes to the remote repository
git push pushing changes after initial configuration
git pull to pull remote changes if available
clone clone a repository into a newly created directory
fork a copy of a repository. Forking a repository allows you to freely experiment with changes without affecting the original project

Resouces

Resource Summary
Github Cheat Sheet Github Cheat Sheet
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment