Avoid error with "locale-check" on Debian 20.04

Brisbane Web Developer - Dec 29 '20 - - Dev Community

Summary

  • Noticed I get the error -bash: /usr/bin/locale-check: No such file or directory every time I become root via sudo su - ay my Debian 20.04 Server.

The Amendment

  • The error seems to be from the file /etc/profile.d/01-locale-fix.sh and there is no package having the file for Debian 20.04 (Ubuntu does).

  • So regardless the file is going to be added to the package base-files or I need to install another package, I decided to avoid the error in the way it starts working whenever the file is added to the server.

/etc/profile.d/01-locale-fix.sh
==========
# Make sure the locale variables are set to valid values.
# Hack: Added "if" statement because Debian 20.04 does not seem
# to have the file "/usr/bin/locale-check"
if [ -f "/usr/bin/locale-check" ];
then
    eval $(/usr/bin/locale-check C.UTF-8)
fi
Enter fullscreen mode Exit fullscreen mode
. . . . . . . . . . . . . . . . . . . . . . . . . .
Terabox Video Player