git status 显示乱码
git-svn克隆太慢

同时管理git与svn两种仓库

妙音 posted @ 2018年1月13日 21:31 in git with tags git-svn , 3986 阅读
如果开发环境使用git仓库,正式环境使用svn仓库。如何将管理有种仓库的代码呢?
幸好git与svn有一个桥接工具git-svn,可以将两种仓库衔接起来,用不同分支进行管理。
 
下面以将git代码,并入svn仓库为例
  • 首先从svn仓库克隆代码
git svn int http://ip/svn/demo/trunk  demo
git svn fetch -r HEAD
  • 添加git仓库地址
cd demo
git remote add git  http://ip/path/demo.git
  • 获取git仓库的分支
git fetch git master    #获取git仓库的master分支
git fetch git 1.0       #获取git仓库的1.0分支
git fetch git           #获取所有git分支
 
  • 此时本地git的分支情况
➜  demo git:(master) git branch -a
* master               #默认对应svn
  remotes/git-svn      #svn
  remotes/git/1.0      #远程git的1.0分支
  remotes/git/master   #远程git的master分支
  • 将git代码合并到svn分支
git merge  git-master
  • 更新并提交
git svn rebase
git svn dcommit
 
此生必看的科学实验-水知道答案
此生不能不认识的一个人
精神病为什么治不好
百病之源

 

Avatar_small
Gaming mouse price i 说:
2023年6月19日 19:29

I don’t think many of websites provide this type of information.

Avatar_small
my today activity 说:
2023年7月10日 22:51

My Activity today is a piece tracking or recording user activity that collects information whenever users with a Google account use Google services daily such as today, yesterday, weekly, monthly, and yearly for entire activities from the account generation. my today activity These My Activity recording or collection services include YouTube, Google Maps, and other Google apps, as well as your search history when using the Google Chrome browser or doing a Google search.

Avatar_small
Imamia Quran Academy 说:
2023年8月04日 06:54

Hi everyone, I really love your story. You have very useful information; I am from Imamia Quran Academy. Shia Online Quran Academy is an institute for Quran Education. They have trained teaching staff along with renowned Islamic Scholars for a better understanding of the Quran. Join our Online Shia Quran Academy now, and Start your free 3 days Trial.

Avatar_small
CBSE 4th Class Syll 说:
2023年8月21日 19:16

CBSE Curriculum is based on the National Curriculum Framework and Provides Opportunities for Students to Achieve Excellence in Learning, CBSE Provides the Syllabus for 4th Class, This new Syllabus CBSE 4th Class Syllabus 2024 are Designed Strategically by a Team of Subject Experts and are Prescribed by the Ministry of Human Resource Development, formerly Ministry of Education, is Responsible for the Development of Human Resources in India, Primary Level Syllabus for the Children of has been developed with the Supervision of the Central Board of Secondary Education.

Avatar_small
โบนัสและโปรโมชั่นการ 说:
2023年8月28日 11:44

Nice post! This is a very nice blog that I will definitively come back to more times this year! Thanks for informative post.

Avatar_small
โบนัสและโปรโมชั่นการ 说:
2023年8月28日 11:45

Nice post! This is a very nice blog that I will definitively come back to more times this year! Thanks for informative post.


登录 *


loading captcha image...
(输入验证码)
or Ctrl+Enter