Xcopy Deploying ASP.NET Subversion Managed Project

I am currently using Subversion to manage an ASP.NET site. I find that whenever I submit my website to my server, I copy a large number of hidden .svn folders and all the contents can be inside them.

Does anyone have any suggestions to prevent this? I don’t particularly want these hidden .svn folders on the production server, but I couldn’t manually delete each .svn folder before I upload my website, I don’t understand how to create a production .svn-folder-free environment.




Edit: Thanks to everyone, these are great offers, I really appreciate it!

+4
Oct 22 '08 at 3:50
source share
4 answers

How about running Subversion on the server and then export svn from the repository? Exporting svn is similar to checking, but without .svn folders (and without the ability to do Subversion work in this directory).

Alternatively, export the svn repo to your local computer and then the FTP version of the exported version.

+2
Oct 22 '08 at 3:53
source share

Right-click on the project folder and delete all .svn folders recursively.

Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Folder\shell\DeleteSVN] @="Delete SVN Folders" [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Folder\shell\DeleteSVN\command] @="cmd.exe /c \"TITLE Removing SVN Folders in %1 && COLOR 9A && FOR /r \"%1\" %%f IN (.svn) DO RD /s /q \"%%f\" \"" 
+4
Oct 22 '08 at 4:04
source share

two sentences:

  • Use robocopy or xcopy to filter .svn folders
  • svn export web server repository ( docs ). Export will not write .svn folders

see also: Tortoise SVN hidden SVN folders

+3
Oct 22 '08 at 3:54
source share

I have a postbuild step that prepares a clean folder for deletion as part of the project build. Here is how I do it:

  <PropertyGroup> <DropPath>..\..\drop\</DropPath> <TestDropPath>..\..\test\</TestDropPath> </PropertyGroup> <Target Name="AfterBuild"> <ItemGroup> <Binaries Include="$(OutputPath)**\*.*" /> </ItemGroup> <ConvertToAbsolutePath Paths="$(DropPath)"> <Output TaskParameter="AbsolutePaths" ItemName="FullDropPath" /> </ConvertToAbsolutePath> <Message Importance="High" Text="Binplacing -&gt; @(FullDropPath)" /> <Copy SourceFiles="@(Compile)" DestinationFiles="@(Compile->'$(DropPath)%(Identity)')" /> <Copy SourceFiles="@(Content)" DestinationFiles="@(Content->'$(DropPath)%(Identity)')" /> <Copy SourceFiles="@(EntityDeploy)" DestinationFiles="@(EntityDeploy->'$(DropPath)%(Identity)')" /> <Copy SourceFiles="@(Binaries)" DestinationFiles="@(Binaries->'$(DropPath)%(Identity)')" /> </Target> 

Of course, svn export works. :-) However, with this approach, you cannot modify and transfer any source file that was changed during the build back to the repository.

+2
Oct 22 '08 at 4:00
source share



All Articles