SVN files are not moved to GitLab

Hello Amitraj,

unfortunately, the archive you sent contains to useful data, there are a couple of empty directories only. However, judging from the screenshot, the push is not possible just because there is no ‘master’ branch in the repository. The same comes from the archive you sent – the directory structure looks like a Git repository directory structure, but it’s empty that means there are no references at all in the repository. And by the way, there are no single SubGit file or directory in the archive – if you archived the whole repository, then this fact means the repository was definitely configured incorrectly. Even empty GitLab repository (just created in GitLab UI) contains some references, and of course, SubGit adds more file, folders and references to the repository, so it looks like repository was somehow cleared or you are accessing incorrect directory on GitLab server.

So, how can I solve this issue or are you trying to say that I can not translate my SVN repository on my GitLab?

Hello Amitraj,

I don’t understand your setup at all: as I mentioned, a new GitLab repository has “master” branch from the very beginning, right after the GitLa repository is created in GitLab UI. Moreover, if you installed SubGit in this repository, there must be some additional files and references. But you sent me a zip file that contains no files at all; and the screenshot states there’s no “master” in the repository – and that means the directory you trying to push to is empty. I have no idea how has this happened, my assumption is that you are dealing with incorrect directory, but that’s just a guess, I have no information at all to say for sure. It’s surely possible to translate SVN repository to GitLab, but definitely something is configured not right. To find out what exactly is incorrect, please describe in details all the steps you took to translate this repository to GitLab – I mean, start from the GitLab repository creating and please mention all the details, like names and paths you set and commands you ran.

Following are the commands which I ran for this translation:

  1. I have configured the GIT_REPO_PATH parameter using the following command:

GIT_REPO_PATH=/users/amitraj/Documents/Translation/Others_Common_VB_PinGen.git

  1. I have run the following command to configure SubGit:

./subgit configure --layout directory “svn+ssh://svn@192.168.7.46/home/svn/svn/language/Others/Common/Visual Basic/PinGen” $GIT_REPO_PATH

  1. I have run the following command to install SubGit:

./subgit install $GIT_REPO_PATH

  1. I have run the following command to register license:

sudo ./subgit register --key /users/amitraj/Documents/Translation/subgit.key $GIT_REPO_PATH

  1. Create a new repository named ’ Others_Common_VB_PinGen’.
  2. Went to the ‘/users/amitraj/Documents/Translation/Others_Common_VB_PinGen.git’ folder.
  3. Ran the following command without any issue:

git remote add origin git@gitlab.com:AmitRaj_007/others_common_vb_pingen.git

  1. Ran the following command and got the error:

git push -u origin master

Is there any size limit of a GitLab group?

Thanks Amitraj, now the setup is clearer.

Try to push with the following command:

git push github --all --follow-tags

instead of pushing only master.

github or gitlab or something else?

this should be the name of the remote. If you added the remote as ‘origin’ then it should be set so:

git push origin --all --follow-tags

The following command worked for one repository but did not work for another repository:

git push origin --all --follow-tags

I followed the same set of steps but got following output:

Amits-MacBook-Pro:BAJ_EMI_TEST.git amitraj$ git push origin --all --follow-tags
No refs in common and none specified; doing nothing.
Perhaps you should specify a branch.
fatal: the remote end hung up unexpectedly
Everything up-to-date

This means the SubGit repository you are trying to push from is empty. Most probably SubGit configuration in this repository is incorrect and SubGit hasn’t imported any data because of this.

How can I correct this?

Configure SubGit repository correctly.
Most probably the SVN URL you set points nowhere, so make sure the URL is pointing to a real SVN directory.

Thanks for your response. Can you please tell me how can I backup of GitLab group with its history where there are more than 50 repositories in it?
GitLab is not installed on my Mac, I am accessing it on browser only.

Hello Amitraj,

It’s better to consult GitLat documentation on that matter:

https://docs.gitlab.com/ee/raketasks/backup_restore.html
https://docs.gitlab.com/omnibus/settings/backups.html