Git Workflow
I’ll flesh this out later, but:
- ADD NEW FILES (if you made new ones):
git add .
to add everything, orgit add FILENAME
to add files one by one. - SAVE CHANGES TO GIT:
git commit -m "Message here"
to make a commit, a.k.a. save things into your repository - SEND TO GITHUB:
git push
to send everything to GitHub - you’ll usegit push -u origin master
the first time - CHECK FOR ERRORS: Did it not work? Did you get a message about
git pull
? That means there is new data on the repository that isn’t on your computer. Runninggit pull
by itself will sometimes send you into a weird text editor, hit ESCAPE then type:wq
and hit enter. I know, it’s dumb. You could also rungit pull --rebase
to avoid that. Then try tocommit
andpush
again.