简体   繁体   中英

Open Visual Studio (Not Visual Studio Code) from the ubuntu bash terminal on windows

I was wondering if it is possible to open Visual Studio (Not Visual Studio Code) from the ubuntu bash terminal on windows .

Opening Visual Studio Code just works fine but I couldn't find a way on how I could actually open Visual Studio from the command line.

Thank you in advance!

It is possible to refer to anything in the Windows file system from inside WSL. However, understand that, since Visual Studio is a Windows exclusive application, it will run in the context of your host Windows OS, not the Ubuntu guest OS. By contrast, Visual Studio Code is a Linux-native application; so it can run in either context.

Try this:

’/mnt/c/Windows/System32/cmd.exe /c “/mnt/c/Program Files (x86)/Microsoft Visual Studio/2019/Community/Common7/IDE/devenv.exe”'

If this works, you can save the command as an alias in your .bashrc

References:

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM