While trying to vs code in wsl 2 Debian, I found this: $ code .
$ -bash: code: command not found To solve this problem, simply add a soft link to /usr/local/bin. sudo ln -s /mnt/c/Users/{replace with your username}/AppData/Local/Programs/Microsoft\ VS\ Code/bin/code /usr/local/bin/code That’s it!