#!/bin/sh set -e if [ -z "$1" ]; then echo "No argument supplied" echo "arg1 sudo user pass" exit 1 fi PASS=$1 URI_TAMSYN_FONTS="https://web.archive.org/web/20200616131205if_/http://www.fial.com/~scott/tamsyn-font/download/tamsyn-font-1.11.tar.gz" # remove extra tty rm /run/runit/service/agetty-tty[4-6] # btrfs sub list -pacgu / #sudo btrfs subvolume snapshot /data/projects/web1 /data/.snapshots/web1-2020-12-25 #sudo btrfs subvolume list /data #sudo btrfs subvolume show /data/.snapshots/web1-2020-12-25 #update cmdline to previous root snapshot #mkinitcpio -p artix #reboot #mkdir /mnt/btrfs-root #mount -o subvolid=@ /dev/mapper/cryptroot /mnt/btrfs-root #sudo rsync -avz --delete /data/.snapshots/web1-2020-12-25/ /data/projects/web1/ btrfs sub snap / /.btrfs/snapshots/root_$(date +"%Y%m%dT%H%M%S")--init # add wheel group to sudoers sed -i "/^#.*%wheel.*ALL) ALL/s/#.*%wheel/%wheel/g" /etc/sudoers sed -i "/^%wheel.*ALL) ALL/i Defaults:%wheel rootpw" /etc/sudoers # create non root user useradd -m -G wheel -s /bin/bash zaat echo "zaat:${PASS}" | chpasswd # qemu guest agent pacman -S --noconfirm qemu-guest-agent-runit ln -s /etc/runit/sv/qemu-guest-agent /run/runit/service/ #pacman -S --noconfirm qemu-guest-agent-openrc #rc-update add qemu-guest-agent boot # install ssh #pacman -S --noconfirm openssh-openrc # install X #pacman -S --noconfirm xorg-server xorg-xinit # xinitrc #cp /etc/X11/xinit/xinitrc /home/zaat/.xinitrc #sed -i "/^twm/d" /home/zaat/.xinitrc #sed -i "/^xclock/d" /home/zaat/.xinitrc #sed -i "/^xterm/d" /home/zaat/.xinitrc #sed -i "/^exec xterm/d" /home/zaat/.xinitrc #echo "openbox-session" >> /home/zaat/.xinitrc # install openbox #pacman -S --noconfirm openbox ttf-liberation xorg-xrandr # openbox config #mkdir -p /home/zaat/.config/openbox #cp -a /etc/xdg/openbox/ /home/zaat/.config/ # add artix universe repos arch=x86_64 echo -e "[universe] Server = https://universe.artixlinux.org/$arch Server = https://mirror1.artixlinux.org/universe/$arch Server = https://mirror.pascalpuffke.de/artix-universe/$arch Server = https://artixlinux.qontinuum.space:4443/artixlinux/universe/os/$arch Server = https://mirror1.cl.netactuate.com/artix/universe/$arch " >> /etc/pacman.conf # add arch repositories pacman -Syu --noconfirm artix-archlinux-support echo -e "# Arch [testing] Include = /etc/pacman.d/mirrorlist-arch [extra] Include = /etc/pacman.d/mirrorlist-arch [community] Include = /etc/pacman.d/mirrorlist-arch" >> /etc/pacman.conf pacman-key --populate archlinux pacman -Syu # ricing #sed -i "s/^#GRUB_COLOR_/GRUB_COLOR_/g" /etc/default/grub #update-grub # ls /usr/share/kbd/consolefonts # showconsolefont # setfont lat2-16 -m #pacman -S --noconfirm tamsyn-font #wget https://aur.archlinux.org/cgit/aur.git/snapshot/tamsyn-font.tar.gz #wget https://web.archive.org/web/20200616131205if_/http://www.fial.com/~scott/tamsyn-font/download/tamsyn-font-1.11.tar.gz wget ${URI_TAMSYN_FONTS} tar xvf tamsyn-font-1.11.tar.gz -C /tmp mv /tmp/tamsyn-font-1.11/*.{pcf,gz} /usr/share/kbd/consolefonts rm tamsyn-font-1.11.tar.gz rm -rf /tmp/tamsyn-font-1.11 echo "FONT=Tamsyn10x20b" >> /etc/vconsole.conf #sed -i "/^consolefont=/c\consolefont=Tamsyn10x20b" /etc/conf.d/consolefont #rc-update add consolefont boot sed -i "/^BINARIES=/c\BINARIES=(setfont)" /etc/mkinitcpio.conf sed -i "/^HOOKS=/c\HOOKS=(base udev autodetect keyboard consolefont modconf block encrypt filesystems fsck)" /etc/mkinitcpio.conf sh -c "mkinitcpio -v --preset artix" #pacman -S --noconfirm obconf # web browsers #pacman -S --noconfirm qutebrowser #firefox # terminal fonts # https://berkeleygraphics.com/typefaces/berkeley-mono/ # https://input.djr.com/ # https://github.com/be5invis/Iosevka # .bash_profile echo "export PS1=' > '" >> /root/.bash_profile echo "echo 'i do still wrong'" >> /root/.bash_profile