git - 如何将私有工作流的输出提交到另一个公共仓库
问题描述
我需要将我的私人回购工作流(github-actions)的输出提交到公共回购是否可能?
解决方案
这应该可以使用标准的 git 工具来实现。将这样的内容添加到您的工作流程中:
cd wherever_your_output_resides
# clone the public repo, or pull if we have a clone already
git pull origin || git clone <url> .
# check out the desired branch (optional)
git checkout some_branch
# stage output
# (you may need to tweak this, e.g. to include files not in the index yet)
git add --all
# commit
git commit -m "<message for the commit>"
# push to the remote repo
git push origin
git 命令不在我的脑海中;你可能想对这些进行试运行,直到一切顺利。
推荐阅读
- sql - 为什么根本不使用由查询计划中的提示插入的新索引?
- java - Spring 中的 @Value 如何在内部工作以便它可以读取 Kubernetes ConfigMap?
- c++ - 如果任何一个线程完成并获得可访问状态,则多线程检查可访问性,然后通过 priting 状态退出主线程
- python - Braintree 客户端令牌生成方法在 Django 中引发 XML 错误
- rust - 有没有办法使用宏定义“匹配”标签?
- python - Python OOP 动态选择实例
- c - 如何在avr中打印一些东西
- flutter - 当我尝试动态传入onPressed回调时,他报如下错误
- excel - 如何在VBA Excel中将公式填充到最后一行?
- react-native - 滑动数据图表 React-Native