From ec20bd4d44887061373f32c630fe0161a7e5fb43 Mon Sep 17 00:00:00 2001 From: Tim Branyen Date: Thu, 8 May 2014 22:37:13 -0400 Subject: [PATCH] Build UMD compatible standalone with Browserify. --- .travis.yml | 1 + CONTRIBUTING.md | 5 ----- Gruntfile.coffee | 3 ++- README.md | 11 ++--------- build/tasks/browserify.coffee | 9 +++++++++ build/tasks/synchronizer.coffee | 10 ---------- package.json | 5 ++++- 7 files changed, 18 insertions(+), 26 deletions(-) create mode 100644 build/tasks/browserify.coffee delete mode 100644 build/tasks/synchronizer.coffee diff --git a/.travis.yml b/.travis.yml index c8e0504..2034445 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,6 +6,7 @@ node_js: - 0.11 before_script: + - npm install -g npm@1.4.3 - npm install -g grunt-cli bower - npm install - bower install diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index c21142b..2ddb44e 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -25,11 +25,6 @@ project community instead of a sole proprietorship. ensure everyone is on board with the change and so you don't spend time writing a fantastic patch we cannot accept. * Provide a description of what the patch is/does. -* Provide unit tests in the correct file: - + `test/comments.js` for changes related to comments. - + `test/common.js` for changes that affect how Combyne is run. - + `test/properties.js` for changes that affect how the properties feature - works. * Make sure you open the pull request onto the `wip` branch and not `master` for requests that break the API or add significant functionality changes. * Open pull requests on `master` only with bug fixes and patch related updates. diff --git a/Gruntfile.coffee b/Gruntfile.coffee index eedf821..3340de9 100644 --- a/Gruntfile.coffee +++ b/Gruntfile.coffee @@ -4,6 +4,7 @@ module.exports = -> @registerTask "test", [ "jshint" "jscs" + "browserify" "simplemocha" "karma:run" ] @@ -11,6 +12,6 @@ module.exports = -> @registerTask "default", [ "jshint" "jscs" - #"synchronizer" + "browserify" "karma:daemon" ] diff --git a/README.md b/README.md index 1fedb76..3d5c63f 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,8 @@ Combyne > A template engine that works the way you expect. +**Stable: 0.3.0** + [![Build Status](https://travis-ci.org/tbranyen/combyne.png?branch=master)](https://travis-ci.org/tbranyen/combyne) [![Coverage Status](https://coveralls.io/repos/tbranyen/combyne/badge.png?branch=master)](https://coveralls.io/r/tbranyen/combyne?branch=master) @@ -48,15 +50,6 @@ in your markup: ``` -### Additional details. ### - -#### Compatibility. #### - -__Desktop:__ IE 9+, Chrome 13+, Opera 11+, FireFox 3.6+, and Safari 5+. - - -__Mobile:__ Android Browser 2.3.4+ , Opera 9.80+ , FireFox Beta, and iPad. - ## Basic usage. ## ``` javascript diff --git a/build/tasks/browserify.coffee b/build/tasks/browserify.coffee new file mode 100644 index 0000000..fd7f346 --- /dev/null +++ b/build/tasks/browserify.coffee @@ -0,0 +1,9 @@ +module.exports = -> + @loadNpmTasks "grunt-browserify" + + @config "browserify", + options: + transform: ["deamdify"] + standalone: "combyne" + + "dist/combyne.js": "lib/index.js" diff --git a/build/tasks/synchronizer.coffee b/build/tasks/synchronizer.coffee deleted file mode 100644 index aeb28b7..0000000 --- a/build/tasks/synchronizer.coffee +++ /dev/null @@ -1,10 +0,0 @@ -module.exports = -> -# @loadNpmTasks "grunt-synchronizer" - - @config "synchronizer", - options: - name: "combyne" - - build: - files: - "dist/combyne.js": "lib/index.js" diff --git a/package.json b/package.json index 875162a..b1a8326 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,10 @@ "grunt-karma-coveralls": "~2.4.4", "karma-mocha": "~0.1.0", "karma-coverage": "~0.2.1", - "karma-phantomjs-launcher": "~0.1.4" + "karma-phantomjs-launcher": "~0.1.4", + "browserify": "~3.46.0", + "grunt-browserify": "~2.0.8", + "deamdify": "~0.1.1" }, "scripts": { "test": "grunt test coveralls"