forked from semanticvectors/semanticvectors
-
Notifications
You must be signed in to change notification settings - Fork 1
/
update-release-docs.sh
executable file
·33 lines (33 loc) · 1.19 KB
/
update-release-docs.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/bash
#
echo "Status: Not been updated to use github. Do not use!"
exit 1;
#
# Script for updating online javadoc when making a new release.
#
# Must be run from this directory, but uses higher directories in the
# svn tree as well. Therefore you need to run on a copy that is checked
# out all the way from the trunk, e.g.,
#
# svn checkout https://semanticvectors.googlecode.com/svn/ semanticvectors-all --username ...
# cd semanticvectors-all
# ./update-release-docs.sh.
#
command -v jar >/dev/null 2>&1 || { echo >&2 "Script requires jar but it's not available. Aborting."; exit 1;
#
VERSION=5.8 # Should be kept in sync with pom.xml
DEST=../javadoc/latest-stable
mvn javadoc:jar
svn rm --force "$DEST"
svn ci "$DEST" -m "Removing old stuff for the new release javadocs"
mkdir "$DEST"
svn add "$DEST"
cd "$DEST"
jar xvf ../../trunk/target/semanticvectors-$VERSION-javadoc.jar
#
svn add --force .
find . -name "*.html" | xargs -n 1 svn propset svn:mime-type text/html
find . -name "*.css" | xargs -n 1 svn propset svn:mime-type text/css
find . -name "*.gif" | xargs -n 1 svn propset svn:mime-type image/gif
svn commit -m "Adding new javadoc for release version $VERSION"
#