2011-10-03 6 views
1

현재 CVS 저장소를 git로 마이그레이션하려고합니다. 모든 이전 데이터가 필요하지만 몇 가지 문제가 있습니다.cvsimport 이후 자식에 대한 문제

가져 오기 작업.

먼저 CVSREPOLOCAL

복사 한 후

git cvsimport -d /home/git/CVS_REPOLOCAL projectname -C projectname.git

gitosis도 projectname

[group projectname] 
members joe jim tom bart 
writable = projectname 
에 기록 할 수 있도록 구성되어 기존의 드라이브 거기 projectnamecvs init을 사용하여 로컬 CVS을 로컬 컴퓨터의

:

git clone ssh://[email protected]/projectnane.git 

변화 파일 및 수행

git commit -a 
[master 8a3d0f7] test 
1 files changed, 1 insertions(+), 1 deletions(-) 

gitk

는 새로운 마스터로 내 변화를 보여줍니다

...하지만 프로젝트에 다른 사람들에 사용할 수있는 변경을하려고 할 때 :

git push 
Counting objects: 7, done. 
Compressing objects: 100% (4/4), done. 
Writing objects: 100% (4/4), 432 bytes, done. 
Total 4 (delta 2), reused 0 (delta 0) 
remote: error: refusing to update checked out branch: refs/heads/master 
remote: error: By default, updating the current branch in a non-bare repository 
remote: error: is denied, because it will make the index and work tree inconsistent 
remote: error: with what you pushed, and will require 'git reset --hard' to match 
remote: error: the work tree to HEAD. 
remote: error: 
remote: error: You can set 'receive.denyCurrentBranch' configuration variable to 
remote: error: 'ignore' or 'warn' in the remote repository to allow pushing into 
remote: error: its current branch; however, this is not recommended unless you 
remote: error: arranged to update its work tree to match what you pushed in some 
remote: error: other way. 
remote: error: 
remote: error: To squelch this message and still keep the default behaviour, set 
remote: error: 'receive.denyCurrentBranch' configuration variable to 'refuse'. 
To ssh://[email protected] 
! [remote rejected] master -> master (branch is currently checked out) 

오래된 가져온 데이터를 유지하는 방법은 있습니까? 여러 사용자를 위해 ssh gitosis를 얻으시겠습니까?

나는 하나 개의 실행했다하지만 CVS 그렇게 솔루션 :(

+0

안녕, 빠른 응답

감사합니다.
내가 CVS에서 다시 가져온 후이 시도했습니다
MV projectname.git 프로젝트 이름
자식 클론 --bare 프로젝트 이름 projectname.git

지금은 밀어 로컬 컴퓨터에서 가져올 수 있습니다.

이것은 좋은 방법입니까?

gery

답변

0

를하지 가져올없이 세 가지 옵션이 있습니다

    베어 (작업 사본없이) 수입과 서로에 대한
  1. 를 사용하여 하나 개의 저장소 하나를 cvs를 가져온 곳에서 맨손으로 코드를 푸시하십시오.이 옵션을 가장 깨끗한 옵션으로 생각합니다. 워크 스테이션에서 가져 오기를 수행하고 서버를 가져 오지 않고 한 번 폐기한다고 주장합니다 스위치가 끝났습니다.
  2. 저장소에서 헤드 분리 (git checkout [email protected]{0}) 또는 확인 다른 지점 (git checkout -b cvsimport).
  3. 실제로 오류 메시지에 언급 된 후크를 구현하지만 다소 까다 롭고 실제로 작업 트리가 다시 필요할 것으로 생각하지 않습니다.
관련 문제