Skip to content
Permalink
Browse files
clean up makefile
  • Loading branch information
Qix- committed Sep 11, 2018
1 parent 833b6f8 commit 62822f12668e8a0b1d1a4fd5a1c2fce1d8715da3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 27 deletions.
@@ -15,22 +15,16 @@ YARN ?= $(shell which yarn)
PKG ?= $(if $(YARN),$(YARN),$(NODE) $(shell which npm))
BROWSERIFY ?= $(NODE) $(BIN)/browserify

install: node_modules
all: lint test

browser: dist/debug.js

node_modules: package.json
@NODE_ENV= $(PKG) install
@touch node_modules

dist/debug.js: src/*.js node_modules
dist/debug.js: src/*.js
@mkdir -p dist
@$(BROWSERIFY) \
--standalone debug \
. > dist/debug.js
@$(BROWSERIFY) --standalone debug . > dist/debug.js

lint:
@eslint *.js src/*.js
@xo

test-node:
@istanbul cover node_modules/mocha/bin/_mocha -- test/**.js
@@ -40,19 +34,9 @@ test-browser:
@$(MAKE) browser
@karma start --single-run

test-all:
@concurrently \
"make test-node" \
"make test-browser"

test:
@if [ "x$(BROWSER)" = "x" ]; then \
$(MAKE) test-node; \
else \
$(MAKE) test-browser; \
fi
test: test-node test-browser

clean:
rimraf dist coverage
rm -rf dist coverage

.PHONY: browser install clean lint test test-all test-node test-browser
.PHONY: all browser install clean lint test test-node test-browser
@@ -6,9 +6,6 @@
"url": "git://github.com/visionmedia/debug.git"
},
"description": "small debugging utility",
"scripts": {
"test": "xo && mocha"
},
"keywords": [
"debug",
"log",
@@ -28,7 +25,6 @@
"chai": "^3.5.0",
"concurrently": "^3.1.0",
"coveralls": "^3.0.2",
"eslint": "^3.12.1",
"istanbul": "^0.4.5",
"karma": "^3.0.0",
"karma-chai": "^0.1.0",

0 comments on commit 62822f1

Please sign in to comment.