- version control system tools
- Download Git Tools
- install defualt
- check git version
git --version
- git config --global user.name "githubUserName"
git config --global user.name
- git config --global user.email "[email protected]"
git config --global user.email
git config --list
git --version
- copy url < https:// > from github and paste after git clone
git clone
- modifies Files and Folders
git status
- cd to go directory and show all the files
- untracked or new file
- modified (somthing changed)
- staged (ready to commit)
- unmodified (no changed)
git add .
- check git status
git commit -m "first commit"
git push
- Go to check on github directory and files
- create file and directory
- CD go to directory
- create .git file
git init
- check files
ls -a
- git romote -v (to verify remote)
git remote -v
- git branch (to check branch)
git branch
- git branch -M main (to rename branch)
git branch -M main
- git push origin main or git push -u origin main
git push -u origin main
- untracked or new file
- modified (somthing changed)
- staged (ready to commit)
- unmodified (no changed)
git add .
- check git status
git commit -m "first commit"
git push
- Go to check on github directory and files
- git branch
- git branch -M main (to rename branch)
- git checkout < branch name> (to navigate)
- git checkout -b < new branch name> (to create new branch)
- git checkout -d < branch name >
- git branch -d < branch > (to delete branch )
- git checkout main or other branch < branch name > (to use changing branch)
- git diff < branck name> ( to compare commits, branches,files & more)
- git merge < branch name >
- create a Pull Requirest
- git pull origin main ( used to fetch and download content from a remote repo and immediately update the local repo to match that content.)
- An event that takes place when Git is is unable to automatically resolve differences in code between two commits.
- git diff main
- git merge main
- git status
- git reser < file name > (reset file for last changes )
- git reset ( all reset changes in multiple files )
- git reset HEAD-1 ( back to the last commit or like undo )
- check log
git log
- git reset < commit hash> ( you can undo with the hash code )
- git reset --hard < commit hash> ( you can undo inside the git and vscode )
- find the project and create fork
- create copy of master or main branch
- now you can work on this file and repo
- changes marge on main project
- pull Requirest marge project main to my main branch ( this is use for bugs resolved )