2009-05-09

powershellのps1ファイルの関連づけ

最近仕事でpowershellを使う機会が多いのでメモメモ

・ps1拡張子をダブルクリックで実行
以下コマンドをpowershell上で実行する
New-Item registry::HKEY_CLASSES_ROOT\Microsoft.PowerShellScript.1\shell\open\command -value '"C:\Windows\system32\WindowsPowerShell\v1.0\powershell.exe" "& ''%1''"' -force

・リンク
Windows PowerShell シェル・スクリプト・プログラミング

No comments: