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.
由于 GitHub 上的更改,我最近不得不完全删除并制作新的 Git 标签。它在 Git 中说您需要遵循某些说明来让用户更新现有标签。但是,我删除了所有标签,并创建了不同名称的新标签。我需要让我的团队使用哪些命令来删除他们现有的标签并提取新标签?
如果您乐于删除所有本地标签并从远程重新获取新标签,那么您可以使用以下两个命令:
git tag -l | xargs git tag -d git fetch --prune