If you are an Ubuntu user and facing locale.Error: unsupported locale setting
. Then type the below command to fix the issue.
export LC_ALL="en_US.UTF-8"
export LC_CTYPE="en_US.UTF-8"
sudo dpkg-reconfigure locales
After typing above command , a pop up will open , select All locales and click enter.
And then another pop will open and select en_US.UTF-8 and then press enter.
Note the above settings will stop working after closing the current session. To make it permanent, follow the below instructions.
-
Open the bashrc file by typing the below command.
nano ~/.bashrc
-
And copy the below lines to the end of a file.
export LC_ALL="en_US.UTF-8"
export LC_CTYPE="en_US.UTF-8"
sudo dpkg-reconfigure locales
-
Save the file by pressing
ctrl+x
and typey
and enter. -
Then run the following command in terminal.
source ~/.bashrc