Click here to Skip to main content
15,886,806 members
Articles / Programming Languages / C#

Visual Studio Cleaner and More

Rate me:
Please Sign up or sign in to vote.
4.86/5 (17 votes)
18 Dec 2011CPOL7 min read 60.9K   2.4K   55  
Delete junk files from Visual Studio solution/project by selecting files using search patterns
<?xml version="1.0" encoding="utf-8"?>
<root>
  <!-- 
    Microsoft ResX Schema 
    
    Version 2.0
    
    The primary goals of this format is to allow a simple XML format 
    that is mostly human readable. The generation and parsing of the 
    various data types are done through the TypeConverter classes 
    associated with the data types.
    
    Example:
    
    ... ado.net/XML headers & schema ...
    <resheader name="resmimetype">text/microsoft-resx</resheader>
    <resheader name="version">2.0</resheader>
    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
        <value>[base64 mime encoded serialized .NET Framework object]</value>
    </data>
    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
        <comment>This is a comment</comment>
    </data>
                
    There are any number of "resheader" rows that contain simple 
    name/value pairs.
    
    Each data row contains a name, and value. The row also contains a 
    type or mimetype. Type corresponds to a .NET class that support 
    text/value conversion through the TypeConverter architecture. 
    Classes that don't support this are serialized and stored with the 
    mimetype set.
    
    The mimetype is used for serialized objects, and tells the 
    ResXResourceReader how to depersist the object. This is currently not 
    extensible. For a given mimetype the value must be set accordingly:
    
    Note - application/x-microsoft.net.object.binary.base64 is the format 
    that the ResXResourceWriter will generate, however the reader can 
    read any of the formats listed below.
    
    mimetype: application/x-microsoft.net.object.binary.base64
    value   : The object must be serialized with 
            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
            : and then encoded with base64 encoding.
    
    mimetype: application/x-microsoft.net.object.soap.base64
    value   : The object must be serialized with 
            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
            : and then encoded with base64 encoding.

    mimetype: application/x-microsoft.net.object.bytearray.base64
    value   : The object must be serialized into a byte array 
            : using a System.ComponentModel.TypeConverter
            : and then encoded with base64 encoding.
    -->
  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
    <xsd:element name="root" msdata:IsDataSet="true">
      <xsd:complexType>
        <xsd:choice maxOccurs="unbounded">
          <xsd:element name="metadata">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element name="value" type="xsd:string" minOccurs="0" />
              </xsd:sequence>
              <xsd:attribute name="name" use="required" type="xsd:string" />
              <xsd:attribute name="type" type="xsd:string" />
              <xsd:attribute name="mimetype" type="xsd:string" />
              <xsd:attribute ref="xml:space" />
            </xsd:complexType>
          </xsd:element>
          <xsd:element name="assembly">
            <xsd:complexType>
              <xsd:attribute name="alias" type="xsd:string" />
              <xsd:attribute name="name" type="xsd:string" />
            </xsd:complexType>
          </xsd:element>
          <xsd:element name="data">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
              </xsd:sequence>
              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
              <xsd:attribute ref="xml:space" />
            </xsd:complexType>
          </xsd:element>
          <xsd:element name="resheader">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
              </xsd:sequence>
              <xsd:attribute name="name" type="xsd:string" use="required" />
            </xsd:complexType>
          </xsd:element>
        </xsd:choice>
      </xsd:complexType>
    </xsd:element>
  </xsd:schema>
  <resheader name="resmimetype">
    <value>text/microsoft-resx</value>
  </resheader>
  <resheader name="version">
    <value>2.0</value>
  </resheader>
  <resheader name="reader">
    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>
  <resheader name="writer">
    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>
  <data name="helpTextBox.Text" xml:space="preserve">
    <value>Filters are patterns used to select directories and files.

Filters fall into four categories:
1.	Directory names
2.	File extensions, matches files
3.	Wildcard, matches directories and files
4.            Exclude files or directories

Directory filters must end in a back slash. Example:   debug\ 
Directory filters only match on directory names and cause the directory and all
of its subdirectories to be selected.

File extension must start with a decimal point. Example:   .obj
File extension filter only matches on files.

Wildcard is a collection of characters with one or more wildcard characters *. 
Wildcard can appear multiple times.
	*   matches zero or more characters.
	
	Example:  Connect*.xml
	Example:  *foo*bar.*	

The wildcard filter is tested against the fulll file or directory path so it is common for 
all wildcard patterns to start with * to match on any prefix of disk drive letters and 
subdirectories.

	Example
	Pattern	               Test Against                             Results
	--------------------           ----------------------------------              ----------
	foo*                         foobarcar                                match
	foo*                         carbarfoo                                no match
	*foo                         carbarfoo                                match
	*foo\bin\*                foo\junk	                               no match
	*foo\bin\*                foo\bin\	                               match
	*foo\bin\*                foo\bin\car.exe                      match
	*\bin\*.obj               c:\foo\bar\bin\car.obj            match
	*\bin\*.o*                c:\foo\bar\bin\car.old           match
	*\bin\*.o*                d:\bin\junk.obj                       match

A filter can contain one or more filters separated by semicolons.
Example:    Connect*.xml;.obj;obj\

The exclude filter is evaulated last and only for matches in the current filter.
Exclude filter starts with a minus sign, but the minus sign.
     	Example:	   *\bin\*;-*.exe
The above example will match on the directory "bin" and all of its subdirectories and files.
The exclude pattern will exclude all files with extension ".exe" from the matched files.
NOTE:  the exclude only works on File and Wildcard filters and not simple Directory name filters.
The following will not work because the members of bin directory are not tested individually.
	Example:	    bin\;-*.exe

Special Global Exclude Filter:
  If one or more exclude filters have their Filter name set to 'never', they are always evaluated
  to prevent files  from being located.

  Example:
	 Filter 	Details	Description
	--------	--------	-------------	
	never	*.exe	Don't remove executables


Use Add and Delete buttons to manage your collection of filter rules.
Double click on a row to change its value.
Right click if you wan to Export the filter rules as CSV

Bookmarks:

Use the bookmarks to memorize a set of filter rule checkmark states and Path setting.
Use the bookmark Add button to add a new bookmark to remember the current settings. 
Double Click on a bookmark to activate its settings.
Press the 'Set' button to refresh the current state of a bookmark to the current list of 
active filter rules and Path.

Keep folder search path empty when you set a bookmark if you want its application to be applied to an existing path. </value>
  </data>
</root>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer (Senior) IBM / WSI
United States United States
I love C/C++ for its speed and power and C#/Visual Studio for quick application development.

Unix/Linux is my favorite OS

Android Studio is the best IDE I have used.

Comments and Discussions