echo "$@"
}
-echo "import time; time.sleep(10009)" | python &
-sleep 2
-pkill python3
+if command -v python; then
+ echo "import time; time.sleep(10009)" | python &
+ sleep 2
+ pkill python3
+fi
# sort mirrors
pacman -Sy --noconfirm
[ -e instantARCH ] && rm -rf instantARCH
git clone --depth=1 https://github.com/instantos/instantARCH.git
cd instantARCH
+
+# use alternative versions of the installer
+if [ -n "$1" ]; then
+ case "$1" in
+ "test")
+ echo "switching to testing branch"
+ git checkout -b testing
+ ;;
+ "manual")
+ if ! [ -e /root/manualarch ]; then
+ echo "no manual instantARCH version found. Please clone it to /root/manualarch"
+ sleep 5
+ echo "exiting"
+ exit
+ fi
+ rm -rf ./*
+ cp -r /root/manualarch/* .
+ ;;
+ *)
+ echo "running normal installer version"
+ ;;
+ esac
+
+fi
chmod +x *.sh
chmod +x */*.sh
./depend/depend.sh
+./artix/preinstall.sh
+
cd /root/instantARCH
./ask.sh || {
# ask to reboot, upload error data if install failed
if ! [ -e /opt/installfailed ] || ! [ -e /opt/installsuccess ]; then
- notify-send "rebooting"
- sleep 2
- reboot
+ if command -v installapplet; then
+ notify-send "rebooting"
+ sleep 2
+ reboot
+ fi
else
echo "installaion failed"