Closed FerencYAO closed 10 years ago
Just curious, when is there a *.git
directory?
after execute ./add_mirror.sh --git --project-name reachability --mirror https://github.com/tonymillion/Reachability.git
in the gitlab_namespace directory generate the *.git file
That should create a directory in "${repo_dir}/${gitlab_namespace}" based on --project-name reachability
. So there should only be ${repo_dir}/${gitlab_namespace}/reachability
. Is this not the case with you?
i think the *.git file is lib/manage_gitlab_project.py generate
manage_gitlab_project.py create the project so the *.git file exist in the ${repo_dir}/${gitlab_namespace} directory.
manage_gitlab_project.py
does not touch the local filesystem at all. It resolves the gitlab remote (or if the project doesn't exist it creates the project and returns the remote). Can you ls -a -1 ${repo_dir}/${gitlab_namespace}/
? Show me what you see.
Also, you don't mention where the ls -1
is that you want to change. I assume you mean within ls-mirrors.sh
. The folders created when you view ls -1
in ls-mirrors.sh
are created by a git command. The folder created should be literally reachability
in your case.
i found the reason, i use the same user for gitlab-mirrors and gitlab, so reachability and reachability.git in the same directory. git@efserver:~/repositories/mirrors$ ls -al /home/git/repositories/mirrors/ total 96 drwxrwx--- 24 git git 4096 Feb 12 11:28 . drwxrws--- 7 git git 4096 Feb 12 09:32 .. drwxrwxr-x 7 git git 4096 Feb 12 11:28 egotableviewpullrefresh drwxrwx--- 7 git git 4096 Feb 12 11:28 egotableviewpullrefresh.git drwxrwxr-x 7 git git 4096 Feb 12 11:27 fmdb drwxrwx--- 7 git git 4096 Feb 12 11:26 fmdb.git drwxrwxr-x 7 git git 4096 Feb 12 11:25 jasidepanels drwxrwx--- 7 git git 4096 Feb 12 11:25 jasidepanels.git drwxrwxr-x 7 git git 4096 Feb 12 11:20 mknetworkkit drwxrwx--- 7 git git 4096 Feb 12 11:19 mknetworkkit.git drwxrwxr-x 7 git git 4096 Feb 12 11:22 openudid drwxrwx--- 7 git git 4096 Feb 12 11:22 openudid.git drwxrwxr-x 7 git git 4096 Feb 12 11:24 pscollectionview drwxrwx--- 7 git git 4096 Feb 12 11:24 pscollectionview.git drwxrwxr-x 7 git git 4096 Feb 12 11:10 reachability drwxrwx--- 7 git git 4096 Feb 12 11:10 reachability.git drwxrwxr-x 7 git git 4096 Feb 12 11:21 ssziparchive drwxrwx--- 7 git git 4096 Feb 12 11:21 ssziparchive.git drwxrwxr-x 7 git git 4096 Feb 12 11:22 svprogresshud drwxrwx--- 7 git git 4096 Feb 12 11:22 svprogresshud.git drwxrwxr-x 7 git git 4096 Feb 12 11:23 toast drwxrwx--- 7 git git 4096 Feb 12 11:23 toast.git drwxrwxr-x 7 git git 4096 Feb 12 11:26 tttattributedlabel drwxrwx--- 7 git git 4096 Feb 12 11:26 tttattributedlabel.git
config.sh:
system_user="git"
user_home="/home/${system_user}"
repo_dir="${user_home}/repositories"
enable_colors=true
git_svn_additional_options="-s"
no_create_set=false
#
#
gitlab_namespace="mirrors"
gitlab_url="http://iosteam.gitlab.com"
gitlab_user="gitmirror"
gitlab_user_token_secret="$(head -n1 "${user_home}/private_token")"
ssl_verify=false
sorry for this, you awesome
Ah yes,
You can't use the same user as gitlab... this is true. It is recommended to keep them separate. Perhaps it would help for me to change the default repositories
directory so it doesn't coincide with GitLab's repositories
directory.
I also have plans for an easy setup script #12 which will hopefully resolve issues like this.
ls -1 "${repo_dir}/${gitlab_namespace} should change to ls -1 --ignore=*.git "${repo_dir}/${gitlab_namespace}"