git:如何将通过git笔记添加的消息推送到中央git服务器? [英] git: how to push messages added by git notes to the central git server?

查看:184
本文介绍了git:如何将通过git笔记添加的消息推送到中央git服务器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

似乎没有关于git笔记的正确文档。我已经使用git notes add命令添加了一些注释。但是当我推送提交,然后做一个单独的克隆,我没有看到那里的注释消息。有没有办法通过git notes命令添加所有的注释消息?

根据 here [git-scm.org] ,您可以使用

  git push< remote> refs / notes / * 

推送所有笔记。可以使用

  git fetch origin refs / notes / *:refs / notes / * 


it seems like there is no proper documentation regarding git notes. I have added some notes to one of the commit using git notes add command. but when i push the commit, and later do a separate clone, i dont see the note message there. Is there a way to push all the note messages added via git notes command?

解决方案

According to here [git-scm.org], you can use

git push <remote> refs/notes/*

to push all notes. Fetching can be done with

git fetch origin refs/notes/*:refs/notes/*

这篇关于git:如何将通过git笔记添加的消息推送到中央git服务器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆