- There is a difference in Ruby versions between WSL2 Ubuntu and when executed in VSCode. ubuntu terminal: ruby -v result vscode: ruby -v result
In 'type -a ruby', asdf is reflected in VSCode but not in Ubuntu. ubuntu terminal vscode
Also, asdf is installed, but it only works in VSCode. When 'asdf' is entered in the terminal Ubuntu, it does not work.
Ubuntu text color issue Normally it should appear like this: color
But when restarting Ubuntu, it turns black and white: ubuntu terminal
However, there is a solution to this. By following the steps up to the second point in this document GoRails Setup for Ubuntu 22.04, the color issue in Ubuntu and the 'ruby -v' issue are resolved.
sudo apt-get update
sudo apt-get install git-core zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev software-properties-common libffi-dev
cd
git clone https://github.com/excid3/asdf.git ~/.asdf
echo '. "$HOME/.asdf/asdf.sh"' >> ~/.bashrc
echo '. "$HOME/.asdf/completions/asdf.bash"' >> ~/.bashrc
echo 'legacy_version_file = yes' >> ~/.asdfrc
echo 'export EDITOR="code --wait"' >> ~/.bashrc
exec $SHELL
However, after restarting, the settings reset, and I have to repeat the process mentioned above. What could be the problem?
The .bash_profile file does not contain any content.