【问题标题】:git svn show-externals Output Interpretationgit svn show-externals 输出解释
【发布时间】:2021-08-28 02:19:19
【问题描述】:

我有一个使用 git svn clone 克隆到 Git 的 SVN 存储库。存储库在 SVN 中有外部。当我使用git svn show-externals 时,我会为不同的提交获得不同的外部前缀打印。打印示例如下:

/^/library/branches/binary
/^library/branches/binary
# /library/branches/test/
# /
/subproject/^/library/tip

每个前缀的解释是什么?

【问题讨论】:

    标签: git svn git-svn


    【解决方案1】:

    正如http://svnbook.red-bean.com/en/1.7/svn.advanced.externals.html 的官方文档中所解释的,唯一接受的相对说明符是:

    ../
    
    Relative to the URL of the directory on which the svn:externals property is set
    
    ^/
    
    Relative to the root of the repository in which the svn:externals property is versioned
    
    //
    
    Relative to the scheme of the URL of the directory on which the svn:externals property is set
    
    /
    
    Relative to the root URL of the server on which the svn:externals property is versioned
    
    ^/../REPO-NAME
    
    Relative to a sibling repository beneath the same SVNParentPath location as the repository in which the svn:externals is defined.
    

    编辑

    关于以# 开头的那些,认为外部是SVN 的属性,因此可以通过在# 符号前加前缀来注释掉它们。

    【讨论】:

    • 当我检查我拥有的 SVN 服务器时,我看到上面列出的第一个打印是针对(例如):www.foo.com/library/ 的存储库,外部来自分支:二进制。因此,根据您的回复,似乎第一次打印应该是:/library/branches/binary,没有额外的^/。我错过了什么吗?另外,我得到的其他打印件在您的答案中没有等效项怎么样?
    • 如果他们被评论,是否意味着他们仍然是我需要在 Git 中添加的外部?他们被评论而其他人没有评论的原因是什么?
    • 对不起,你已经问过代码是谁写的了。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-02-15
    • 2019-03-14
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多