nilmbuntu/full-rebuild.sh

23 lines
465 B
Bash
Raw Permalink Normal View History

2013-08-17 22:31:57 -04:00
#!/bin/bash
2013-08-18 15:45:41 -04:00
# make sure this was run as root, so we don't get asked for
# passwords during execution
2013-08-17 22:31:57 -04:00
if [ $UID -ne 0 ] ; then
echo "Need to be root; trying sudo"
2013-08-18 21:29:01 -04:00
exec sudo nice env BUILD_CONFIG=$BUILD_CONFIG $0 "$@"
2013-08-17 22:31:57 -04:00
fi
. config || exit 0
2013-08-17 22:31:57 -04:00
set -e
2013-08-17 22:31:57 -04:00
./cleanup.sh
2013-08-19 11:58:48 -04:00
for d in ${ORIG} ${OUTPUT} ${DISK} ; do
mkdir -p $(dirname $d)
chown ${NONPRIV_UID} $(dirname $d)
2013-08-19 11:58:48 -04:00
done
2013-08-17 22:31:57 -04:00
./extractiso.sh
2016-06-27 16:52:34 -04:00
./customize.sh
./buildiso.sh
chown ${NONPRIV_UID} ${ORIG} ${OUTPUT}