| Summary: | Git migration request for emf.compare | ||
|---|---|---|---|
| Product: | Community | Reporter: | Cedric Brun <cedric.brun> |
| Component: | Git | Assignee: | Eclipse Webmaster <webmaster> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | ||
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
| Bug Depends on: | |||
| Bug Blocks: | 333059 | ||
|
Description
Cedric Brun
I've created the initial repo. With regards to the import: the import tooling can only handle one cvs module, there isn't any wildcard support. So you'll either need to 'tag' all of the code you want (and then import based on that tag), or we'll need to unify the code in CVS and then import it. If you'd like to work on the import side of things(so you don't have to wait for us) here's a basic command to get you started: git-cvsimport -v -i -p -x -d :local:/cvsroot/modeling org.eclipse.emf/org.eclipse.emf.compare -C /gitroot/emfcompare/org.eclipse.emf.compare.git And you can edit the 'description' file in /gitroot/emfcompare/org.eclipse.emf.compare.git to set the details displayed on git.eclipse.org. -M. The org.eclipse.emf/org.eclipse.emf.compare.releng module is old, no more used and it's history provides little value, so we'll just drop it. I did type : /usr/local/libexec/git-core/git-cvsimport -v -i -p -x -d :local:/cvsroot/modeling org.eclipse.emf/org.eclipse.emf.compare -C /gitroot/emfcompare/org.eclipse.emf.compare.git A few minutes later I have a repository which I can clone on my laptop with git clone ssh://cbrun@git.eclipse.org/gitroot/emfcompare/org.eclipse.emf.compare.git Though I noticed the git.eclipse.org repository is not a *bare* repository, I have a .git in it. That mean I can't push my changes (git complains because the local files might be out-dated then) Looking to the other repositories they are all *bare* ones and don't have .git I did transformed the CVS imported non-bare repository with git clone --bare org.eclipse.emf.compare.git org.eclipse.emf.compare.git-bare and then renamed org.eclipse.emf.compare.git-bare in org.eclipse.emf.compare.git Everything looks fine now I'm just wondering if I did something wrong or if the documentation should be updated somewhere. I don't think you did anything 'wrong'(since it seems to be working for you), so it's possible the docs are a little out of date. -M. Everything works perfectly. I'll update the wiki accordingly to what I did. Thanks ! > Though I noticed the git.eclipse.org repository is not a *bare* repository, I
> have a .git in it.
FWIW, to avoid having org.eclipse.abc.git/.git, when performing a cvs import, I typically define the GIT_DIR environment variable as org.eclipse.abc.git, then specify-C as the "container" directory: /gitroot/containername/
Your way: GIT_DIR=null
-C /gitroot/containername/org.eclipse.abc.git
My way: GIT_DIR=org.eclipse.abc.git
-C /gitroot/containername/
Both methods work, so this is just a matter of preference.
(In reply to comment #4) > Everything works perfectly. I'll update the wiki accordingly to what I did. Did you update documentation anywhere? The usage of GIT_DIR is explained here: http://wiki.eclipse.org/Git/Migrating_to_Git#Using_git-cvsimport I did try with the GIT_DIR variable too and had some errors at some point.. I can't recall exactly what the issues were.. If you're ok I'll just add a paragraph in the doc explaining how to transform a "non bare" to a "bare" repository. Reopening as I have a strange issue... So far everything was working well, but today I want to push my changes and I get : Counting objects: 114, done. Delta compression using up to 2 threads. Compressing objects: 100% (45/45), done. Writing objects: 100% (65/65), 11.39 KiB, done. Total 65 (delta 36), reused 0 (delta 0) error: insufficient permission for adding an object to repository database ./objects fatal: failed to write object error: unpack failed: unpack-objects abnormal exit To ssh://cbrun@git.eclipse.org/gitroot/emfcompare/org.eclipse.emf.compare ! [remote rejected] master -> master (n/a (unpacker error)) error: failed to push some refs to 'ssh://cbrun@git.eclipse.org/gitroot/emfcompare/org.eclipse.emf.compare' Is there any ongoing issue with git.eclipse.org ? Not that I know of.
Your permissions look good:
>/gitroot/emfcompare/org.eclipse.emf.compare.git # ls -Fla | grep obj
drwxrwsr-x 152 cbrun modeling.emf.compare 3648 Mar 7 11:05 objects/
>
Inside the objects directory I only see one 'file' that looks odd:
drwxr-sr-x 2 pkonemann modeling.emf.compare 104 Feb 2 13:51 51/
So I made it rwxrwsr-x .
Outside of that as you 'own' these files I would expect you to be able to read/write as you see fit.
-M
(In reply to comment #9) > Inside the objects directory I only see one 'file' that looks odd: Matt, when you create a repository, don't forget to make it shared in the repo's config file: dev3:/gitroot/emfcompare/org.eclipse.emf.compare.git # cat config [core] repositoryformatversion = 0 filemode = true bare = true sharedrepository = 1 <=== Add this To be clear, I've added sharedrepository = 1 to the repo for this case. My previous comment was an FYI. It works now, thanks for the tip ! |