解决办法 not Signed-off-by author/committer/uploader in commit message footer

现象

一个 Gerrit 是从已经 merge 的仓库 回滚出来的一个,然后在上面修改,修改完了提交的时候发现一个错误

! [remote rejected] HEAD -> refs/drafts/stable/beryllium (not Signed-off-by author/committer/uploader in commit message footer)

对于gerrit 这个工具网上的解决方法是比较少的,看了官方有个解决方案。

https://gerrit-review.googlesource.com/Documentation/error-not-signed-off-by.html

大概说下, 就是这几个原因

missing Signed-off-by in the commit message footer
Signed-off-by is contained in the commit message footer but it’s neither from the author, committer nor uploaderSigned-off-by from the author, committer or uploader is contained in the commit message but not in the footer (last paragraph)

解决办法

解决办法就是

To be able to push your commits you have to update the commit messages as explained here so that they contain a Signed-off-by from the author, committer or uploader in the last paragraph. However it is important that you only add a Signed-off-by if you understand the semantics of the Signed-off-by and the commit applies to the rules that are connected with this footer.

通俗的讲就是, 先 git commit --amend,然后把对应的用户信息加上去,格式如下
Signed-off-by: rikxiao <xxd0225@gmail.com>

最后再次push即可。

posted @   叉叉敌  阅读(612)  评论(0编辑  收藏  举报
编辑推荐:
· go语言实现终端里的倒计时
· 如何编写易于单元测试的代码
· 10年+ .NET Coder 心语,封装的思维:从隐藏、稳定开始理解其本质意义
· .NET Core 中如何实现缓存的预热?
· 从 HTTP 原因短语缺失研究 HTTP/2 和 HTTP/3 的设计差异
阅读排行:
· 分享一个免费、快速、无限量使用的满血 DeepSeek R1 模型,支持深度思考和联网搜索!
· 基于 Docker 搭建 FRP 内网穿透开源项目(很简单哒)
· ollama系列01:轻松3步本地部署deepseek,普通电脑可用
· 25岁的心里话
· 按钮权限的设计及实现
点击右上角即可分享
微信分享提示