From bfc11b7f0be63e87c0c8bd78800a9e78bd265161 Mon Sep 17 00:00:00 2001 From: Kilian Ciuffolo Date: Fri, 27 Nov 2015 18:43:50 -0800 Subject: [PATCH] improved README and added init and serve scripts --- README.md | 14 +++----------- _config-local.sample.yml | 2 +- init.sh | 33 +++++++++++++++++++++++++++++++++ serve.sh | 3 +++ 4 files changed, 40 insertions(+), 12 deletions(-) create mode 100755 init.sh create mode 100755 serve.sh diff --git a/README.md b/README.md index 344b9cc..5ab0902 100644 --- a/README.md +++ b/README.md @@ -5,23 +5,15 @@ $ git clone git@github.com:tinymce/tinymce-docs.git $ cd tinymce-docs $ sudo gem install bundle - $ bundle install - $ cp _config-local.sample.yml _config-local.yml - $ curl http://beta.tinymce.com/_docs/menu.html > _includes/menu.html - $ curl http://beta.tinymce.com/_docs/menu_demo.html > _includes/menu_demo.html - $ curl http://beta.tinymce.com/_docs/footer.html > _includes/footer.html - $ curl http://beta.tinymce.com/_docs/favicons.html > _includes/favicons.html - $ echo [] > _data/nav_api.json - -Edit `_config-local.yml` accordingly with your workflow, you may want to set `shared_baseurl: "http://beta.tinymce.com"` for example in order to use the correct styles and CSS. + $ ./init.sh ### Run development version - $ jekyll serve --config _config.yml,_config-local.yml + $ ./serve.sh Navigate to http://127.0.0.1:4000/ ### Contribute to TinyMCE If you would like to contribute to the TinyMCE project please read our contributor's guide: -http://beta.tinymce.com/docs/advanced/contributing-to-open-source/ +http://www.tinymce.com/docs/advanced/contributing-to-open-source/ diff --git a/_config-local.sample.yml b/_config-local.sample.yml index b3bf892..cd86f4e 100644 --- a/_config-local.sample.yml +++ b/_config-local.sample.yml @@ -1,3 +1,3 @@ -shared_baseurl: "http://tinymce.com" +shared_baseurl: "https://www.tinymce.com" gems: - jekyll-redirect-from diff --git a/init.sh b/init.sh new file mode 100755 index 0000000..b3e3a37 --- /dev/null +++ b/init.sh @@ -0,0 +1,33 @@ +#!/bin/bash + +set -e + +echo "" + +echo " > installing gems into ./vendor/bundle" +bundle install --path vendor/bundle + +if [[ -e "_config-local.yml" ]]; then + echo " > _config-local.yml present, skipping creation" +else + echo " > creating _config-local.yml" + cp _config-local.sample.yml _config-local.yml +fi + +echo " > downloading html includes 1/4" +curl -s https://www.tinymce.com/_docs/menu.html > _includes/menu.html + +echo " > downloading html includes 2/4" +curl -s https://www.tinymce.com/_docs/menu_demo.html > _includes/menu_demo.html + +echo " > downloading html includes 3/4" +curl -s https://www.tinymce.com/_docs/footer.html > _includes/footer.html + +echo " > downloading html includes 4/4" +curl -s https://www.tinymce.com/_docs/favicons.html > _includes/favicons.html + +echo " > creating dummy API ref data file" +echo [] > _data/nav_api.json + +echo " > done" +echo "" diff --git a/serve.sh b/serve.sh new file mode 100755 index 0000000..8eb2d08 --- /dev/null +++ b/serve.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +bundle exec jekyll serve --config _config.yml,_config-local.yml