You are not logged in.
Hello, i have been having this issue on both my laptop and my desktop pc, it's an issue with tmux and it not having the right locale although i have selected the right locale.
Starting server...tmux: need UTF-8 locale (LC_CTYPE) but have ANSI_X3.4-1968
-
locale -a
C
POSIX
en_GB.utf8
-
locale-gen
Generating locales...
en_GB.UTF-8... done
Generation complete.Offline
What does `locale` return?
Offline
locale
LANG=C
LC_CTYPE="C"
LC_NUMERIC="C"
LC_TIME="C"
LC_COLLATE="C"
LC_MONETARY="C"
LC_MESSAGES="C"
LC_PAPER="C"
LC_NAME="C"
LC_ADDRESS="C"
LC_TELEPHONE="C"
LC_MEASUREMENT="C"
LC_IDENTIFICATION="C"
LC_ALL=Offline
So that's your problem, you generated the locale, but didn't set it. What's in /etc/locale.conf?
Offline
cat /etc/locale.conf
LANG=en_GB.UTF-8Offline
Then you've likely got something overriding it later. How are you logging in? What WM/DE?
Offline
yeah that might be the issue, i use dwm and login through startx and have this option on .xinitrc
#Keyboard Layout
setxkbmap gb &Offline
So you log in at a tty, you start your graphical session with startx.
What shell? Before you startx, is `locale` the same? You can log into a second tty to check that.
Offline
i use the zsh shell in tty and my terminal, this is the output of locale in the tty
LANG=en_GB.UTF-8
LC_CTYPE="en_GB.UTF-8"
LC_NUMERIC="en_GB.UTF-8"
LC_TIME="en_GB.UTF-8"
LC_COLLATE="en_GB.UTF-8"
LC_MONETARY="en_GB.UTF-8"
LC_MESSAGES="en_GB.UTF-8"
LC_PAPER="en_GB.UTF-8"
LC_NAME="en_GB.UTF-8"
LC_ADDRESS="en_GB.UTF-8"
LC_TELEPHONE="en_GB.UTF-8"
LC_MEASUREMENT="en_GB.UTF-8"
LC_IDENTIFICATION="en_GB.UTF-8"
LC_ALL=Offline
So your problem is later. setxkbmap wouldn't do this, what else is in .xinitrc? Does dwm have any startup scripts? What terminal emulator?
Offline
what else is in .xinitrc?
#!/bin/sh
while true; do
xsetroot -name " Linux $(uname -r) | $(top -bn1 | grep Cpu | awk '{print $2}')% | $(free --mebi | sed -n '2{p;q}' | awk '{printf ("%2.2fGiB/%2.2fGiB\n", ( $3 / 1024), ($2 / 1024))}') | pac $(pacman -Qu | grep -Fcv "[ignored]") | weather $(curl -s "wttr.in/*?format=1" | grep -o ".[0-9].*") | $(cat /sys/class/power_supply/BAT0/status): $(cat /sys/class/power_supply/BAT0/capacity)% | $(date +"%H:%M") • $(date +"%a %d/%m/%Y")"
sleep 5s
done &
# Programs to open on startup
flameshot &
unclutter &
dunst &
clipmenud &
redshift -l 53.480759:-2.242631 &
#Keyboard Layout
setxkbmap gb &
#Set background
feh --bg-center /home/*/.local/share/background_2.png &
exec dwmDoes dwm have any startup scripts?
no
What terminal emulator?
st
Offline
ok i fixed it on my laptop (the /etc/locale.conf fixed it) but it is still different on my desktop pc.
locale
LANG=
LC_CTYPE="POSIX"
LC_NUMERIC="POSIX"
LC_TIME="POSIX"
LC_COLLATE="POSIX"
LC_MONETARY="POSIX"
LC_MESSAGES="POSIX"
LC_PAPER="POSIX"
LC_NAME="POSIX"
LC_ADDRESS="POSIX"
LC_TELEPHONE="POSIX"
LC_MEASUREMENT="POSIX"
LC_IDENTIFICATION="POSIX"
LC_ALL=This is the same for the tty as well which uses zsh.
Offline
If you aren't using OMZ, post your .zprofile and .zshenv files.
Offline
don't have a zprofile file but this is my zshenv
export ZDOTDIR=~/.config/zsh
export HISTFILE=~/.local/share/zsh/history
# Ensure that a non-login, non-interactive shell has a defined environment.
if [[ ( "$SHLVL" -eq 1 && ! -o LOGIN ) && -s "${ZDOTDIR:-$HOME}/.zprofile" ]]; then
source "${ZDOTDIR:-$HOME}/.zprofile"
fiOffline
If you don't have a zprofile, why is it sourced?
Offline
the /etc/locale.conf fixed it
…
localectl
locale -a
localeSince $LANG is empty on the desktop "locale" output it's pretty much guaranteed that you don't have a properly configured locale.conf there either…
The video tutorial you follow to install arch forgets to mention https://wiki.archlinux.org/title/Locale
Online