Powershell

Powershellファイルをクリックで実行する方法

Windows上のコマンドライン、Powershellファイルをクリックで実行する方法方法について紹介します。

Shou Arisaka
1 分で読める
2019年8月22日

Windows上のコマンドライン、Powershellファイルをクリックで実行する方法方法について紹介します。

こういうショートカットファイルを作るか

C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -ExecutionPolicy RemoteSigned -File C:\startup\open_folders.ps1

こういうバッチファイルを作る。

@echo off
start /d . powershell -NoProfile -ExecutionPolicy Unrestricted .\open_folders.ps1
exit

この記事をシェア

Shou Arisaka 2019年8月22日

🔗 リンクをコピー