none
Any default variable in PS holding result of a console command (for when I too often forget to say '$myVar =' before MyLongRunningCmd) ? RRS feed

  • Question

  • At the PS prompt, I issued the following command:

    Get-ChildItem \\Somename\shared\folder\folder  -Recurse

    Is Powershell storing my (object) result in some default temp variable (even though the result was ultimately pipelined to the screen)  when I forget to store the result in a var?

    or

    am I out of luck and must do this:

    $myvar = Get-ChildItem \\Somename\shared\folder\folder  -Recurse

    thus, re issuing the same command again although I did realise, after waiting quite a bit of time, that I forgot to store the result ?

    Am using V 2.0


    Tuesday, May 6, 2014 7:56 PM

Answers

All replies