SVN 仅从标签中导出更改的文件 [英] SVN export just the changed files from tags

查看:28
本文介绍了SVN 仅从标签中导出更改的文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有谁知道如何使用 svn 仅从两个标签中导出更改过的文件?

Does anyone know how to export only the changed files from two tags using svn?

假设我有标签 1.0,然后修复了主干中的错误.接下来我准备发布一个新补丁,所以我将它标记为 1.1.现在我想在标签 1.0 和 1.1 之间导出更改的文件.这可能吗?

Lets say I have tag 1.0 and then later fix bugs in the trunk. Next I am ready for a new patch release so I tag it 1.1. Now I want to export the changed files between tag 1.0 and 1.1. Is this possible?

推荐答案

svn diff --summarize url/to/tag1.0 url/to/tag1.1

svn diff --summarize url/to/tag1.0 url/to/tag1.1

将为您提供在这两个标签之间更改的文件列表.您应该能够在脚本中解析该列表并使用

will give you a list of files that changed between those two tags. You should be able to parse that list in a script and export each file individually with either

svn 导出 url/to/file 文件路径

svn export url/to/file filepath

svn cat url/to/file > 文件

svn cat url/to/file > file

如果您使用的是 TortoiseSVN:

If you're using TortoiseSVN:

  • 打开存储库浏览器,浏览到 tag1.0,右键单击,选择标记进行比较"
  • 浏览到 tag1.1,右击,选择比较网址"
  • 在文件差异对话框中,选择在标签之间更改的所有文件/文件夹 (Ctrl+A)
  • 右键单击,选择导出到..."

这篇关于SVN 仅从标签中导出更改的文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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