PowerShell でオブジェクトに列を追加するにはどうすればよいですか?
たとえば、Get-Childitem は、Mode、LastWriteTime、Length Name などのオブジェクトを返します。このオブジェクトを、LastWriteTime から計算される追加の列で拡張したいと考えています。
これは元の Get-Childitem 出力です。
Mode LastWriteTime Length Name
---- ------------- ------ ----
-a--- 2012.12.15. 17:02 5390 Log_20121215.txt
-a--- 2013.01.02. 17:10 14014 Log_20130102.txt
-a--- 2013.01.07. 17:08 2200 Log_20130107.txt
そして、私はこの出力が欲しい:
Mode LastWriteTime Length Name ComputedColumn
---- ------------- ------ ---- --------------
-a--- 2012.12.15. 17:02 5390 Telenor_Log_20121215.txt 20131215
-a--- 2013.01.02. 17:10 14014 Telenor_Log_20130102.txt 20140102
-a--- 2013.01.07. 17:08 2200 Telenor_Log_20130107.txt 20140207
助けてくれてありがとう。