Meta/dodoc.sh: do not lose index.html

Junio C Hamano committed Mar 28, 2007 at 14:14 UTC 89822eec3bbe1d64c3f446ab947e1e774c876284
1 file changed +16 -4
dodoc.sh
+16 -4
@@ -69,11 +69,11 @@ do
69 rm -fr doc-$type-inst
70 done
71
72 -make >../:html.log 2>&1 \
72 +make >./:html.log 2>&1 \
73 -C Documentation -j 2 \
74 WEBDOC_DEST="$DOCREPO/doc-html-inst" install-webdoc || exit
75
76 -make >../:man.log 2>&1 \
76 +make >./:man.log 2>&1 \
77 -C Documentation -j 2 \
78 man1="$DOCREPO/doc-man-inst/man1" \
79 man7="$DOCREPO/doc-man-inst/man7" \
@@ -102,7 +102,19 @@ do
102 (
103 cd doc-${type}pages
104
105 - if git commit -a -m "Autogenerated docs for $NID"
105 + case "$type" in
106 + html)
107 + TYPE='HTML docs'
108 + rm -f index.html
109 + ln -sf git.html index.html
110 + git add index.html
111 + ;;
112 + man)
113 + TYPE='manpages'
114 + ;;
115 + esac
116 +
117 + if git commit -a -m "Autogenerated $TYPE for $NID"
118 then
119 git send-pack "$MASTERREPO" master:refs/heads/$type
120 else
@@ -115,7 +127,7 @@ if test -d $PUBLIC
127 then
128 # This is iffy...
129 mv Documentation/git.html Documentation/saved-git-html
118 - make >>../:html.log 2>&1 \
130 + make >>./:html.log 2>&1 \
131 -C Documentation \
132 WEBDOC_DEST="$PUBLIC" ASCIIDOC_EXTRA='-a stalenotes' \
133 install-webdoc &&