差分
このページの2つのバージョン間の差分を表示します。
次のリビジョン | 前のリビジョン | ||
windows:powershell:commands:get-execution_policy [2020/05/29 13:50] – 作成 ともやん | windows:powershell:commands:get-execution_policy [2020/09/11 19:07] (現在) – ともやん | ||
---|---|---|---|
行 1: | 行 1: | ||
- | ====== Get-ExecutionPolicy/ | + | ====== Get-ExecutionPolicy / Set-ExecutionPolicy ====== |
コンピューターの PowerShell 実行ポリシーを取得/ | コンピューターの PowerShell 実行ポリシーを取得/ | ||
**動作: Windows/ | **動作: Windows/ | ||
- | \\ | + | |
===== Get-ExecutionPolicy ===== | ===== Get-ExecutionPolicy ===== | ||
**Windows**\\ | **Windows**\\ | ||
+ | <WRAP prewrap 100%> | ||
+ | <code powershell> | ||
+ | $ Get-ExecutionPolicy | ||
+ | </ | ||
+ | </ | ||
+ | <WRAP prewrap 100% #result> | ||
<code powershell> | <code powershell> | ||
- | PS > Get-ExecutionPolicy | ||
RemoteSigned | RemoteSigned | ||
+ | </ | ||
+ | </ | ||
- | PS > Get-ExecutionPolicy -List | + | <WRAP prewrap 100%> |
+ | <code powershell> | ||
+ | $ Get-ExecutionPolicy -List | ||
+ | </ | ||
+ | </ | ||
+ | <WRAP prewrap 100% # | ||
+ | <code powershell> | ||
Scope ExecutionPolicy | Scope ExecutionPolicy | ||
行 19: | 行 32: | ||
| | ||
</ | </ | ||
+ | </ | ||
**Linux**\\ | **Linux**\\ | ||
+ | <WRAP prewrap 100%> | ||
+ | <code powershell> | ||
+ | $ Get-ExecutionPolicy | ||
+ | </ | ||
+ | </ | ||
+ | <WRAP prewrap 100% #result> | ||
<code powershell> | <code powershell> | ||
- | PS > Get-ExecutionPolicy | ||
Unrestricted | Unrestricted | ||
- | PS > Get-ExecutionPolicy -List | + | </code> |
+ | </ | ||
+ | |||
+ | <WRAP prewrap 100%> | ||
+ | <code powershell> | ||
+ | $ Get-ExecutionPolicy -List | ||
+ | </ | ||
+ | </ | ||
+ | <WRAP prewrap 100% # | ||
+ | <code powershell> | ||
Scope ExecutionPolicy | Scope ExecutionPolicy | ||
行 34: | 行 62: | ||
| | ||
</ | </ | ||
+ | </ | ||
===== Set-ExecutionPolicy ===== | ===== Set-ExecutionPolicy ===== | ||
**Windows**\\ | **Windows**\\ | ||
+ | <WRAP prewrap 100%> | ||
<code powershell> | <code powershell> | ||
- | PS > Set-ExecutionPolicy RemoteSigned | + | $ Set-ExecutionPolicy RemoteSigned |
</ | </ | ||
+ | </ | ||
or | or | ||
+ | <WRAP prewrap 100%> | ||
<code powershell> | <code powershell> | ||
- | PS > Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope LocalMachine | + | $ Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope LocalMachine |
</ | </ | ||
+ | </ | ||
**Linux**\\ | **Linux**\\ | ||
+ | <WRAP prewrap 100%> | ||
+ | <code powershell> | ||
+ | $ Set-ExecutionPolicy RemoteSigned | ||
+ | </ | ||
+ | </ | ||
+ | <WRAP prewrap 100% #result> | ||
<code powershell> | <code powershell> | ||
- | PS > Set-ExecutionPolicy RemoteSigned | ||
Set-ExecutionPolicy: | Set-ExecutionPolicy: | ||
</ | </ | ||
+ | </ | ||
===== ExecutionPolicy ===== | ===== ExecutionPolicy ===== |