GIT Commands

?I will talk about the Top Git Commands that you will be using frequently while you are?working with Git.

Here are the some basic GIT commands which are being covered:

? git config : This command sets the author name and email address respectively to be used with your commits.

? git init: This command is used to start a new repository.

? git clone: This command is used to obtain a repository from an existing URL.

? git add: This command adds a file to the staging area.

? git commit: This command records or snapshots the file permanently in the version history.

? git diff: This command shows the file differences which are not yet staged.

? git reset: This command unstages the file, but it preserves the file contents.

? git status: This command lists all the files that have to be committed.

? git rm: This command deletes the file from your working directory and stages the deletion.

? git log: This command is used to list the version history for the current branch.

? git show: This command shows the metadata and content changes of the specified commit.

? git tag: This command is used to give tags to the specified commit.

? git branch: This command lists all the local branches in the current repository.

? git checkout: This command is used to switch from one branch to another.

? git merge: This command merges the specified branch’s history into the current branch.

? git remote: This command is used to connect your local repository to the remote server.

? git push: This command sends the committed changes of master branch to your remote repository.

? git pull: This command fetches and merges changes on the remote server to your working directory.

? git stash: This command temporarily stores all the modified tracked files.

要查看或添加评论,请登录

SilentSol的更多文章

社区洞察

其他会员也浏览了