-
Notifications
You must be signed in to change notification settings - Fork 14
/
publish.sh
executable file
·45 lines (38 loc) · 1.13 KB
/
publish.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
34
35
36
37
38
39
40
41
42
43
44
45
#!/bin/sh -e
# Publishes inband track spec to CVS
cd "$(dirname $0)"
GITUSER="$(git config --get user.email)"
if [ $GITUSER = [email protected] ]; then
CVSUSER=spfeiffe
else
echo "Unable to map $GITUSER to a CVS user"
exit 1
fi
export [email protected]:/sources/public
export CVS_RSH=ssh
if [ ! -e ../../CVS/html5/html-sourcing-inband-tracks ]; then
echo "# Checkout CVS"
cd ../../CVS/html5/
cvs checkout html-sourcing-inband-tracks
else
echo "# Update CVS"
cd ../../CVS/html5/html-sourcing-inband-tracks
cvs update
cd -
fi
echo
#echo "# Generate static HTML"
#phantomjs ../../respec/tools/respec2html.js index.html ../../CVS/html5/html-sourcing-inband-tracks/Overview.html
echo "# Copying Overview.html to CVS"
cp Overview.html ../../CVS/html5/html-sourcing-inband-tracks/
echo "# Commit to CVS"
if [ "$1" != "-f" ]; then
read -p "Really commit? (y) " CONTINUE
if [ "$CONTINUE" != "y" ]; then
echo "Not really."
exit 1
fi
fi
COMMIT="$(git rev-parse HEAD)"
cd ../../CVS/html5/html-sourcing-inband-tracks
cvs commit -m "Sync HTML sourcing inband tracks spec with Git commit $COMMIT"