SVN cannot set LC_CTYPE locale

后端 未结 12 2243
醉话见心
醉话见心 2021-01-30 03:39

I started getting the following error whenever i use SVN in my server:

svn: warning: cannot set LC_CTYPE locale
svn: warning: environment variable LC_CTYPE is UT         


        
相关标签:
12条回答
  • 2021-01-30 04:28

    Adding just one more option that worked for me on a RHEL6 system.

    /etc/sysconfig/i18n contained LANG="en_US.UTF-8" but locale -a | grep -i en_us showed en_US.utf8.

    After updating /etc/sysconfig/i18n to match the output of locale -a the problem was resolved.

    0 讨论(0)
  • 2021-01-30 04:30

    On Debian Jessie:

    I ran:

    sudo dpkg-reconfigure locales
    

    Added and installed the missing locale. Then it worked.

    0 讨论(0)
  • 2021-01-30 04:33

    Check the output of

    locale -a
    

    If the locale that SVN is complaining about isn't installed, then you can install it.

    You might need to do:

    sudo apt-get install language-pack-en-base
    

    followed by one of (depending on the exact error from SVN, yours is the first case):

    sudo locale-gen UTF-8
    sudo locale-gen en_GB.UTF-8
    sudo locale-gen en_US.UTF-8
    

    Alternatively as Ankit writes in his answer:

    export LC_ALL=C
    

    may work (in your current session, or in your .profile).

    0 讨论(0)
  • 2021-01-30 04:33

    This is caused by not having the proper locales generated on your system.

    Uncommented lines that you want to support in /etc/locale.gen

    For example:

    en_GB.UTF-8 UTF-8
    en_US.UTF-8 UTF-8
    ru_RU.UTF-8 UTF-8
    

    and then run sudo locale-gen

    0 讨论(0)
  • 2021-01-30 04:34

    For iTerm2:

    Profiles → Open Profiles… → Edit Profiles… → Terminal → Unckeck Set locale variables automatically

    0 讨论(0)
  • 2021-01-30 04:37

    We had this problem in our company as well, when using IntelliJ. A colleague of mine just fixed it.

    For us the problem was the line SendEnv LANG LC_* in /etc/ssh/ssh_config. When I commented out that line, everything worked fine.

    0 讨论(0)
提交回复
热议问题