https://github.com/zentered/makefile-example
Node.js Makefile and Environment
https://github.com/zentered/makefile-example
Last synced: 10 months ago
JSON representation
Node.js Makefile and Environment
- Host: GitHub
- URL: https://github.com/zentered/makefile-example
- Owner: zentered
- License: mit
- Created: 2018-01-25T13:55:01.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2021-06-10T15:54:10.000Z (about 5 years ago)
- Last Synced: 2025-07-10T11:13:22.875Z (12 months ago)
- Language: JavaScript
- Size: 5.86 KB
- Stars: 9
- Watchers: 11
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[]()
# Makefile for test and development environment
Full article: https://zentered.co/articles/makefile-for-node-js-developers/
This is an example on how we use the Makefile to simulate different environments.
## Development
`make dev` (NODE_ENV = development)
## Test
`make test` (NODE_ENV = test)
TAP version 13
# add
ok 1 1 + 1 = 2
# subtract
ok 2 1 - 1 = 0
1..2
# tests 2
# pass 2
# ok
## Watch
`make watch` (NODE_ENV = development)
change:test/index.js
TAP version 13
# add
add
ok 1 1 + 1 = 2
# subtract
subtract
ok 2 1 - 1 = 0
1..2
# tests 2
# pass 2
# ok