diff --git a/.gitignore b/.gitignore index 564b6438..b062732b 100644 --- a/.gitignore +++ b/.gitignore @@ -7,4 +7,5 @@ npm-debug.log *.iml .idea reports -cover \ No newline at end of file +cover +.tox diff --git a/README.md b/README.md index 6821dddd..3f6e6fd6 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ storyboard-webclient ==================== -A PoC WebClient for the OpenStack Storyboard project. +A WebClient for the OpenStack Storyboard project. ### Prerequisites: Quick build/CI @@ -13,16 +13,38 @@ A PoC WebClient for the OpenStack Storyboard project. ### Prerequisites: Dev -* NodeJS 0.10.24 or newer -* Grunt 0.4.2 -* bower 1.2.8 +* tox -### Command reference: +### Use tox: -**Bootstrap & build the CI environment** +**Run the test suite** -* `./bin/bootstrap.sh` -* `./bin/build.sh` +* `tox -enode test` + +**Run a local development server** + +* `tox -enode server` + +**Package the distro** + +* `tox -enode build` + +### For development. + +**Create the virtualenv** + +* `tox -enode build` + +**Activate the virtualenv** + +* `source .tox/node/bin/activate` + +**Update/refresh the javascript build and runtime dependencies** + +* `npm prune` +* `npm install` +* `bower prune` +* `bower install` **Run a local development server** @@ -34,4 +56,4 @@ A PoC WebClient for the OpenStack Storyboard project. **Package the distro** -`grunt build` \ No newline at end of file +`grunt build` diff --git a/tox.ini b/tox.ini new file mode 100644 index 00000000..77794e26 --- /dev/null +++ b/tox.ini @@ -0,0 +1,20 @@ +[tox] +minversion = 1.6 +envlist = node +skipsdist = True + +[testenv] +install_command = pip install -U {opts} {packages} +setenv = VIRTUAL_ENV={envdir} + LANG=en_US.UTF-8 + LANGUAGE=en_US:en + LC_ALL=C +deps = nodeenv + +[testenv:node] +commands = + nodeenv -p {envdir} --node=0.10.24 || true + npm install -g bower@1.2.8 grunt@0.4.2 grunt-cli@0.1.11 + npm install + bower install + grunt {posargs} \ No newline at end of file