【问题标题】:Error "repository is not local" when doing HG update进行 HG 更新时出现错误“存储库不是本地的”
【发布时间】:2012-10-09 15:03:46
【问题描述】:

我正在尝试在我们团队使用了一段时间的 repo 上更新到 Mercurial 的最新拉取更改。

C:\code\printlogix\templates-dev>hg update --clean
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
getting changed bfiles
abort: repository 'https://printlogix.kilnhg.com/Code/Repositories/Templates/templates-dev' is not local

C:\code\printlogix\templates-dev>

不确定这个“repository xxxx is not local”消息是什么意思,我以前从未见过。

作为参考,我在 Windows 7 x64 上使用 TortoiseHg 2.5.1(带有 Mercurial 2.3.2)。我们还使用 KilnBfiles 扩展。

【问题讨论】:

  • 您最近是否升级到新版本的 Mercurial?您应该尝试设置--debug--traceback 再次运行该命令,看看它是否提供更多信息。

标签: mercurial tortoisehg


【解决方案1】:

远射,但我遇到了这个问题(hg v 2.4.2)并查看了调试输出并发现以下内容。

calling hook preupdate.eol: <function preupdate at 0x000000000263A048>
lock: reading lock data from c9a8f1b931da
lock: reading d:\kev\htmapp\.hglocks@c9a8f1b931da <---- RELEVANT CLUE
using https://code.google.com/p/htmapp/
sending capabilities command
code.google.com certificate successfully verified
Traceback (most recent call last):
  File "mercurial\dispatch.pyo", line 88, in _runcatch
  File "mercurial\dispatch.pyo", line 741, in _dispatch`

我使用的是 hglocks 扩展,在查看网站上的文档后发现它与 2.3 之后的任何新版本都不兼容。禁用扩展并解决问题。

【讨论】:

    【解决方案2】:

    在 Windows 上,您需要设置 TortoiseHG/Mercurial 以使用 TortoisePlink 来支持 SSH。详情在这里:

    https://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial

    短版:在 mercurial.ini 文件的 [UI] 部分添加如下所示的行。

    ssh = "C:\Program Files\TortoiseHg\TortoisePlink.exe" -ssh -2 -batch -C
    

    然后注销并重新登录。不知道为什么这是必要的,但在我这样做之前我无法获得 mercurial 来获取 mercurial.ini 更改。

    例如,我的 mercurial.ini 文件如下所示:

    # Generated by TortoiseHg settings dialog
    [extensions]
    mq = 
    rebase = 
    transplant = 
    hgsubversion = C:\Users\rsyring\dev\3rdparty\hgsubversion\hgsubversion
    eol = 
    
    [ui]
    username = Randy Syring <me@nospam.com>
    ssh = "C:\Program Files\TortoiseHg\TortoisePlink.exe" -ssh -2 -batch -C
    

    【讨论】:

      【解决方案3】:

      在这种情况下,Mercurial 消息并不是真正具有描述性的。将hg --debug -vvv --traceback 用于您的转换命令以获取更多详细信息会有所帮助。

      【讨论】:

        【解决方案4】:

        从命令行中移除 -R

        从这里

        hg pull -R URL -rREVISION
        

        到这里

        hg pull -rREVISION URL
        

        【讨论】:

          猜你喜欢
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 2018-11-10
          • 1970-01-01
          相关资源
          最近更新 更多