excludedFiles

Jun 3, 2011 at 12:52 PM

hi all,

when i set excludedFiles to "~" in order to exclude temporary files, no file is beeing checked at all.

Does anyone have the same behaviour? Any hints appreciated.

bye,

yb

 

Jun 3, 2011 at 1:31 PM

hi all,

i have found a bug in file 'BuildCopEngine.cs'. The method GetBuildFiles() adds globally excluded files information to the excluded list by adding a semicolone first.

If however the field is empty, the exclusion information starts with a semicolone which is wrong. Have a look at the code:



string excludedFiles = pathConfiguration.ExcludedFiles;
 if (!string.IsNullOrEmpty(buildFilesConfiguration.ExcludedFiles)) 
 {
 // Append the globally excluded files.
  excludedFiles += ExclusionSeparator + buildFilesConfiguration.ExcludedFiles;
 }
I have changed the code like this:
string excludedFiles = pathConfiguration.ExcludedFiles;
                if (!string.IsNullOrEmpty(buildFilesConfiguration.ExcludedFiles))
                {
                    // Append the globally excluded files.
                    if (excludedFiles.Equals(String.Empty))
                    {
                        excludedFiles += buildFilesConfiguration.ExcludedFiles;
                    }
                    else
                    {
                        excludedFiles += ExclusionSeparator + buildFilesConfiguration.ExcludedFiles;
                    }
                }

 When now i run the console program, the temp-files are excluded and any other file is getting checked.

 

bye,

 

yb

 

 

Coordinator
Jun 20, 2011 at 10:53 AM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.