文書の過去の版を表示しています。
Get-ExecutionPolicy/Set-ExecutionPolicy
コンピューターの PowerShell 実行ポリシーを取得/設定する。
動作: Windows/Linux
Windows
PS > Get-ExecutionPolicy RemoteSigned PS > Get-ExecutionPolicy -List Scope ExecutionPolicy ----- --------------- MachinePolicy Undefined UserPolicy Undefined Process Undefined CurrentUser Undefined LocalMachine RemoteSigned
Linux
PS > Get-ExecutionPolicy Unrestricted PS > Get-ExecutionPolicy -List Scope ExecutionPolicy ----- --------------- MachinePolicy Unrestricted UserPolicy Unrestricted Process Unrestricted CurrentUser Unrestricted LocalMachine Unrestricted
Windows
PS > Set-ExecutionPolicy RemoteSigned
or
PS > Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope LocalMachine
Linux
PS > Set-ExecutionPolicy RemoteSigned Set-ExecutionPolicy: Operation is not supported on this platform.