From b96c1752299c130601a11e91e1847552b5db300b Mon Sep 17 00:00:00 2001 From: Radek Stepan Date: Wed, 16 Oct 2013 12:10:53 +0100 Subject: [PATCH] publish script --- Makefile | 12 ++++++++++++ README.md | 10 ++++++++++ 2 files changed, 22 insertions(+) diff --git a/Makefile b/Makefile index 6506cd0..2db4013 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,16 @@ test: ./node_modules/.bin/mocha --compilers coffee:coffee-script --reporter spec --ui exports --bail +publish: + git checkout gh-pages + git show master:build/build.js > build.js + git show master:build/build.css > build.css + git add . + @status=$$(git status --porcelain); \ + if ! test "x$${status}" = x; then \ + git commit -m 'publish latest build to gh-pages'; \ + git push -u origin gh-pages; \ + fi + git checkout master + .PHONY: test \ No newline at end of file diff --git a/README.md b/README.md index 717deb9..56b9dca 100644 --- a/README.md +++ b/README.md @@ -99,6 +99,16 @@ $ npm install apps-b-builder -g $ apps-b build ./src/ ./build/ ``` +##Publish It + +If you would like to track changes to build files in `gh-pages` branch, execute the following command: + +```bash +$ make publish +``` + +It will checkout the `gh-pages` branch, copy the two build files from master and provided we have changed them locally, make a commit a push them to remote. + ##Test It ```bash