GIT HELPER - DAVID RALECHE
SYNC GIT
git remote updategit fetch Downloads the latest from remote without trying to merge or rebase anything.git fetch -- allRename Git Commit
git commit -amend
REMOVE untracked files
git clean -f -dRESET BRANCH/FILE
git reset --hard origin/master -- force discard local changesgit reset --hard origin/ -- force discard local changesgit checkout -f -- force discard local changesCOMMIT
git commit -m ‘My commit David Raleche’remove git add
git reset HEAD -file-PUSH
git push origin CONFLICTED FILES
git diff --name-only --diff-filter=U GIT ADD git add git commit -m “message of your commit” git push originGIT RESET ADD
git reset git reset(VERY DANGEROUS) REMOVING LAST COMMIT (VERY DANGEROUS)
git reset --soft HEAD~1git reset --hard HEAD^
(VERY DANGEROUS)
GIT CHECKOUT SOMEONE ELSE REPO
git checkout --track origin/ECOM-307
Comments