Commit 3d5884f6 authored by Alessandro Elias's avatar Alessandro Elias
Browse files

Add time stamp to the target directory, where iso is created.


Signed-off-by: Alessandro Elias's avatarAlessandro Elias <ae11@c3sl.ufpr.br>
parent 100a7350
......@@ -42,17 +42,17 @@ source "${PREFIX}/conf/$_DIST/create-iso.conf" \
source common.sh
TIME_STAMP="`date +'%Y-%m-%dT%H:%M:%S'`"
LOG_FILE="${LOG_PATH}/create-iso-${TIME_STAMP}.log"
export LOG_FILE="${LOG_PATH}/create-iso-${TIME_STAMP}.log"
mkdir -p ${TMP}
sudo apt-get install isolinux syslinux squashfs-tools genisoimage xorriso \
apt-get install isolinux syslinux squashfs-tools genisoimage xorriso \
|| log ERROR "Failed to install basic tools: \"${_DIST}\""
for file in $(ls ${SCRIPTSDIR}); do
if [ -x "${SCRIPTSDIR}/${file}" ] && egrep -q '^[0-9]{2}-[a-z-]+' <<< "$file"; then
echo "$file"
if ! "${SCRIPTSDIR}/${file}"\
for script in `ls ${SCRIPTSDIR}`; do
if [ -x "$SCRIPTSDIR/$script" ] && egrep -q '^[0-9]{2}-[A-Za-z]+' <<< "$script"; then
echo "Running `basename $script`..."
if ! "${SCRIPTSDIR}/${script}"\
${_DIST} \
${CHROOTDIR} \
${CHROOTFILE} \
......@@ -69,19 +69,25 @@ for file in $(ls ${SCRIPTSDIR}); do
${SOURCESLISTDEFAULT} \
${TMP} \
${LOG_FILE}; then
log ERROR "While running \"${SCRIPTSDIR}/${file}\""
log ERROR "While running \"${SCRIPTSDIR}/${script}\""
cleanup "$CHROOTDIR" "$TMP"
exit 1
fi
if [[ "$script" =~ [0-9]+\-chroot\.* ]]; then
execChroot "$CHROOTDIR"
fi
fi
done
set -x
NAME="LinuxEducacional6-$(echo ${_DIST} | cut -d'/' -f2).iso"
NAME="LinuxEducacional6-$(echo ${_DIST} | cut -d'/' -f2).iso"
cd ${TMP}/image
xorriso -as mkisofs -isohybrid-mbr /usr/lib/ISOLINUX/isohdpfx.bin -c isolinux/boot.cat -b isolinux/isolinux.bin -no-emul-boot -boot-load-size 4 -boot-info-table -eltorito-alt-boot -no-emul-boot -isohybrid-gpt-basdat -o ${PREFIX}/iso/${NAME} \
. ||\
log ERROR "Failed to generate iso image."
cd -
cleanTmpFiles
cleanup "$CHROOTDIR" "$TMP"
exit 0
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment