mediawiki-extensions-Visual.../.docs/generate.sh
Timo Tijhof 62aeb254d9 Implement inline documentation examples.
Refactored the (previously unused) eg-iframe file to be a
template with 2 placeholders for script and styles.

The previous version was just the basic version to execute
javascript code, but that's not good enough since we need a
whole bunch of classes to be loaded.

A bash file processes the template into proper html, with the
help of the makeStaticLoader maintenance script we already had.

Updated demo.css, cleaned up redundant properties restyled
slightly to be more like the Vector skin and less "raw".

Fixed default $IP path in makeStaticLoader.php to work with simple mediawiki core installs having the extension in the
regular extensions directory, and prefixed __DIR__ so it
doesn't rely on the directory you call it from.

Change-Id: Ic789121dfeca08d9db69564d2ad2e52b3fa45de9
2013-02-08 17:47:10 -08:00

22 lines
463 B
Bash
Executable file

#!/usr/bin/env bash
cd $(cd $(dirname $0); pwd)
(
while IFS='' read -r l
do
if [[ "$l" =~ {{VE-LOAD-BODY}} ]]
then
php ../maintenance/makeStaticLoader.php --section=body --ve-path=../modules/
elif [[ "$l" =~ {{VE-LOAD-HEAD}} ]]
then
php ../maintenance/makeStaticLoader.php --section=head --ve-path=../modules/
else
echo "$l"
fi
done
) < eg-iframe.tpl | php > eg-iframe.html
jsduck --config=config.json
rm eg-iframe.html
cd - > /dev/null