【问题标题】:How to link redmine user with repository user如何将 redmine 用户与存储库用户链接
【发布时间】:2011-04-22 07:24:57
【问题描述】:

我有一个与存储库 (git) 链接的 Redmine 项目。 我想将我的提交与我的 Redmine 帐户相关联。现在我的每次提交都是由“匿名”用户进行的,因为 RM 用户名和 repo 用户名不同。

【问题讨论】:

    标签: git repository redmine


    【解决方案1】:

    在您的项目设置下,在带有您的存储库 URL 的灰色部分下方的存储库选项卡中,有一个用户图标。此屏幕将允许您将 repo 用户名与 redmine 用户名进行映射。这存在于我的 redmine 版本 1.1.3.stable 中。不确定它是在哪个版本中实现的。

    【讨论】:

    • 是的,这个效果最好 ^_^ 我不确定我是否可以早点使用它,因为现在我使用的是稳定的 1.2.0(一周前发布;))。无论如何,感谢您提供此解决方案。
    • 在 1.2.1 中,如果 git 用户名或电子邮件匹配,现在应该自动执行此操作。在同一部分/选项卡中 user562034 提到:“具有相同 Redmine 和存储库用户名或电子邮件的用户会自动映射。”
    • 似乎不再是这种情况了。 3.4.3版看不到这样的画面
    【解决方案2】:

    你看到like those的消息了吗?

    Redmine is checking your changes for correctness...
    Authenticated as Lukasz Dywicki
    Changes:
        Ref: refs/heads/fusion type: commit
                Error: Initial commit can be done only by repository manager
            Commit: 442155e0797c4f4fbae74f91265ab664f3ca0880
            Commit: c8a137d577f2033721c9d52e0907b7e9f8ca48b2
                Error: Commit author name or email is wrong
                Error:     Execute following commands and _recreate_ commit:
                Error:     git config --global user.name "Lukasz Dywicki"
                Error:     git config --global user.email luke@code-house.org
    

    this thread中所述:

    请记住,~/.gitconfig 文件中的电子邮件应与您在 Redmine 中注册的电子邮件一致:
    检查您的电子邮件:

    git config --get user.email
    

    设置您的电子邮件:

    locally (in project folder):
    git config user.email your@email.com
    
    or globally (anywhere):
    git config --global user.email your@email.com
    

    这是因为 redmine 代码中的逻辑(问题?)..

    【讨论】:

    • Witaj ;) 不,我没有看到这些消息。 RM 在我的仓库中运行良好。只有“错误”是提交不是我的。所以你告诉用户是通过电子邮件地址识别的......嗯,好的,所以我必须在我的本地仓库中更改邮件地址;)谢谢,我稍后会检查你的解决方案,如果正确,将其标记为答案
    • 所以...我在这里找到了我的名字 ;)
    • @splatch 确实 :) 让我知道这是否是一个问题,如果你想让我混淆它。
    • 我的名字很好,请省略项目名称。
    猜你喜欢
    • 2018-07-30
    • 2011-11-09
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-12-05
    • 1970-01-01
    • 2012-10-10
    • 1970-01-01
    相关资源
    最近更新 更多