chiark / gitweb /
Merge branch 'tidy' into 'main'
[jarrg-ian.git] / build-sh
index 887f236df8b671f2893d1618acd2d8bf32e9aeec..39a2be28c43817499fa9548248e975f1535b637f 100755 (executable)
--- a/build-sh
+++ b/build-sh
@@ -17,6 +17,7 @@ revision=`git describe --always || echo '(unknown revision)'`
 if [ x"`git diff 2>/dev/null || echo x`" != x ]; then
        revision="$revision-local"
 fi
+revision=${revision#jarrg-}
 
 cat >src/net/chiark/yarrg/Version.java <<END
   package net.chiark.yarrg;
@@ -39,6 +40,7 @@ Building tarballs
 
 tarball () {
        output=$1; shift
+       >"$output"; # avoids rsync seeing that . changed
        GZIP='-9v --rsyncable' tar --exclude=\*{~,.tar.gz,.exe} --exclude='#*#' \
          --transform='s/^./jarrg/' --exclude={src/build,tmp} "$@" \
          -zcf "$output" .
@@ -56,12 +58,17 @@ Generated OK:
 "
 ls -al $files
 
-pubbase="${JARRG_PUBLISH_BASE-login.chiark.greenend.org.uk}"
+pubbase="${JARRG_PUBLISH_BASE-ijackson@login.chiark.greenend.org.uk}"
 pubdir="${JARRG_PUBLISH_DIR-/home/yarrgweb/public-html/download/jarrg}"
 
 echo "
 Revision: $revision
 
-Install with:
- RSYNC_RSH=ssh rsync -vP $files $pubbase:$pubdir/test/
+Publish as test with:
+  RSYNC_RSH=ssh rsync -vP $files $pubbase:$pubdir/test/
+
+To actually publish a release, on $pubbase:
+  mkdir $revision
+  ln test/* $revision/.
+  ln -f test/* .
 "