#!/bin/sh # kernel_cmdline # Looks for a parameter on the kernel's boot-time command line. # # returns: 0 if param was found. Also prints its value if it was a K=V param. # 1 if it was not. Also prints value passed as # kernel_cmdline () { for param in $(/bin/cat /proc/cmdline); do case "${param}" in $1=*) echo "${param##*=}"; return 0 ;; $1) return 0 ;; *) continue ;; esac done [ -n "${2}" ] && echo "${2}" return 1 } LOCALE="$(kernel_cmdline locale.LANG en_US.utf8)" TIMEZONE="$(kernel_cmdline timezone UTC)" KEYMAP="$(kernel_cmdline vconsole.keymap us)" CONSOLEFONT="$(kernel_cmdline vconsole.font)" CONSOLEMAP="$(kernel_cmdline vconsole.font.map)" USENONFREE="$(kernel_cmdline nonfree no)" #Polkit issue, reinstall needed? pacman -Udf --noconfirm /opt/chakra/pkgs/polkit* &>/dev/null systemctl --system daemon-reload systemctl reload dbus.service systemctl start polkit.service systemctl stop NetworkManager.service systemctl start NetworkManager.service #edit /etc/environment echo "LANG=${LOCALE}" >> /etc/environment source /etc/locale_setup.sh # imports get_bootparam_value, get_country and #set_locale set_locale # sets locale settings and hwclock #Hardware detection /opt/chakra/bin/hwdetect #Detecting drivers /opt/chakra/bin/xorg-detect #Adjusting xorg config file /opt/chakra/bin/xorg-config #do_configsforroot cp -a /etc/skel/. /root/ #This will go into workspace soon sed -i -e 's/halt/poweroff/' /usr/share/config/kdm/kdmrc # set correct permissions for live user chown -R live:users /home/live # fix sudoers file chown root:root /etc/sudoers chmod 0440 /etc/sudoers # misc exports export KDE_NO_IPV6="TRUE" export OPERAPLUGINWRAPPER_PRIORITY=0