This project has moved. For the latest updates, please go here.

How to use ExportSrc.exe ?

Open the command prompt. Then type :
ExportSrc.exe <source directory> <destination directory> [configuration file]
where
  • source directory is the path to the folder that contains the source files that must be copied
  • destination directory is the path to the folder where the source files will be copied.
Note: if the destination folder does not exist, it will be created
  • configuration file is the path to the configuration file. This parameter is optional. If not set the default configuration will be use.

For example:
  • ExportSrc.exe c:\Projects\ExportSrc c:\Save\ExportSrc
  • ExportSrc.exe c:\Projects\ExportSrc c:\Save\ExportSrc config.xml

Configuration File

<?xml version="1.0"?>
<Settings computeHash="True" removeTfsBinding="True" overrideExistingFiles="True" unprotectFiles="True" outputReadOnly="" excludeGeneratedFiles="False" keepSymbolicLinks="False" replaceLinkFiles="False">
<Filters>
<Filter type="Exclude" caseSensitive="False" applyToDirectory="False" applyToFile="True" applyToFileName="True" applyToPath="False">*.cache</Filter>
<Filter type="Include" caseSensitive="False" applyToDirectory="False" applyToFile="True" applyToFileName="True" applyToPath="False">_cf_md.config</Filter>
</Filters>
</Settings>
  • Settings
    • computeHash : Validate copied file in computing and comparing Md5 sum.
    • removeTfsBinding : Remove the TFS Binding of solution file (sln) and project files (csproj, vbproj, wixproj, vdproj, vcproj, vcxproj)
    • overrideExistingFiles : Override existing files when copying
    • unprotectFiles : Remove read-only attribute of files before overriding them
    • outputReadOnly : Set the read-only attribute of the new file. If not set the output keeps the source attribute value.
    • excludeGeneratedFiles : Do not copy generated file (*.g.cs, *.designer.cs, etc)
    • keepSymbolicLink : If set to true symbolic links will be copied as symbolic link; otherwise they are treat as normal folders.
    • replaceLinkFiles : if set to true files added as link in Visual Studio will be replace by "local" copy of files.
  • Filter
    • Content : Text that must be test against files or directories.
      • "*" match 0 or more characters.
      • "?" match one character.
    • type : Include or Exclude. If a file is in the include list and in the exclude list, it will be included. If you want to include just one dll you can use to filters: Exclude *.dll and Include dllToInclude.dll
    • caseSensitive : The filter text is case sensitive : "*.jpg" match "toto.jpg" but does not match "toto.JPG"
    • applyToDirectory : The filter applies to directories
    • applyToFile : The filter applies to files
    • applyToFileName : The filter applies to file name or directory (example: Exporter.cs)
    • applyToPath : The filter applies to file path or directory path (example: ExportSrc/Exporter.cs)

Some examples:
*.jpg matches files where extension is "jpg"
t?t?.txt matches titi.txt, toto.txt, tgtb.txt
toto.cs matches toto.cs

Last edited Jul 28, 2016 at 4:56 PM by Meziantou, version 16

Comments

No comments yet.