diff options
author | Marius Kintel <marius@kintel.net> | 2011-09-11 18:56:45 (GMT) |
---|---|---|
committer | Marius Kintel <marius@kintel.net> | 2011-09-11 18:56:45 (GMT) |
commit | 06a101df174602fd1f6dd5e1ac7486004e0b80f8 (patch) | |
tree | 495b64d0e66e84bef1860c263251a2ee7cd3f9d0 /scripts | |
parent | 81ec00c09b5923effe6ad0d7fbf9404610f16d0f (diff) |
Change link on web page when publishing snapshots
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/publish-macosx.sh | 3 | ||||
-rwxr-xr-x | scripts/update-web.sh | 14 |
2 files changed, 17 insertions, 0 deletions
diff --git a/scripts/publish-macosx.sh b/scripts/publish-macosx.sh index 6415b52..088e64e 100755 --- a/scripts/publish-macosx.sh +++ b/scripts/publish-macosx.sh @@ -20,3 +20,6 @@ cp OpenSCAD-$VERSION.dmg ~/Dropbox/Public ln -sf OpenSCAD-$VERSION.dmg ~/Dropbox/Public/OpenSCAD-latest.dmg echo "Upload in progress..." + +# Update snapshot filename on wab page +`dirname $0`/update-web.sh OpenSCAD-$VERSION.dmg diff --git a/scripts/update-web.sh b/scripts/update-web.sh new file mode 100755 index 0000000..264da08 --- /dev/null +++ b/scripts/update-web.sh @@ -0,0 +1,14 @@ +#!/bin/bash + +dmgfile=$1 +if [ -z "$dmgfile" ]; then + echo "Usage: $0 <dmgfile>" + exit 1 +fi +indexfile=../openscad.github.com/index.html +if [ -f $indexfile ]; then + sed -i .backup -e "s/^\(.*mac-snapshot.*\)\(openscad-.*\.dmg\)\(.*\)\(openscad-.*dmg\)\(.*$\)/\\1$dmgfile\\3$dmgfile\\5/" $indexfile +else + echo "Web page not found at $indexfile" +fi +echo "Web page updated. Remember to commit and push openscad.githib.com" |