. (, dir Cmd.exe) .
PowerShell Format (. 4). , ( ).
4. PowerShell
Format-Table | , ( ). |
Format-List | , . |
Format-Custom | (view) |
Format-Wide | , |
, Format , , . , Get-Service (Status, Name DisplayName):
PS C:\> Get-Service Status Name DisplayName------ ---- -----------Stopped Alerter Running ALG Stopped AppMgmt Stopped aspnet_state ASP.NET State ServiceRunning Ati HotKey Poller Ati HotKey PollerRunning AudioSrv Windows AudioRunning BITS ...Running Browser Stopped cisvc Stopped ClipSrv Stopped clr_optimizatio....NET Runtime Optimization Service v...Stopped COMSysApp COM+Running CryptSvc Running DcomLaunch DCOMRunning Dhcp DHCP-...Format. , Format-List:
PS C:\> Get-Service | Format-List Name: AlerterDisplayName: Status : StoppedDependentServices: {}ServicesDependedOn: {LanmanWorkstation}CanPauseAndContinue: FalseCanShutdown: FalseCanStop: FalseServiceType: Win32ShareProcess Name: ALGDisplayName: Status: RunningDependentServices: {}ServicesDependedOn: {}CanPauseAndContinue: FalseCanShutdown: FalseCanStop: TrueServiceType: Win32OwnProcess..., ( ). , Format-List . , Get-Service, Format-Table, , , .
Format-List Format-Table , (, , , Get-Member). :
PS C:\> Get-Service | Format-List Name, Status, CanStop Name: AlerterStatus: StoppedCanStop: False Name: ALGStatus: RunningCanStop: True Name: AppMgmtStatus: StoppedCanStop: False...*, :
PS C:\> Get-Service | Format-table *