get hub code example
Example 1: github
in case of emergancy:
1) git commit
2) git push
3) run away ...
Example 2: github
git checkout master
git checkout master
git pull origin master
Adding New Features
git checkout -b my_branch_name
git add .
git commit -am "Initial commit"
git branch
git push -u origin new_branch_name
Example 3: new repository github used
$ git init
$ git add .
$ git commit -m "First commit"
$ git remote add origin remote repository URL
$ git remote -v
$ git push origin main
Example 4: github
//cancel commits
git reset HEAD^
//cancel last 3 commits
git reset HEAD~3
//when first commit
git push -u origin master
//remove remote origin
git remote remove origin
//reset remote origin
git remote add origin https://github.com/yourname/project.git
git init
//add all
git add .
//cancel adds
git reset
Example 5: github
echo "# practice" >> README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin https://github.com/shlee87/practice.git
git push -u origin master
Example 6: github
adding git remote origin