Powershell的内置变量
ls Variable:
Name | Value | Description |
$ | ||
? | TRUE | Status of last command |
^ | ||
args | System.Object[] | |
ConfirmPreference | High | Dictates when confirmation should be requested. Confirmation is requested when the ConfirmImpact of the operation is equal to or greater than $ConfirmPreference. If $ConfirmPreference is None, actions will only be confirmed when Confirm is specified. |
ConsoleFileName | Name of the current console file | |
DebugPreference | SilentlyContinue | Dictates the action taken when a Debug message is delivered |
Error | System.Collections.ArrayList | |
ErrorActionPreference | Continue | Dictates the action taken when an error message is delivered |
ErrorView | NormalView | Dictates the view mode to use when displaying errors |
ExecutionContext | System.Management.Automation.EngineIntrinsics | The run objects available to cmdlets |
FALSE | FALSE | Boolean False |
FormatEnumerationLimit | 4 | Dictates the limit of enumeration on formatting IEnumerable objects |
HOME | C:\Users\814072 | Folder containing the current user‘s profile |
Host | System.Management.Automation.Internal.Host.InternalHost | A reference to the host of the current runspace |
input | System.Collections.ArrayList+ArrayListEnumeratorSimple | |
MaximumAliasCount | 4096 | Maximum number of aliases allowed in a session |
MaximumDriveCount | 4096 | Maximum number of drives allowed in a session |
MaximumErrorCount | 256 | Maximum number of errors to retain in a session |
MaximumFunctionCount | 4096 | Maximum number of functions allowed in a session |
MaximumHistoryCount | 4096 | Maximum number of history objects to retain in a session |
MaximumVariableCount | 4096 | Maximum number of variables allowed in a session |
MyInvocation | System.Management.Automation.InvocationInfo | |
NestedPromptLevel | 0 | Dictates what type of prompt should be displayed for the current nesting level |
null | References to the null variable always return the null value. Assignments have no effect. | |
OutputEncoding | System.Text.DBCSCodePageEncoding | The text encoding used when piping text to a native executable file |
PID | 4800 | Current process ID |
profile | C:\Users\814072\Documents\WindowsPowerShell\Microsoft.PowerShellISE_profile.ps1 | |
ProgressPreference | Continue | Dictates the action taken when progress records are delivered |
PSBoundParameters | System.Management.Automation.PSBoundParametersDictionary | |
PSCommandPath | ||
PSCulture | zh-CN | Culture of the current Windows PowerShell session |
PSDefaultParameterValues | System.Management.Automation.DefaultParameterDictionary | Variable to hold all default <cmdlet:parameter, value> pairs |
PSEmailServer | Variable to contain the name of the email server. This can be used instead of the HostName parameter in the Send-MailMessage cmdlet. | |
PSHOME | C:\Windows\System32\WindowsPowerShell\v1.0 | Parent folder of the host application of the current runspace |
psISE | Microsoft.PowerShell.Host.ISE.ObjectModelRoot | |
PSScriptRoot | ||
PSSessionApplicationName | wsman | AppName where the remote connection will be established |
PSSessionConfigurationName | http://schemas.microsoft.com/powershell/Microsoft.PowerShell | Name of the session configuration which will be loaded on the remote computer |
PSSessionOption | System.Management.Automation.Remoting.PSSessionOption | Default session options for new remote sessions |
PSUICulture | en-US | UI culture of the current Windows PowerShell session |
psUnsupportedConsoleApplications | Microsoft.PowerShell.Host.ISE.UICollection`1[System.String] | |
PSVersionTable | System.Management.Automation.PSVersionHashTable | Version information for current Windows PowerShell session |
PWD | C:\Users\814072 | |
scriptAnalyzer | Microsoft.PowerShell.Host.ISE.ISEAddOnTool | |
scriptBrowser | Microsoft.PowerShell.Host.ISE.ISEAddOnTool | |
ShellId | Microsoft.PowerShell | The ShellID identifies the current shell. This is used by #Requires. |
StackTrace | at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy) at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share) at System.Management.Automation.PathUtils.MasterStreamOpen(PSCmdlet cmdlet, String filePath, Encoding resolvedEncoding, Boolean defaultEncoding, Boolean Append, Boolean Force, Boolean NoClobber, FileStream& fileStream, StreamWriter& streamWriter, FileInfo& readOnlyFileInfo, Boolean isLiteralPath) |
|
TRUE | TRUE | Boolean True |
VerbosePreference | SilentlyContinue | Dictates the action taken when a Verbose message is delivered |
WarningPreference | Continue | Dictates the action taken when a Warning message is delivered |
WhatIfPreference | FALSE | If true, WhatIf is considered to be enabled for all commands. |
郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。