alibaba / git-repo-go

git-repo is a command-line tool for centralized workflow, can work with Gerrit, AGit-Flow compatible servers. It is written in Golang, and it can be installed easily without further dependency. It provides an easy-to-use solution for multiple repositories which is introduced by Android repo first, and it can also work with a single repository.

Home Page:https://git-repo.info/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

git repo sync ERROR: bad address for review ''

speedoops opened this issue · comments

Hi, Thanks for bring up such a great tool.

What's the problem?

ADE@2-vt0003 MINGW64 /d/CodeBase/AOSP
$ git repo sync
NOTE: fail to check remote server, you may need to install gerrit hooks by hands
ERROR: bad address for review ''

ADE@2-vt0003 MINGW64 /d/CodeBase/AOSP
$ git repo sync
NOTE: fail to check remote server, you may need to install gerrit hooks by hands
ERROR: bad address for review ''
FATAL: fail to rename lockfile to 'D:\CodeBase\AOSP.repo\project.list': rename D:\CodeBase\AOSP.repo\project.list.lock D:\CodeBase\AOSP.repo\project.list: Access is denied.

What did I do?

  1. I copy git-repo.exe to my local executable path (i.e. C:\Program Files\Git\mingw64\bin\git-repo.exe), then it's ok to run git repo version;
    $ git repo version
    git-repo version 0.7.4
    git version 2.24.1.windows.2

  2. I create a repo manifest project, and edit the default.xml to add sub git projects.

  3. I use git repo init -u <my-manifest-project-url to init the repo.

  4. git repo sync, so far so good.

  5. git repo pr, after this, whenever i execute git repo sync again, it shows the above erros.

Need help:

  1. Did I miss some step to use this git-repo tool? What should I do to fix this?
  2. It seems a little complicate to modify gitlab core, so I want to fix the above errors first.

Thanks

FYI: My repo manifest file:

<?xml version="1.0" encoding="UTF-8" ?>

<manifest>
    <remote name="origin" fetch="git@mq.code.ade.org:MY/test/"/>
    <default remote="origin" revision="master"/>

    <project path="docker/hello" name="docker/hello"/>
    <project path="docker/aloha" name="docker/aloha"/>
</manifest>

Thank you for contributing.

It's hard for me to test git-repo on Windows. At Alibaba, we use Macbooks, and most of the test cases for git-repo are written in sharness test framework which cannot be executed on Windows. So even though git-repo is written in a cross-platform language, I cannot guarantee that it can work on Windows.

Your fix sees OK, will merge.