Skip to content

Commit

Permalink
Version 1.3.0.
Browse files Browse the repository at this point in the history
The version number is now derived from package.json.

UglifyJS and D3 dependencies have also been updated.
  • Loading branch information
jasondavies committed Aug 30, 2013
1 parent ec1383c commit 89bc6c3
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 46 deletions.
18 changes: 5 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
JS_TESTER = ./node_modules/vows/bin/vows
JS_UGLIFY = ./node_modules/uglify-js/bin/uglifyjs

.PHONY: test benchmark

all: crossfilter.min.js package.json
all: crossfilter.min.js

crossfilter.js: \
src/version.js \
src/identity.js \
src/permute.js \
src/bisect.js \
Expand All @@ -24,25 +20,21 @@ crossfilter.js: \

%.min.js: %.js Makefile
@rm -f $@
$(JS_UGLIFY) $< -c -m -o $@
node_modules/.bin/uglifyjs $< -c unsafe=true -m -o $@

%.js:
@rm -f $@
@echo '(function(exports){' > $@
@echo 'crossfilter.version = "'$(shell node -p 'require("./package.json").version')'";' >> $@
cat $(filter %.js,$^) >> $@
@echo '})(this);' >> $@
@chmod a-w $@

package.json: crossfilter.js src/package.js
@rm -f $@
node src/package.js > $@
@chmod a-w $@

clean:
rm -f crossfilter.js crossfilter.min.js package.json
rm -f crossfilter.js crossfilter.min.js

test: all
@$(JS_TESTER)
@npm test

benchmark: all
@node test/benchmark.js
3 changes: 2 additions & 1 deletion crossfilter.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
(function(exports){
crossfilter.version = "1.2.0";
crossfilter.version = "1.3.0";
function crossfilter_identity(d) {
return d;
}
Expand Down Expand Up @@ -1182,6 +1182,7 @@ function crossfilter() {
return g;
}

// Removes this dimension and associated groups and event listeners.
function dispose() {
dimensionGroups.forEach(function(group) { group.dispose(); });
var i = dataListeners.indexOf(preAdd);
Expand Down
2 changes: 1 addition & 1 deletion crossfilter.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "crossfilter",
"version": "1.2.0",
"version": "1.3.0",
"description": "Fast multidimensional filtering for coordinated views.",
"keywords": [
"square",
Expand Down Expand Up @@ -30,9 +30,9 @@
"url": "http://github.com/square/crossfilter.git"
},
"devDependencies": {
"d3": "3.0.x",
"d3": "3.3",
"vows": "0.7.0",
"uglify-js": "git://github.com/mishoo/UglifyJS2.git#aebafad4"
"uglify-js": "2.4.0"
},
"scripts": {
"test": "./node_modules/.bin/vows"
Expand Down
1 change: 1 addition & 0 deletions src/crossfilter.js
Original file line number Diff line number Diff line change
Expand Up @@ -667,6 +667,7 @@ function crossfilter() {
return g;
}

// Removes this dimension and associated groups and event listeners.
function dispose() {
dimensionGroups.forEach(function(group) { group.dispose(); });
var i = dataListeners.indexOf(preAdd);
Expand Down
Loading

0 comments on commit 89bc6c3

Please sign in to comment.