In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
This article introduces what git commands can be used in your work, the content is very detailed, interested friends can refer to, I hope it can be helpful to you.
Branch operation:
Git branch create branch
Git branch-b creates and switches to the newly created branch
Git checkout switching branch
Git branch View Branch list
Git branch-v to view the last operation of all branches
Git branch-vv view current branch
Git brabch-b branch name origin/ branch name create remote branch to local
Git branch-- merged to view branches that have been merged by other branches and current branches
Git branch-- no-merged to view branches that are not merged with the current branch
Git branch-d branch name delete local branch
Git branch-D branch name forcibly delete branch
Git branch origin: branch name removes remote warehouse branch
Git merge branch name merges branches to the current branch
Staging operation:
Git stash temporarily saves the current modification
Git stash apply restores the most recent temporary save
Git stash pop restores staging and deletes staging records
Git stash list View scratch list
Git stash drop staging name (e.g. stash@ {0}) removes a staging
Git stash clear clear temporary storage
Fallback operation:
Git reset-- hard head ^ rollback to the previous version
Git reset-- hard ahdhs1 (commit_id) rollback to a version
Git checkout-file undoes the modified file (if the file is added to the temporary storage area, it will be returned to the temporary storage area, and if the file is added to the version library, it will be restored to the state after it was added to the version library)
Git reset HEAD file withdraws files from the staging area and modifies them to the workspace
Label operation:
Add tags to the git tag signature (default for the current version)
Git tag signature commit_id tags a submission record
Git tag-a signature-m 'description' to create a new tag and add comments
Git tag lists all tags
Git show tag signature to view label information
Git tag-d signature to delete local label
Git push origin signature push label to remote warehouse
Git push origin-tags pushes all tags to the remote warehouse
Git push origin: refs/tags/ tag signature removes tags from remote repositories
General operation:
Git push origin test pushes the local branch to the remote warehouse
Git rm-r-cached file / folder name cancels the file being versioned
Git reflog gets the executed command
Git log-- graph View Branch merge Diagram
Git merge-- no-ff-m 'merge description' branch names are not merged in Fast forward mode, in which merge records can be seen
Git check-ignore-v filename View ignore rules
Git add-f filename forces the file to be submitted
Git creates a project repository:
Git init initialization
Git remote add origin url Associated remote Warehouse
Git pull
Git fetch acquires all the branches in the remote warehouse to the local
Ignore files that have been added to the version library:
Git update-index-- assume-unchanged file ignores individual files
Git rm-r-cached file / folder name (. Ignore all files)
Cancel ignoring files:
Git update-index-no-assume-unchanged file
Pull and upload exemption password:
Git config-global credential.helper store
About what can be used in the work of git commands shared here, I hope that the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.