Sep 19, 2024
git init
, git add
, git commit
, git push
, git pull
, git branch
, etc.git version
command.git init
to create a local repository.git add <filename>
.git commit -m "message"
to save changes with a message.git branch <branch-name>
or git checkout -b <branch-name>
.git checkout <branch-name>
or git switch <branch-name>
.git merge <branch-name>
.git branch
to list branches.git log --graph
to visualize commits in a branching structure.git push origin <branch-name>
to push local changes to the remote repository.git pull origin <branch-name>
to fetch and merge changes from the remote.git tag -a <tag-name> -m "message"
to create an annotated tag.git push origin <tag-name>
.