diff options
author | Juan RP <xtraeme@gmail.com> | 2012-06-14 11:21:54 +0200 |
---|---|---|
committer | Juan RP <xtraeme@gmail.com> | 2012-06-14 11:21:54 +0200 |
commit | a45a0d1448a8a6b60769f33c114b6db243aede47 (patch) | |
tree | 4eb975e28db3a42f9ea3c7f4bcbc06bd9b159753 /dracut | |
parent | 7045698d748dbaad02149da73148cd31f44ed1d6 (diff) | |
download | hrmpf-a45a0d1448a8a6b60769f33c114b6db243aede47.tar.gz hrmpf-a45a0d1448a8a6b60769f33c114b6db243aede47.tar.xz hrmpf-a45a0d1448a8a6b60769f33c114b6db243aede47.zip |
Added a new dracut script to overwrite keymap/locale settings in NEWROOT. v0.9.6
Diffstat (limited to 'dracut')
-rw-r--r-- | dracut/module-setup.sh | 1 | ||||
-rw-r--r-- | dracut/vmklive-conf.sh | 25 |
2 files changed, 26 insertions, 0 deletions
diff --git a/dracut/module-setup.sh b/dracut/module-setup.sh index 34d5120..0e334b8 100644 --- a/dracut/module-setup.sh +++ b/dracut/module-setup.sh @@ -13,4 +13,5 @@ depends() { install() { inst chmod inst_hook pre-pivot 01 "$moddir/vmklive-adduser.sh" + inst_hook pre-pivot 02 "$moddir/vmklive-conf.sh" } diff --git a/dracut/vmklive-conf.sh b/dracut/vmklive-conf.sh new file mode 100644 index 0000000..4fe1747 --- /dev/null +++ b/dracut/vmklive-conf.sh @@ -0,0 +1,25 @@ +#!/bin/sh +# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- +# ex: ts=8 sw=4 sts=4 et filetype=sh + +KEYMAP=$(getarg vconsole.keymap) +FONT=$(getarg vconsole.font) +FONT_MAP=$(getarg vconsole.font.map) +FONT_UNIMAP=$(getarg vconsole.font.unimap) +LOCALE=$(getarg locale.LANG) + +if [ -n "$KEYMAP" ]; then + sed -i -e "s|^KEYMAP=.*|KEYMAP=$KEYMAP|g" ${NEWROOT}/etc/vconsole.conf +fi +if [ -n "$FONT" ]; then + sed -i -e "s|^FONT=.*|FONT=$FONT|g" ${NEWROOT}/etc/vconsole.conf +fi +if [ -n "$FONT_MAP" ]; then + sed -i -e "s|^FONT_MAP=.*|FONT_MAP=$FONT_MAP|g" ${NEWROOT}/etc/vconsole.conf +fi +if [ -n "$FONT_UNIMAP" ]; then + sed -i -e "s|^FONT_UNIMAP=.*|FONT_UNIMAP=$FONT_UNIMAP|g" ${NEWROOT}/etc/vconsole.conf +fi +if [ -n "$LOCALE" ]; then + sed -i -e "s|^LANG=.*|LANG=$LOCALE|g" ${NEWROOT}/etc/locale.conf +fi |