发布时间:2025-12-10 19:20:52 浏览次数:30
[TFS4]TFS git地址,分支概念[通俗易懂]1)上传本地代码到TFSa.GenerateGitCredentials,即创建git账户密码b)上传本地代码2)git分支也可以参考此文:Git在团队中的**实践如何正确使用GitFlow作者:khowarizmi链接:https://www.zhihu.com/quest
a.Generate Git Credentials,即创建git账户密码
b)上传本地代码
git add *
git commit -m "纳入管理"
git remote add origin https://qiongyan2.visualstudio.com/_git/BeibeiCore2
git push -u origin --all
{{-u参考链接:https://www.zhihu.com/question/20019419/answer/83091592}}
git remote rm origin
【正版授权,激活自己账号】:Jetbrains全家桶Ide使用,1年售后保障,每天仅需1毛
Username for 'https://qiongyan2.visualstudio.com': qiongyan2@126.com
Password for 'https://qiongyan2@126.com@qiongyan2.visualstudio.com':
也可以参考此文:Git 在团队中的**实践–如何正确使用Git Flow
作者:khowarizmia. 创建develop分支git branch developgit push -u origin develop b. 开始新Feature开发git checkout -b some-feature develop# Optionally, push branch to origin:git push -u origin some-feature # 做一些改动 git statusgit add some-filegit commit c. 完成Featuregit pull origin developgit checkout developgit merge --no-ff some-featuregit push origin developgit branch -d some-feature# If you pushed branch to origin:git push origin --delete some-feature d. 开始Relasegit checkout -b release-0.1.0 develop# Optional: Bump version number, commit# Prepare release, commite. 完成Releasegit checkout mastergit merge --no-ff release-0.1.0git pushgit checkout developgit merge --no-ff release-0.1.0git pushgit branch -d release-0.1.0# If you pushed branch to origin:git push origin --delete release-0.1.0 git tag -a v0.1.0 mastergit push --tagsf. 开始Hotfixgit checkout -b hotfix-0.1.1 master g. 完成Hotfixgit checkout mastergit merge --no-ff hotfix-0.1.1git pushgit checkout developgit merge --no-ff hotfix-0.1.1git pushgit branch -d hotfix-0.1.1git tag -a v0.1.1 mastergit push --tags
书本目录:https://git-scm.com/book/zh/v2
qiongyazhudembp:BeibeiCore qiongyanzhu$ git branch --all* master remotes/origin/masterqiongyazhudembp:BeibeiCore qiongyanzhu$
$ git branch develop$ git branch --all develop* master remotes/origin/master
然也可以同步
$ git push -u origin develop:developTotal 0 (delta 0), reused 0 (delta 0)To https://qiongyan2.visualstudio.com/_git/BeibeiCore2 * [new branch] develop -> developBranch develop set up to track remote branch develop from origin.$ git branch --all develop* master remotes/origin/develop remotes/origin/master
$ cat .git/refs/heads/master54b20f4c9f793ad1fc59f4e4b03867c93ad2bca7$ git checkout developSwitched to branch 'develop'Your branch is up-to-date with 'origin/develop'.$ git branch --all* develop master remotes/origin/develop remotes/origin/master
远程如果已经有develop分支
$ gitdiff 工作区与暂存区(提交暂存区,stage)相比的差异
$git checkout bootstrap.js