0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

【原因不明】WSLの一部ディストリビューションで規定のターミナルが開かない

Posted at

環境

Windows 11 Pro 23H2
WSL Ubuntu 22.04
WSL バージョン: 2.4.13.0
カーネル バージョン: 5.15.167.4-1
VSCode version 1.86.2

症状

WSLでターミナルの初期ディレクトリを指定するには、こちらの記事

で書かれているようにterminal.integrated.cwdで以下のように設定する。

"terminal.integrated.cwd": "/home/username/aaa"

ワークスペースのルートディレクトリなら以下のようになるはず。

"terminal.integrated.cwd": "${workspaceFolder}"

が、Ubuntuディストリビューションで実施したところ、両者ともにユーザーのホームディレクトリ~/からのままになってしまった。

自分の環境でよく使うUbuntu-22.04ディストリビューションでは、そもそもデフォルトでワークスペースのルートディレクトリがターミナルの規定になっていたので意識していなかった。

色々調べたけど問題解決はしなかったが、同じところでまた躓きそうなのでメモ。

0
0
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
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?