11

Please help me to change default language in midnight commander from ru to en, now, to start mc in english i have to write LANG=en_EN.UTF-8 mc in terminal, but it's too long, i want mc in english by mc ty:)

4 Answers 4

17

From ru.stackoverflow.com in russian

Try to make alias like:

alias mc='LANG=en_EN.UTF-8 mc'

Author says not a best way, but helped

Also you need source ~./bashrc or logout to apply changes

2
  • 2
    It's always a good idea to append $* at the end of an alias, i.e. — alias mc='LANG=en_EN.UTF-8 mc $*' in case you want to pass the arguments to the process, then it will still work as expected for example when you call mc ~/bin.
    – ccpizza
    Jan 10, 2017 at 11:43
  • 2
    @ccpizza No need for that $*, aliases forward the arguments anyway. And even if they didn't, "$@" (double quotes and dollar-at) would be the only correct way of forwarding them even in presence of embedded spaces.
    – egmont
    Dec 1, 2017 at 19:42
12

I stumbled over this thread trying to change my Midnight Commander on macOS Sierra away from French and since macOS is unix and since using an alias did not really suit me, this is what I added to my ~/.bashrc:

export LANG="en_EN.UTF-8"

then I sourced .bashrc and all was well (i.e. ran source ~/.bashrc in the terminal).

Please note that this might affect other applications as well. But I have not discovered any - in any case that is exactly what I want. Further note that I have only tested this on a mac, yet it should work just as well on Ubuntu or other *nix's.

0

This is good answer, yet there's no clear reason why MC uses other than English in my case. I noticed it happens whenever I have another language in Systems Preferences -> Language & Region -> Preferred languages, even if English is set to Primary.

0

The simplest solution I have found is to just rename or remove the locale-directory in the Midnight Commander installation directory. This makes MC fallback to English by default. At least on my installation of MC on Windows 11.

For example, exit Midnight Commander, rename "C:\Program Files (x86)\Midnight Commander\locale" to "C:\Program Files (x86)\Midnight Commander\locale_renamed_to_get_english_by_default" and then start Midnight Commander again. It should now run with the default English locale.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.