micro-artwork / micro-artwork.github.io

blog
0 stars 0 forks source link

posts/dev/common/2022-07-03-how-to-add-developer-powershell/ #3

Open utterances-bot opened 10 months ago

utterances-bot commented 10 months ago

Visual Studio Code 터미널에 개발자 PowerShell 추가하기 – Yogo's blog

Yogo's life and devlog

https://opensourcehardware.io/posts/dev/common/2022-07-03-how-to-add-developer-powershell/

insaneinvader commented 10 months ago

To get rid of this ridiculous warning, use the -VsInstallationPath argument, e.g.: PowerShell -NoLogo -NoExit -File 'C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\Tools\Launch-VsDevShell.ps1' -HostArch amd64 -Arch amd64 -VsInstallationPath 'C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\Tools'

insaneinvader commented 10 months ago

To my surprise, this ridiculous warning also disappears if you use the -Latest argument, e.g.: PowerShell -NoLogo -NoExit -File 'C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\Tools\Launch-VsDevShell.ps1' -Latest -HostArch amd64 -Arch amd64

From here you will also learn that:

Installed shortcuts, like those in the Start menu, load the module and invoke the cmdlet directly. Launch-VsDevShell.ps1 is the recommended way to initialize Developer PowerShell interactively or for scripting build automation.