mirror of
https://github.com/rojo-rbx/rojo.git
synced 2026-04-20 12:45:05 +00:00
New doc site
This commit is contained in:
10
bin/docs-index.html
Normal file
10
bin/docs-index.html
Normal file
@@ -0,0 +1,10 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>redirect</title>
|
||||
<meta http-equiv="refresh" content="0;url=/docs/latest" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,31 +1,32 @@
|
||||
#!/bin/sh
|
||||
|
||||
# Kludged documentation generator to support multiple versions.
|
||||
# Make sure the `site` folder is a checkout of this repository's `gh-pages`
|
||||
# branch.
|
||||
|
||||
set -e
|
||||
|
||||
REMOTE=$(git remote get-url origin)
|
||||
CHECKOUT="$(mktemp -d)"
|
||||
OUTPUT="$(pwd)/site"
|
||||
OUTPUT="$(pwd)/site/docs"
|
||||
|
||||
if [ -d site ]
|
||||
then
|
||||
cd site
|
||||
git pull
|
||||
else
|
||||
git clone "$REMOTE" site
|
||||
git clone https://github.com/rojo-rbx/rojo-rbx.github.io site
|
||||
cd site
|
||||
git checkout gh-pages
|
||||
fi
|
||||
|
||||
rm -rf docs
|
||||
mkdir docs
|
||||
cp ../bin/docs-index.html docs/index.html
|
||||
|
||||
git clone "$REMOTE" "$CHECKOUT"
|
||||
cd "$CHECKOUT"
|
||||
|
||||
echo "Building master"
|
||||
git checkout master
|
||||
mkdocs build --site-dir "$OUTPUT"
|
||||
mkdocs build --site-dir "$OUTPUT/latest"
|
||||
|
||||
echo "Building 0.5.x"
|
||||
mkdocs build --site-dir "$OUTPUT/0.5.x"
|
||||
|
||||
Reference in New Issue
Block a user