LoginSignup
0
0

More than 1 year has passed since last update.

powershellから「リンク先」におけるオプションを指定する方法

Posted at

.ps1ファイルのショートカットを作成し、「リンク先」に

powershell -ExecutionPolicy ByPass

などと書き込むことで実行ファイル化している方は多いと思います。

ps1ファイルから別のps1ファイル及びそのショートカットを作成して、リンク先を編集する操作を行ったのですが、情報が少なかったため共有します。

上記参考です。

$Shortcut.TargetPath = "powershell"
$Shortcut.Arguments = "-ExecutionPolicy ByPass C:(以下ps1ファイルのpath)"

などとすることでオプションを指定することができます。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0