title: DSC, compiling a ps1 file into MOF
body: <p>I'm trying to configure a target node via DSC.<br>
  I've created a .ps1 file with a dummy Configuration; you can see it below; it's just one of the first examples that you find in DSC sites.<br>
  Now I want to compile it into .mof file.
  I've executed:</p>
  
  <pre><code>PS C:\var\DSC\Configurations&gt; . .\localhost.ps1
  </code></pre>
  
  <p>but it does nothing. The mof file doesn't appear and no error messages are thrown. 
  What am I missing?</p>
  
  <pre><code>Configuration FileResourceDemo
  {
  Node "localhost"
  {
      File DirectoryCopy
      {
          Ensure = "Present"  # You can also set Ensure to "Absent"
          Type = "Directory" # Default is "File".
          Recurse = $true # Ensure presence of subdirectories, too
          SourcePath = "C:\Users\Public\Documents\DSCDemo\DemoSource"
          DestinationPath = "C:\Users\Public\Documents\DSCDemo\DemoDestination"    
      }
  
      Log AfterDirectoryCopy
      {
          # The message below gets written to the Microsoft-Windows-Desired  State Configuration/Analytic log
          Message = "Finished running the file resource with ID DirectoryCopy"
          DependsOn = "[File]DirectoryCopy" # This means run "DirectoryCopy"  first.
      }
  }
  } 
  </code></pre>