Skip to content
Newer
Older
100644 65 lines (46 sloc) 1.35 KB
64b4d65 explicitly set bash as the shell since the makefile uses bash-isms
gflarity authored Feb 22, 2011
1 SHELL = bash
2
de338f9 @isaacs Support subfolders in the man/doc files
isaacs authored Jul 5, 2010
3 docs = $(shell find doc -name '*.md' \
4 |sed 's|.md|.1|g' \
0e151fc @isaacs build submodules in make process
isaacs authored Feb 18, 2011
5 |sed 's|doc/|man1/|g' )
6
de338f9 @isaacs Support subfolders in the man/doc files
isaacs authored Jul 5, 2010
7 doc_subfolders = $(shell find doc -type d \
0e151fc @isaacs build submodules in make process
isaacs authored Feb 18, 2011
8 |sed 's|doc/|man1/|g' )
9
d7d8662 @isaacs Closes GH-609 `make install` installs current, not latest
isaacs authored Feb 22, 2011
10 # This is the default make target.
11 # Since 'make' typically does non-installation build stuff,
12 # it seems appropriate.
0e151fc @isaacs build submodules in make process
isaacs authored Feb 18, 2011
13 submodules:
007fedb @isaacs Update submodules recursively in make
isaacs authored Jul 16, 2011
14 ! [ -d .git ] || git submodule update --init --recursive
86c296f @isaacs Add commands to make man files from the docs.
isaacs authored Apr 25, 2010
15
d7d8662 @isaacs Closes GH-609 `make install` installs current, not latest
isaacs authored Feb 23, 2011
16 latest: submodules
17 @echo "Installing latest published npm"
18 @echo "Use 'make install' or 'make link' to install the code"
19 @echo "in this folder that you're looking at right now."
4325dcc @isaacs fix make latest
isaacs authored Jul 16, 2011
20 node cli.js install -g -f npm
743d387 @isaacs Improve install process.
isaacs authored May 10, 2010
21
d7d8662 @isaacs Closes GH-609 `make install` installs current, not latest
isaacs authored Feb 23, 2011
22 install: submodules
364dfc6 @isaacs Clobber in Makefile
isaacs authored Apr 4, 2011
23 node cli.js install -g -f
743d387 @isaacs Improve install process.
isaacs authored May 10, 2010
24
d7d8662 @isaacs Closes GH-609 `make install` installs current, not latest
isaacs authored Feb 23, 2011
25 # backwards compat
26 dev: install
27
db9ee01 @isaacs clean when linking
isaacs authored Oct 28, 2010
28 link: uninstall
364dfc6 @isaacs Clobber in Makefile
isaacs authored Apr 4, 2011
29 node cli.js link -f
e0c6abb @isaacs Add 'clean' make target
isaacs authored Sep 2, 2010
30
31 clean: uninstall
743d387 @isaacs Improve install process.
isaacs authored May 10, 2010
32
0e151fc @isaacs build submodules in make process
isaacs authored Feb 18, 2011
33 uninstall: submodules
e7d403e @isaacs Change the way that cli.js is run to hopefully work on Cygwin
isaacs authored Aug 11, 2010
34 node cli.js cache clean
4f0d334 @isaacs Less warning, better style
isaacs authored Apr 21, 2011
35 node cli.js rm npm -g -f --loglevel error
86c296f @isaacs Add commands to make man files from the docs.
isaacs authored Apr 25, 2010
36
dbee5c3 @isaacs Change the way npm help works, so that it will work with man programs…
isaacs authored Sep 21, 2010
37 man: man1
38
39 man1: $(doc_subfolders)
4f0d334 @isaacs Less warning, better style
isaacs authored Apr 21, 2011
40 [ -d man1 ] || mkdir -p man1
86c296f @isaacs Add commands to make man files from the docs.
isaacs authored Apr 25, 2010
41
dbee5c3 @isaacs Change the way npm help works, so that it will work with man programs…
isaacs authored Sep 21, 2010
42 doc: man1 $(docs)
c638e80 @isaacs Add a makefile to build the man page.
isaacs authored Apr 24, 2010
43
f2ccd17 @isaacs Use ronnjs instead of the ronn rubygem to build docs
isaacs authored Aug 18, 2010
44 # use `npm install ronn` for this to work.
dbee5c3 @isaacs Change the way npm help works, so that it will work with man programs…
isaacs authored Sep 21, 2010
45 man1/%.1: doc/%.md
7d44c11 @isaacs Don't install ronn for every doc
isaacs authored Mar 11, 2011
46 @[ -x ./node_modules/.bin/ronn ] || node cli.js install ronn
8945848 @isaacs A make command that works
isaacs authored Mar 10, 2011
47 ./node_modules/.bin/ronn --roff $< > $@
c638e80 @isaacs Add a makefile to build the man page.
isaacs authored Apr 24, 2010
48
dbee5c3 @isaacs Change the way npm help works, so that it will work with man programs…
isaacs authored Sep 21, 2010
49 man1/%/: doc/%/
4f0d334 @isaacs Less warning, better style
isaacs authored Apr 21, 2011
50 @[ -d $@ ] || mkdir -p $@
de338f9 @isaacs Support subfolders in the man/doc files
isaacs authored Jul 5, 2010
51
0e151fc @isaacs build submodules in make process
isaacs authored Feb 18, 2011
52 test: submodules
176f12e @isaacs Move test command into package.json
isaacs authored Apr 13, 2011
53 node cli.js test
90c9ec8 @isaacs Make test (quietly)
isaacs authored Jul 3, 2010
54
5846adf @isaacs version bumper
isaacs authored Jan 11, 2011
55 version: link
4f0d334 @isaacs Less warning, better style
isaacs authored Apr 21, 2011
56 git add package.json &&\
57 git ci -m v$(shell npm -v)
5846adf @isaacs version bumper
isaacs authored Jan 11, 2011
58
59 publish: link
4f0d334 @isaacs Less warning, better style
isaacs authored Apr 21, 2011
60 git tag -s -m v$(shell npm -v) v$(shell npm -v) &&\
61 git push origin master &&\
62 npm publish
2d27e74 @isaacs Add a 'publish' make target
isaacs authored Jan 10, 2011
63
d7d8662 @isaacs Closes GH-609 `make install` installs current, not latest
isaacs authored Feb 23, 2011
64 .PHONY: latest install dev link doc clean uninstall test man
Something went wrong with that request. Please try again.