Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add component.json to appease Bower.

  • Loading branch information...
commit d1239985231820dbe6a4fac58b293d97c679182d 1 parent 39347b4
@mbostock authored
Showing with 18 additions and 0 deletions.
  1. +6 −0 Makefile
  2. +5 −0 component.json
  3. +7 −0 src/component.js
View
6 Makefile
@@ -9,6 +9,7 @@ LOCALE ?= en_US
all: \
d3.v2.js \
d3.v2.min.js \
+ component.json \
package.json
# Modify this rule to build your own custom release.
@@ -237,6 +238,11 @@ d3%.js: Makefile
cat $(filter %.js,$^) | $(JS_BEAUTIFIER) > $@
@chmod a-w $@
+component.json: src/component.js
+ @rm -f $@
+ node src/component.js > $@
+ @chmod a-w $@
+
package.json: src/package.js
@rm -f $@
node src/package.js > $@
View
5 component.json
@@ -0,0 +1,5 @@
+{
+ "name": "d3",
+ "version": "2.10.1",
+ "main": "./d3.v2.js"
+}
View
7 src/component.js
@@ -0,0 +1,7 @@
+require("./core/core");
+
+require("util").puts(JSON.stringify({
+ "name": "d3",
+ "version": d3.version,
+ "main": "./d3.v2.js"
+}, null, 2));
Please sign in to comment.
Something went wrong with that request. Please try again.