开发者

export changed files using tortoise svn to another directory

For my project I would like to export only the changed/added files since last update (those marked with red exclamation or plus sign) using tortoise svn, however I can't seem to find the right combination to do this simple task.

What I do now is do xcopy with specified modified date, h开发者_JS百科owever it misses some files which were simply added to a folder and not modified. Since I can get a list of changes, I don't see any way to simply export these files to a deploy directory.


Check-for-modifications dialog, sort by status. Shift-Click or Ctrl-Click to select all those with "modified" and "added" status. Then simply right-drag the files from the Check-for-modifications dialog to another folder in explorer.

Another way (if you already committed your changes): Show log dialog, select all revisions with the interesting changes. In the lower pane, shift-select all entries, right-click, choose "save as".

Yet another way: Use the repository browser, find the first url (assuming you want to export everything that's changed between two tags, e.g., version 1 and version 2), right-click, "Mark for comparison". Find the second url, right-click, "compare urls". In the following "changed files" dialog, select all files, right-click, choose "export selection to...".


From the TortoiseSVN daily use guide:

Another way to export from a working copy is to right drag the working copy folder to another location and choose ... Context Menu → SVN Export changed items here ... The third option exports only modified items, but maintains the folder structure.


In the check for modification dialog, select all files you want to export and then right click and select export.

This is a better solution, specially if you want to export files in subdirectories. (The drag option from check for modification will flatten the directory structure).


Another option.

Lets say that you last deployed your application from repository version #85. After a few weeks of development, the repository is now up to revision #178.

  1. Using TortoiseSVN, right-click on your working folder and select “Show Log” from the TortoiseSVN menu.
  2. Click the revision that was last published (#85 in this example) Ctrl+Click the HEAD revision (or whatever revision you want to release ie #178) so that both the old and the new revisions are highlighted.
  3. Right-click on either of the highlighted revisions and select “Compare revisions.” This will open a dialog window that lists all new/modified files.
  4. Select all files from this list (Ctrl+a) then right-click on the highlighted files and select “Export selection to…”
  5. You’ll be prompted for a location to save your updated files and SVN will export them all with the directory structure preserved. You can then zip this up for your client, transfer it to your host or whatever you normally do to deploy the application.

From Here


That's not a built-in feature of Tortoise. You could probably whip up a script in powershell that would parse the output of 'svn st' and copy the files though.


Your best bet might be to use svn status, then grep on the file codes to determine what files to copy.

see http://svnbook.red-bean.com/en/1.0/re26.html.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜