From a61d7a5e658da2bd364e7222aaab9f069a7de573 Mon Sep 17 00:00:00 2001 From: Justin Ethier Date: Sun, 2 Oct 2016 16:48:29 -0400 Subject: [PATCH] Added file --- scripts/api-update.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 scripts/api-update.sh diff --git a/scripts/api-update.sh b/scripts/api-update.sh new file mode 100755 index 00000000..67ea55c5 --- /dev/null +++ b/scripts/api-update.sh @@ -0,0 +1,17 @@ +#!/bin/bash + +rm -rf /tmp/api +cp -r docs/api/ /tmp/api +git checkout gh-pages +cp -r /tmp/api/ docs/ + +# find . | grep md +for fn in `find . | grep md`; do + echo "processing file: $fn" + sed -i.old '1s;^;---\n;' $fn + sed -i.old '1s;^;title: API\n;' $fn + sed -i.old '1s;^;layout: main\n;' $fn + sed -i.old '1s;^;---\n;' $fn + rm -f $fn.old +done +