Skip to content
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,6 @@ package-clean:
rm -f dist/package/$(package_name).tar.xz

test-publish:
for t in t/*.sh; do $$t > $$t.log 2> $$t.debug || ( echo FAIL: $$t && exit 1); done && echo ALL PASS
( for t in t/*.sh; do bash -x $$t > $$t.log 2> $$t.debug && continue; echo FAIL: $$t; exit 1; done && echo ALL PASS )

.PHONY: all install
33 changes: 13 additions & 20 deletions publish_distro
Original file line number Diff line number Diff line change
Expand Up @@ -57,28 +57,20 @@ get_changes_filename() {

# --dry and --cleanup should not be passed to rsync through $@
# config file and possibly other opts including --force need to be
for arg; do
shift
if [ "$arg" == '--force' ]; then
while (("$#")); do
if [ "$1" == '--force' ]; then
force=1
# newargs+=("$arg")
shift
continue
elif [ "$arg" == '--dry' ]; then
elif [ "$1" == '--dry' ]; then
dryrun=echo
shift
continue
elif [ "$arg" == '--cleanup' ]; then
elif [ "$1" == '--cleanup' ]; then
do_cleanup=1
date="90 days ago"
continue
elif [ "$arg" == '--now' ]; then
elif [ "$1" == '--now' ]; then
PUBLISH_DELAY=0
shift
continue
else
newargs+=("$arg")
newargs+=("$1")
fi
shift
done

# set newargs as $@
Expand Down Expand Up @@ -121,8 +113,8 @@ if [ -n "$do_cleanup" ]; then
fi

if test "$dryrun" == echo; then
deletelog=/dev/stdout
synclog=/dev/stdout
deletelog=/dev/stderr
synclog=/dev/stderr
else
mkdir -p "${synclog%/*}" "${deletelog%/*}"
if test -f $synclog; then
Expand All @@ -135,6 +127,7 @@ fi

version=
do_sync_isos=1
changes_done=0 # we need changes done only once in this loop
for flavor in "${flavors[@]}"; do
get_version

Expand All @@ -149,7 +142,8 @@ for flavor in "${flavors[@]}"; do
do_sync_isos=0
break
fi
if [ -n "$changes" ]; then
if [ -n "$changes" ] && [ 0 == "$changes_done" ] ; then
changes_done=1
if [ -d "$stage/$changes" ]; then
# new way, use the obs generated changelogs
$dryrun rsync -avvhiH $stage/$changes \
Expand All @@ -162,8 +156,7 @@ for flavor in "${flavors[@]}"; do
# old way (already broken?)
if [ ! -s "$changes" ]; then
echo "generating $changes" | tee -a $synclog
[ -z "$dryrun" ] || changes=/dev/stdout
$dryrun curl -sf "$url" >$changes
$dryrun curl -sf "$url" -o "$changes"
fi
if [ ! -e $stage/$isodir/$changes ]; then
$dryrun cp -v $changes $stage/$isodir | tee -a $synclog
Expand Down
3 changes: 1 addition & 2 deletions publish_distro_conf/publish_tumbleweed.config
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ logfile_base=~/publish_logs/tumbleweed/$(date -d "$date" '+%Y/%m/%d/%H%M')
synclog="${logfile_base}.log"
deletelog="${logfile_base}-deletes.log"
path="/tumbleweed"
flavors=(DVD-x86_64 NET-x86_64 GNOME-Live-x86_64 KDE-Live-x86_64 Rescue-CD-x86_64 \
DVD-i586 NET-i586 GNOME-Live-i686 KDE-Live-i686 Rescue-CD-i686)
flavors=(DVD-x86_64 NET-x86_64 GNOME-Live-x86_64 KDE-Live-x86_64 Rescue-CD-x86_64)

get_version() {
# get expected version from first flavor
Expand Down
285 changes: 0 additions & 285 deletions t/01-publish_distro_leap.sh.debug

This file was deleted.

Loading