From a73fa02c2cdb8ff229fafd0dbd65da4cf66e9ba6 Mon Sep 17 00:00:00 2001 From: Marcus Stade Date: Wed, 4 Nov 2015 18:12:06 +0100 Subject: [PATCH 1/7] Quick and dirty change to exclude rhumb from the build If we had more dependencies, we'd need to have a better story for this, but it'll do for now. --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 4e9fcf2..847c34a 100644 --- a/Makefile +++ b/Makefile @@ -11,7 +11,7 @@ v ?= patch build: node_modules $(LIB) lib/%.js: src/%.js @mkdir -p $(@D) - @browserify $< --standalone $(@F:%.js=%) | uglifyjs -o $@ + @browserify --exclude @websdk/rhumb $< --standalone $(@F:%.js=%) > $@ node_modules: package.json $(NPM) From 6a964c98cd16de17f7717f26f17c982cd525d047 Mon Sep 17 00:00:00 2001 From: Marcus Stade Date: Wed, 4 Nov 2015 18:37:38 +0100 Subject: [PATCH 2/7] Append `node_modules/.bin`, instead of prepending, to `$PATH` This fixes the broken build when npm 3 is used. --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 847c34a..acfe223 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -PATH := node_modules/.bin:$(PATH) +PATH := $(PATH):node_modules/.bin SHELL := /bin/bash SRC = $(wildcard src/*.js) From ed03c48928e2cbeea2200c0df721e79c1ea286f8 Mon Sep 17 00:00:00 2001 From: Marcus Stade Date: Thu, 5 Nov 2015 11:25:02 +0100 Subject: [PATCH 3/7] Remove node modules from PATH, see if this fixes Travis build We may just want to look into Wercker instead, so we can have a deterministic environment for the builds. --- Makefile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index acfe223..15d050c 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,3 @@ -PATH := $(PATH):node_modules/.bin SHELL := /bin/bash SRC = $(wildcard src/*.js) @@ -6,12 +5,14 @@ LIB = $(SRC:src/%.js=lib/%.js) TST = $(wildcard test/*.js) $(wildcard test/**/*.js) NPM = @npm install --local > /dev/null && touch node_modules +NM = node_modules/.bin + v ?= patch build: node_modules $(LIB) lib/%.js: src/%.js @mkdir -p $(@D) - @browserify --exclude @websdk/rhumb $< --standalone $(@F:%.js=%) > $@ + @$(NM)/browserify --exclude @websdk/rhumb $< --standalone $(@F:%.js=%) > $@ node_modules: package.json $(NPM) @@ -19,16 +20,16 @@ node_modules/%: $(NPM) test: build - @tape $(TST) + @$(NM)/tape $(TST) .nyc_output: node_modules - @nyc $(MAKE) test + @$(NM)/nyc $(MAKE) test coverage: .nyc_output - @nyc report --reporter=text-lcov | coveralls + @$(NM)/nyc report --reporter=text-lcov | $(NM)/coveralls dev: node_modules - @nodemon -q -x "(clear; nyc $(MAKE) test | tap-dot && nyc report) || true" + @$(NM)/nodemon -q -x "(clear; $(NM)/nyc $(MAKE) test | $(NM)/tap-dot && $(NM)/nyc report) || true" release: clean build test @npm version $(v) From 5386d17db0623b05e7b09bcb5318e02d2dd02eb6 Mon Sep 17 00:00:00 2001 From: Marcus Stade Date: Thu, 5 Nov 2015 11:38:59 +0100 Subject: [PATCH 4/7] Print PATH so we can tell WTH travis is doing --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index 0bb834c..421bf6f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,6 +4,7 @@ node_js: - "iojs" - "4" +before_install: echo "PATH = $PATH" install: make clean build script: make test after_success: make coverage \ No newline at end of file From d9ed8fe283c2f0d0448795b5b63a3bce33ffc1f0 Mon Sep 17 00:00:00 2001 From: Marcus Stade Date: Thu, 5 Nov 2015 13:55:32 +0100 Subject: [PATCH 5/7] Clean PATH env var of ./node_modules/.bin --- Makefile | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index 15d050c..525e397 100644 --- a/Makefile +++ b/Makefile @@ -1,18 +1,17 @@ SHELL := /bin/bash +PATH := $(shell echo $${PATH//\.\/node_modules\/\.bin:/}):node_modules/.bin SRC = $(wildcard src/*.js) LIB = $(SRC:src/%.js=lib/%.js) TST = $(wildcard test/*.js) $(wildcard test/**/*.js) NPM = @npm install --local > /dev/null && touch node_modules -NM = node_modules/.bin - v ?= patch build: node_modules $(LIB) lib/%.js: src/%.js @mkdir -p $(@D) - @$(NM)/browserify --exclude @websdk/rhumb $< --standalone $(@F:%.js=%) > $@ + @browserify --exclude @websdk/rhumb $< --standalone $(@F:%.js=%) > $@ node_modules: package.json $(NPM) @@ -20,16 +19,16 @@ node_modules/%: $(NPM) test: build - @$(NM)/tape $(TST) + @tape $(TST) .nyc_output: node_modules - @$(NM)/nyc $(MAKE) test + @nyc $(MAKE) test coverage: .nyc_output - @$(NM)/nyc report --reporter=text-lcov | $(NM)/coveralls + @nyc report --reporter=text-lcov | coveralls dev: node_modules - @$(NM)/nodemon -q -x "(clear; $(NM)/nyc $(MAKE) test | $(NM)/tap-dot && $(NM)/nyc report) || true" + @nodemon -q -x "(clear; nyc $(MAKE) test | tap-dot && nyc report) || true" release: clean build test @npm version $(v) From 950d84819f398272cb3c3a328a8a2c8097c2f61d Mon Sep 17 00:00:00 2001 From: Marcus Stade Date: Thu, 5 Nov 2015 14:04:03 +0100 Subject: [PATCH 6/7] Remove PATH echoing in travis config --- .travis.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 421bf6f..0bb834c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,7 +4,6 @@ node_js: - "iojs" - "4" -before_install: echo "PATH = $PATH" install: make clean build script: make test after_success: make coverage \ No newline at end of file From a05532260a996b4ed2bbfe7ffe35bceb817ee439 Mon Sep 17 00:00:00 2001 From: Marcus Stade Date: Thu, 5 Nov 2015 14:05:10 +0100 Subject: [PATCH 7/7] 0.10.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index e87431a..bda91f5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@websdk/nap", - "version": "0.9.8", + "version": "0.10.0", "description": "Organizing applications into resources", "main": "lib/nap.js", "devDependencies": {