Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
当我 fork 一个在其自述文件中有一些 shields.io 徽章的 repo 时,我的 fork 上的盾牌一直代表原始位置而不是我的 fork 的状态。是否可以参数化自述文件,以便它们指向“我来自的任何 github 项目”而不是特定的?
不,这是不可能的。徽章是带有硬编码 URL 的简单图像,因此您必须运行类似
sed -i 's|ozkriff/zemeroth|another-user/zemeroth|g' README.md
然后手动检查它是否有效,并且您没有意外修改其他硬编码路径。