Source control folders copied into Output folder

Topics: Developer Forum, User Forum
Mar 20, 2007 at 3:42 PM
Hi.
Firstly thank you for such an excellently put-together application...

I've found a problem that seems similar to Excluding directories from additional contents but occurs at a different stage
in the build

It's happening when icon/styles/scripts folders are copied from the Presentation folder
to the Output folder.
My Presentation folder is checked into Subversion, so every folder copies contains a .svn
folder, with text files for source control.

So, this happens during this stage in the build:

-------------------------------
Copying standard help content...
...
D:\dev\subversion\MyProject\trunk\MyProject\tools\Sandcastle\Presentation\Prototype\icons\security.gif -> D:\dev\subversion\MyProject\trunk\build\Documentation\MyProject.Docs\Working\Output\icons\security.gif
D:\dev\subversion\MyProject\trunk\MyProject\tools\Sandcastle\Presentation\Prototype\icons\static.gif -> D:\dev\subversion\MyProject\trunk\build\Documentation\MyProject.Docs\Working\Output\icons\static.gif
D:\dev\subversion\MyProject\trunk\MyProject\tools\Sandcastle\Presentation\Prototype\icons\.svn\all-wcprops -> D:\dev\subversion\MyProject\trunk\build\Documentation\MyProject.Docs\Working\Output\icons\.svn\all-wcprops
D:\dev\subversion\MyProject\trunk\MyProject\tools\Sandcastle\Presentation\Prototype\icons\.svn\entries -> D:\dev\subversion\MyProject\trunk\build\Documentation\MyProject.Docs\Working\Output\icons\.svn\entries
D:\dev\subversion\MyProject\trunk\MyProject\tools\Sandcastle\Presentation\Prototype\icons\.svn\format -> D:\dev\subversion\MyProject\trunk\build\Documentation\MyProject.Docs\Working\Output\icons\.svn\format
D:\dev\subversion\MyProject\trunk\MyProject\tools\Sandcastle\Presentation\Prototype\icons\.svn\prop-base\alert_caution.gif.svn-base -> D:\dev\subversion\MyProject\trunk\build\Documentation\MyProject.Docs\Working\Output\icons\.svn\prop-base\alert_caution.gif.svn-base
...

This causes a HTMLHelp 1.x compiler error later on in the build.

I thought I could solve this by modifying the copyOutput.bat file in the Presentation folder, but the GUI doesn't appear to use this script as changing it makes no difference.

I'm working around this at the moment by adding the following to BuildHelpTopics.bat which seems to be the first
script that runs after the files are copied:

rem Workaround Step 2b - Remove .svn folders from Output path
rmdir /S /Q Output\icons\.svn
rmdir /S /Q Output\scripts\.svn
rmdir /S /Q Output\styles\.svn

Any suggestions for a more elegant solution?
Thanks.
Mar 20, 2007 at 4:00 PM
You could make a copy of your presentation folder before you do the build, and strip your .svn folder from the copy
This avoids read-only problems, and lets you munge the temporary copy without worrying about edits to your SVN repository.
(e.g. adding styling or bread-crumbs to your presentation stuff that's dynamically generated)

i.e. basically doing your workaround before you run the build, rather than doing it in the build itself.
Mar 20, 2007 at 4:05 PM
Hmmm, yes that's a good idea, thanks!