MonoDevelop.Projects.Project.DeleteSupportFiles C# (CSharp) Method

DeleteSupportFiles() public method

Removes all support files from the output directory
Deletes all support files from the output directory of the given configuration. Support files include: assembly references with the Local Copy flag, data files with the Copy to Output option, etc.
public DeleteSupportFiles ( IProgressMonitor monitor, MonoDevelop.Projects.ConfigurationSelector configuration ) : void
monitor IProgressMonitor /// Progress monitor. ///
configuration MonoDevelop.Projects.ConfigurationSelector /// Configuration for which to delete the files. ///
return void
		public void DeleteSupportFiles (IProgressMonitor monitor, ConfigurationSelector configuration)
		{
			ProjectConfiguration config = (ProjectConfiguration) GetConfiguration (configuration);

			foreach (FileCopySet.Item item in GetSupportFileList (configuration)) {
				FilePath dest = Path.Combine (config.OutputDirectory, item.Target);

				// Ignore files which were not copied
				if (Path.GetFullPath (dest) == Path.GetFullPath (item.Src))
					continue;

				try {
					dest.Delete ();
				} catch (IOException ex) {
					monitor.ReportError (GettextCatalog.GetString ("Error deleting support file '{0}'.", dest), ex);
				}
			}
		}