title: Whitespace and truncation with ellipsis on Select-Object
body: <p>I'm trying to figure out why <code>Select-Object</code></p>
  
  <ol>
  <li>adds a lot of whitespace at the start of its output; and</li>
  <li>truncates long properties with ellipsis.</li>
  </ol>
  
  <p>Here's a repro of what I mean. Suppose you run these commands on <code>C:\</code>:</p>
  
  <pre><code>New-Item "MyTest" -Type Directory
  </code></pre>
  
  
  
  <pre><code>cd MyTest
  </code></pre>
  
  
  
  <pre><code>"Some very long lorem ipsum like text going into a certain file, bla bla bla and some more bla." | Out-File test.txt
  </code></pre>
  
  
  
  <pre><code>Get-ChildItem | Select-String "text" | Select-Object LineNumber,Line
  </code></pre>
  
  <p>This will show output like this:</p>
  
  <p><img src="https://i.stack.imgur.com/rEAIH.png" alt="Select-Object output"></p>
  
  <p>The ellipsis I can understand, that would be just the way the command ends up getting formatted when the result is written to the console host. However, the whitespace at the start still confuses me in this case.</p>
  
  <p>Things get weirder for me though when I pipe the result to either <code>clip</code> or <code>Out-File output.txt</code>. I get similarly formatted output, with a lot of whitespace at the start and truncated <code>Line</code> properties.</p>
  
  <p>Which command is causing this behavior, and how can I <em>properly</em> solve this? Most importantly: how can I get the <em>full</em> results into a file or onto my clipboard?</p>