-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathupdocs.sh
More file actions
executable file
·40 lines (32 loc) · 869 Bytes
/
updocs.sh
File metadata and controls
executable file
·40 lines (32 loc) · 869 Bytes
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
34
35
36
37
38
39
40
#!/bin/bash
GROUP=io/playn
VERSION=$1
if [ -z "$VERSION" ]; then
echo "Usage: $0 M.N"
echo "Where M.N is the version of the just performed release."
exit 255
fi
unpack() {
ARTIFACT=playn-$1
COREDIR=$HOME/.m2/repository/$GROUP/$ARTIFACT/$VERSION
if [ ! -d $COREDIR ]; then
echo "Can't find: $COREDIR"
echo "Is $VERSION the correct version?"
exit 255
fi
echo "Unpacking $ARTIFACT-$VERSION-javadoc.jar..."
pushd docs/api/$1
jar xf $COREDIR/$ARTIFACT-$VERSION-javadoc.jar
rm -rf META-INF
popd
}
unpack core
unpack scene
echo "Adding and committing updated docs..."
git add docs/api
git commit -m "Updated docs for $VERSION release." .
git push
echo "Tagging docs..."
git tag -a v$VERSION -m "Tagged docs for $VERSION release."
git push origin v$VERSION
echo "Thank you, please drive through."