Fix whitespace.
This commit is contained in:
parent
d269466522
commit
bd95b08675
|
@ -30,40 +30,40 @@ BUILD_SRCDIR_BASE=${BASE_DIR}/buildroot/${ARCH}-dev/builds/
|
||||||
BUILD_DESTDIR_BASE=/home/buildsync/builds/${ARCH}/
|
BUILD_DESTDIR_BASE=/home/buildsync/builds/${ARCH}/
|
||||||
|
|
||||||
give_latest_from_dates() {
|
give_latest_from_dates() {
|
||||||
sed 's,-20,~20,g' | \
|
sed 's,-20,~20,g' | \
|
||||||
sort -k +1 -n -t '~' |\
|
sort -k +1 -n -t '~' |\
|
||||||
awk -F\~ \
|
awk -F\~ \
|
||||||
'BEGIN{i=$1; o=$0};
|
'BEGIN{i=$1; o=$0};
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
||||||
END { print o; };' | \
|
END { print o; };' | \
|
||||||
tr '~' '-'
|
tr '~' '-'
|
||||||
}
|
}
|
||||||
|
|
||||||
pre_build() {
|
pre_build() {
|
||||||
pushd ${REPO_DIR}
|
pushd ${REPO_DIR}
|
||||||
git pull
|
git pull
|
||||||
popd
|
popd
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
||||||
cd $d
|
cd $d
|
||||||
for f in $(ls 'stage3*bz2' | give_latest_from_dates ) ; do
|
for f in $(ls 'stage3*bz2' | give_latest_from_dates ) ; do
|
||||||
of=${f/20[0-9][0-9].[0-9]/latest} # for 20XX.Y stuff
|
of=${f/20[0-9][0-9].[0-9]/latest} # for 20XX.Y stuff
|
||||||
of=${of/20[0-9][0-9][0-1][0-9][0-9][0-9]/latest} # for 20YYMMDD stuff
|
of=${of/20[0-9][0-9][0-1][0-9][0-9][0-9]/latest} # for 20YYMMDD stuff
|
||||||
ln -sf $f $of
|
ln -sf $f $of
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
post_build() {
|
post_build() {
|
||||||
cd ${BUILD_SRCDIR_BASE}/default
|
cd ${BUILD_SRCDIR_BASE}/default
|
||||||
cp stage3-*${DATESTAMP}*bz2* ${BUILD_DESTDIR_BASE}/
|
cp stage3-*${DATESTAMP}*bz2* ${BUILD_DESTDIR_BASE}/
|
||||||
if [ -n "$(ls -1 *${DATESTAMP}*.iso* 2>/dev/null)" ]; then
|
if [ -n "$(ls -1 *${DATESTAMP}*.iso* 2>/dev/null)" ]; then
|
||||||
cp *${DATESTAMP}*.iso* ${BUILD_DESTDIR_BASE}/
|
cp *${DATESTAMP}*.iso* ${BUILD_DESTDIR_BASE}/
|
||||||
fi
|
fi
|
||||||
cd ${BUILD_SRCDIR_BASE}/hardened
|
cd ${BUILD_SRCDIR_BASE}/hardened
|
||||||
if [ -n "$(ls -1 stage3-*${DATESTAMP}*.bz2.* 2>/dev/null)" ]; then
|
if [ -n "$(ls -1 stage3-*${DATESTAMP}*.bz2.* 2>/dev/null)" ]; then
|
||||||
cp stage3-*${DATESTAMP}*.bz2* ${BUILD_DESTDIR_BASE}/hardened/
|
cp stage3-*${DATESTAMP}*.bz2* ${BUILD_DESTDIR_BASE}/hardened/
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# vim:ft=sh:
|
# vim:ft=sh:
|
||||||
|
|
|
@ -28,40 +28,40 @@ BUILD_SRCDIR_BASE=${BASE_DIR}/buildroot/${ARCH}-dev/builds/
|
||||||
BUILD_DESTDIR_BASE=/home/buildsync/builds/${ARCH}/
|
BUILD_DESTDIR_BASE=/home/buildsync/builds/${ARCH}/
|
||||||
|
|
||||||
give_latest_from_dates() {
|
give_latest_from_dates() {
|
||||||
sed 's,-20,~20,g' | \
|
sed 's,-20,~20,g' | \
|
||||||
sort -k +1 -n -t '~' |\
|
sort -k +1 -n -t '~' |\
|
||||||
awk -F\~ \
|
awk -F\~ \
|
||||||
'BEGIN{i=$1; o=$0};
|
'BEGIN{i=$1; o=$0};
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
||||||
END { print o; };' | \
|
END { print o; };' | \
|
||||||
tr '~' '-'
|
tr '~' '-'
|
||||||
}
|
}
|
||||||
|
|
||||||
pre_build() {
|
pre_build() {
|
||||||
pushd ${REPO_DIR}
|
pushd ${REPO_DIR}
|
||||||
git pull
|
git pull
|
||||||
popd
|
popd
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
||||||
cd $d
|
cd $d
|
||||||
for f in $(ls 'stage3*bz2' | give_latest_from_dates ) ; do
|
for f in $(ls 'stage3*bz2' | give_latest_from_dates ) ; do
|
||||||
of=${f/20[0-9][0-9].[0-9]/latest} # for 20XX.Y stuff
|
of=${f/20[0-9][0-9].[0-9]/latest} # for 20XX.Y stuff
|
||||||
of=${of/20[0-9][0-9][0-1][0-9][0-9][0-9]/latest} # for 20YYMMDD stuff
|
of=${of/20[0-9][0-9][0-1][0-9][0-9][0-9]/latest} # for 20YYMMDD stuff
|
||||||
ln -sf $f $of
|
ln -sf $f $of
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
post_build() {
|
post_build() {
|
||||||
cd ${BUILD_SRCDIR_BASE}/default
|
cd ${BUILD_SRCDIR_BASE}/default
|
||||||
cp stage3-i[46]86-*${DATESTAMP}*.bz2* ${BUILD_DESTDIR_BASE}
|
cp stage3-i[46]86-*${DATESTAMP}*.bz2* ${BUILD_DESTDIR_BASE}
|
||||||
if [ -n "$(ls -1 *${DATESTAMP}*.iso* 2>/dev/null)" ]; then
|
if [ -n "$(ls -1 *${DATESTAMP}*.iso* 2>/dev/null)" ]; then
|
||||||
cp *${DATESTAMP}*.iso* ${BUILD_DESTDIR_BASE}/
|
cp *${DATESTAMP}*.iso* ${BUILD_DESTDIR_BASE}/
|
||||||
fi
|
fi
|
||||||
cd ${BUILD_SRCDIR_BASE}/hardened
|
cd ${BUILD_SRCDIR_BASE}/hardened
|
||||||
if [ -n "$(ls -1 stage3-i686-*${DATESTAMP}*.bz2* 2>/dev/null)" ]; then
|
if [ -n "$(ls -1 stage3-i686-*${DATESTAMP}*.bz2* 2>/dev/null)" ]; then
|
||||||
cp stage3-i686-*${DATESTAMP}*.bz2* ${BUILD_DESTDIR_BASE}/hardened/
|
cp stage3-i686-*${DATESTAMP}*.bz2* ${BUILD_DESTDIR_BASE}/hardened/
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# vim:ft=sh:
|
# vim:ft=sh:
|
||||||
|
|
Loading…
Reference in a new issue