title: How do I define RequiredModules in a PowerShell module manifest (psd1)?
body: <p>I'm trying to create a simple dependency between two PowerShell modules, but I'm getting the syntax or <em>something</em> wrong. </p>
  
  <p><code>Module1.psd1</code>:</p>
  
  <pre><code>@{
      RootModule        = 'Module1.psm1'
      ModuleVersion     = '1.0'
      GUID              = '11111111-1111-1111-1111-111111111111'
      Author            = 'uw'
      FunctionsToExport = @()
      CmdletsToExport   = @()
      VariablesToExport = '*'
      AliasesToExport   = @()
  }
  </code></pre>
  
  <p><code>Module2.psd1</code>:</p>
  
  <pre><code>@{
      RootModule        = 'Module2.psm1'
      ModuleVersion     = '1.0'
      GUID              = '22222222-2222-2222-2222-222222222222'
      Author            = 'uw'
      FunctionsToExport = @()
      CmdletsToExport   = @()
      VariablesToExport = '*'
      AliasesToExport   = @()
      RequiredModules   = @(
                            @{
                              ModuleName = "Module1"; 
                              ModuleVersion = "1.0"; 
                              Guid = "11111111-1111-1111-1111-111111111111"
                             }
                           )
  }
  </code></pre>
  
  <p>The module manifest for <code>Module2</code> defines that <code>Module2</code> depends on <code>Module1</code>.</p>
  
  <p>When running <code>Test-ModuleManifest Module2.psd1</code>, I get the following error:</p>
  
  <pre><code>Test-ModuleManifest : The specified RequiredModules entry 'Module1' in the module manifest 'Module2.psd1' is invalid. 
  Try again after updating this entry with valid values.
  </code></pre>