I copy /etc/default/keybord
and make a keyboard2
file.
When I cat the file I get :
# KEYBOARD CONFIGURATION FILE
# Consult the keyboard(5) manual page.
XKBMODEL="pc105"
XKBLAYOUT="fr"
XKBVARIANT=""
XKBOPTIONS=""
BACKSPACE="guess"
Then I sed s/fr/us/ keyboard2
and immediatlly displays :
# KEYBOARD CONFIGURATION FILE
# Consult the keyboard(5) manual page.
XKBMODEL="pc105"
XKBLAYOUT="us"
XKBVARIANT=""
XKBOPTIONS=""
BACKSPACE="guess"
But when I cat keyboard2
again, I got :
# KEYBOARD CONFIGURATION FILE
# Consult the keyboard(5) manual page.
XKBMODEL="pc105"
XKBLAYOUT="fr"
XKBVARIANT=""
XKBOPTIONS=""
BACKSPACE="guess"
tested with sudo, tested puting the 's/fr/us/'
Did I understood something wrong ? Is sed supposed to write into the file or do I need to pipe and overwrite the original file ? Thank you
Versions:
sed (GNU sed) 4.7
Linux kali 5.9.0-kali5-amd64 #1 SMP Debian 5.9.15-1kali1 (2020-12-18) x86_64 GNU/Linux in Oracle Virtual Box