• 使用以下指令
    • PS C:\> cd env:
    • PS Env:\> ls
      • Path
        TEMP
        SESSIONNAME
        PATHEXT
        USERDOMAIN
        PROCESSOR_ARCHITECTURE
        SystemDrive
        APPDATA
        windir
        LIB
        TMP
        USERPROFILE
        ProgramFiles
        FP_NO_HOST_CHECK
        HOMEPATH
        COMPUTERNAME
        VS71COMNTOOLS
        RUBYOPT
        NUMBER_OF_PROCESSORS
        PROCESSOR_IDENTIFIER
        USERNAME
        INCLUDE
        ComSpec
        LOGONSERVER
        CommonProgramFiles
        SystemRoot
        PROCESSOR_LEVEL
        PROCESSOR_REVISION
        ALLUSERSPROFILE
        OS
        HOMEDRIVE
  • 讀取變數
    • $env:變數名
      • $env:Path,$env:OS,$env:ComSpec 等等
創作者介紹

PowerShell@HungYuWu

ayowu 發表在 痞客邦 PIXNET 留言(0) 人氣()