LoginSignup
2
4

More than 5 years have passed since last update.

Bash on Ubuntu on Windows から VS Code を「普通に」使う

Last updated at Posted at 2017-09-07

Bash on Ubuntu on Windows から、VSCode を

$ code my/suggoi/iketeru.ts aitsu-no/yabai.ts

みたいに相対パス付きで立ち上げるのが、いろいろめんどくさかったのでメモ。

環境は Windows 10 Pro Insider Preview Build 16199 / $ uname -a
Linux PC201404-001 4.4.0-43-Microsoft #1-Microsoft Wed Dec 31 14:42:53 PST 2014 x86_64 x86_64 x86_64 GNU/Linux
/ VS Code 64bit 1.16.0-insider。他の組み合わせは知らん。

  1. bash に wslpath (cygpath みたいなやつ) を入れる: https://gist.github.com/ntabee/d7af5686dc4a99fda5a77b4ef081b102 ←を /usr/local/bin かなんかに置いて chmod a+x すべし。
  2. VS Code の bin に起動用シェルスクリプトを入れる: https://gist.github.com/ntabee/5c2e655edce1c59d76d885868031cf5d ←を C:\Program Files\Microsoft VS Code Insiders\bin に置いて chmod a+x すべし。

やってることは、.exe や引数のパス名を Windows ネイティブの形に変換して powershell に渡す、それだけ。

2
4
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
2
4