German keyboard layout

Hi,

in /etc/login.conf I added

Code:
german|German Users Accounts:\
    :charset=ISO-8859-15:\
    :lang=de_DE.ISO8859-15:\
    :tc=default:

and then ran

Code:
sudo cap_mkdb /etc/login.conf

/etc.rc.conf has

Code:
keymap="de"

After that I did

Code:
sudo pw user mod helmut -L german

Code:
[helmut@BSDHelmut ~]$ sudo grep helmut /etc/master.passwd
helmut:*:1001:1001:german:0:0:Helmut:/home/helmut:/usr/local/bin/bash
[helmut@BSDHelmut ~]$

Then reboot. But german umlauts are still not displayed. What did I miss?

Code:
[helmut@BSDHelmut ~]$ uname -a
FreeBSD BSDHelmut 12.2-RELEASE-p10 FreeBSD 12.2-RELEASE-p10 12803d8a9(releng/12.2) GENERIC-PF-ALTQ  amd64
[helmut@BSDHelmut ~]$

Thank you!
 
Try a to use a ~/.login_conf in your user’s home directory with the following contents
Code:
me:\
    :charset=UTF-8:\
    :setenv=LC_ALL=de_DE.UTF-8:\
    :lang=de_DE.UTF-8:

(Note the filename has an underscore, not a dot.)

And don't forget to run
Code:
cap_mkdb ~/.login_conf

If you use Xorg add this to .xinitrc:
Code:
setxkbmap de -variant nodeadkeys -model pc105

Edit: Adding users to language groups is totally new to me, never needed this.
 
If you want that system wide in 12.2 :

/etc/rc.conf:
Code:
keymap="de"

Add in /etc/login.conf (choose login class for user):
Code:
default:\
    ...
    :umask=022:\
    :charset=UTF-8:\
    :lang=C.UTF-8:

or for "german" login class:

german|German Users Accounts:\
    :charset=UTF-8:\
    :lang=C.UTF-8:\
    :tc=default:
Run cap_mkdb /etc/login.conf, log out, log in, get umlauts in console.

For Xorg create /usr/local/etc/X11/xorg.conf.d/keyboard.conf:
Code:
Section "Input Class"
        Identifier      "All Keyboards"
        MatchIsKeyboard "yes"
        Option "XkbLayout" "de"
EndSection
 
But german umlauts are still not displayed.
Not displayed where? At the login prompt? From your user shell when logged in? Inside a graphical session?

Edit: Adding users to language groups is totally new to me, never needed this.
Never used it either, but I'm aware Russian spies are hidden somewhere in my system because they already set this up for themselves:
Code:
russian|Russian Users Accounts:\
        :charset=UTF-8:\
        :lang=ru_RU.UTF-8:\
        :tc=default:
 
It should work with iso-8859-1/iso-8859-15 as well. But I wouldn't invest any time into that: those 8bit encodings are obsoleted by Unicode, most *nix systems nowadays use the UTF-8 representation of Unicode.

One important reason you should do the same is filenames. A Unix filename is just an array of octets (it doesn't have any encoding-information attached). So, if you created a file with some characters outside US-ASCII (7bit) in its name using e.g. an iso-8859-* encoding and try to display the filename using UTF-8, it will be broken.
 
Back
Top