title: Simpler way to execute command from PowerShell prompt
body: <p>The command below only works if I execute it from a Windows legacy <strong>cmd.exe</strong> prompt exactly like this:</p>
  <pre><code>powershell.exe -command &quot;Write-Host -NoNewLine y ; sleep 2 ; Write-Host -NoNewLine y&quot; | plink.exe ...
  </code></pre>
  <p>If I want to do the same thing from a PowerShell prompt, I have to do:</p>
  <pre class="lang-PoSH prettyprint-override"><code>cmd /c powershell.exe -noprofile -command &quot;Write-Host -NoNewLine y ; sleep 1 ; Write-Host -NoNewLine y&quot; `| plink.exe ...
  </code></pre>
  <p>I'd like to know if there's a simpler &amp; more streamlined way to do the same thing from a PowerShell prompt without breaking anything.</p>