|
@@ -1,18 +1,6 @@
|
|
|
|
|
|
|
|
|
-set -e
|
|
|
-
|
|
|
-
|
|
|
-VAI_getarg() {
|
|
|
- set +e
|
|
|
- getarg "$@"
|
|
|
- set -e
|
|
|
-}
|
|
|
-VAI_getargbool() {
|
|
|
- set +e
|
|
|
- getargbool "$@"
|
|
|
- set -e
|
|
|
-}
|
|
|
+type getargbool >/dev/null 2>&1 || . /lib/dracut-lib.sh
|
|
|
|
|
|
|
|
|
VAI_info_msg() {
|
|
@@ -224,10 +212,13 @@ VAI_configure_autoinstall() {
|
|
|
esac
|
|
|
|
|
|
|
|
|
- if VAI_getargbool 0 autourl ; then
|
|
|
- xbps-uhelper fetch "$(VAI_getarg autourl)>/etc/autoinstall.cfg"
|
|
|
+ set +e
|
|
|
+ if getargbool 0 autourl ; then
|
|
|
+ set -e
|
|
|
+ xbps-uhelper fetch "$(getarg autourl)>/etc/autoinstall.cfg"
|
|
|
|
|
|
else
|
|
|
+ set -e
|
|
|
mv /etc/autoinstall.default /etc/autoinstall.cfg
|
|
|
fi
|
|
|
|
|
@@ -300,9 +291,10 @@ VAI_main() {
|
|
|
}
|
|
|
|
|
|
|
|
|
-if VAI_getargbool 0 auto ; then
|
|
|
+if getargbool 0 auto ; then
|
|
|
+ set -e
|
|
|
VAI_main
|
|
|
+
|
|
|
+ set +e
|
|
|
fi
|
|
|
|
|
|
-
|
|
|
-set +e
|