3 # enable all sorts of configuration concerning login, lightdm, networking and grub
5 # enable lightdm greeter
6 if grep -q 'greeter-session' /etc/lightdm/lightdm.conf; then
7 LASTSESSION="$(grep 'greeter-session' /etc/lightdm/lightdm.conf | tail -1)"
8 sed -i "s/$LASTSESSION/greeter-session=lightdm-gtk-greeter/g" /etc/lightdm/lightdm.conf
10 sed -i 's/^\[Seat:\*\]/\[Seat:\*\]\ngreeter-session=lightdm-gtk-greeter/g' /etc/lightdm/lightdm.conf
13 # set up instantwm as a default user session
14 if grep -q '^user-session.*' /etc/lightdm/lightdm.conf; then
15 echo "adjusting user session"
16 sed -i 's/^user-session=.*/user-session=instantwm/g' /etc/lightdm/lightdm.conf
19 # fix gui not showing up
20 sed -i 's/^#logind-check-graphical=.*/logind-check-graphical=true/' /etc/lightdm/lightdm.conf
22 echo '# modified by instantARCH' >>/etc/lightdm/lightdm.conf
24 # needed to get internet to work
25 if ! [ -e /opt/topinstall ] && ! iroot partswap; then
26 if command -v systemctl; then
27 if ! grep -iq manjaro /etc/os-release; then
29 systemctl enable systemd-swap
31 echo "swapfc_enabled=1"
32 echo "swapfc_max_count=8"
33 } >>/etc/systemd/swap.conf
38 sed -i 's/# %wheel/%wheel/g' /etc/sudoers
39 echo 'Defaults env_reset,pwfeedback' >>/etc/sudoers
41 if command -v systemctl; then
42 systemctl enable lightdm
43 systemctl enable NetworkManager
46 if ! command -v update-grub &>/dev/null; then
47 # can't include this in package
49 grub-mkconfig -o /boot/grub/grub.cfg' >/usr/bin/update-grub
50 chmod 755 /usr/bin/update-grub
55 [ -e /opt/instantos ] || mkdir -p /opt/instantos
56 echo "kvm" >/opt/instantos/kvm