Answer the question
In order to leave comments, you need to log in
Why is file information not displayed in the Get-ChildItem cmdlet?
Hey!
Question such: Delivered PS7.0. Everything is fine, but when executing the dir command (aka Get-ChildItem ) via invoke-command, the output of information is somewhat discouraging (see screenshot). How would the number of files he sees.
Moreover, if you run the command locally on the PC, everything is OK. PS5.1 also executes the same code normally. Run as admin of course.
Separately, in the ps7 utility, the same thing. This is not a problem with VS code, as we managed to find out in a practical way.
The nuance is that if you enter the -Name key, then it will display the file names separately.
Gentlemen and ladies! Can you please explain in ps7.0 that something has changed in this regard? Change display order via invoke-command? I've tried googling but haven't found an answer yet.
Answer the question
In order to leave comments, you need to log in
This is just an assumption, but apparently you have 5.1 on another computer
And the display format has changed slightly between 5.1 and 7,
Get-ChildItem C:\ | Select-Object Mode, LastWriteTime, Length, Name
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question