title: PowerShell how to add a custom common parameter?
body: <p>I would like to make a custom -Force switch a common parameter.</p>
  
  <p>I have three functions that each take the parameter.</p>
  
  <p>function A calls function B, function B calls function C</p>
  
  <p>I would like to call function A with the custom -Force parameter and have it propagate as a common parameter, without having to do something like this:</p>
  
  <pre><code>function B() {
  
      [cmdletbinding()]
  
      param([switch] $Force)   
  
      # NOTE: THIS CHECK IS THE PART I WANT TO ELIMINATE
      # I WANT -Force TO BE PASSED ALONG AS A COMMON PARAMETER
      if ($Force) {
          C -Force
      }
      else {
          C
      }
  
  }
  </code></pre>