title: How to make a batch file that writes directory names to a text file
body: <p>I am trying to write a batch file that scans a directory of folders and outputs the names to a text file.</p>
  
  <p>The folder names are as follows:</p>
  
  <pre><code>    Folder Name 1 [123abc]
      Folder Name 2 [abc321]
  </code></pre>
  
  <p>I'm needing the the folder names deleted leaving only the brackets and whats in between them listed out to a new.txt</p>
  
  <p>Like this:</p>
  
  <pre><code>    [123abc]
      [abc321]
  </code></pre>