-
Notifications
You must be signed in to change notification settings - Fork 19
/
Makefile
48 lines (39 loc) · 953 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
BOOK_NAME := tke-handbook
BOOK_OUTPUT := _book
.PHONY: build
build:
gitbook build . $(BOOK_OUTPUT)
.PHONY: serve
serve:
gitbook serve . $(BOOK_OUTPUT)
.PHONY: epub
epub:
gitbook epub . $(BOOK_NAME).epub
.PHONY: pdf
pdf:
gitbook pdf . $(BOOK_NAME).pdf
.PHONY: mobi
mobi:
gitbook mobi . $(BOOK_NAME).mobi
.PHONY: install
install:
npm install gitbook-cli -g
gitbook install
.PHONY: clean
clean:
rm -rf $(BOOK_OUTPUT)
.PHONY: spell
spell:
go get github.com/client9/misspell/cmd/misspell
git ls-files | xargs misspell -error -o stderr
.PHONY: help
help:
@echo "Help for make"
@echo "make - Build the book"
@echo "make build - Build the book"
@echo "make serve - Serving the book on localhost:4000"
@echo "make install - Install gitbook and plugins"
@echo "make epub - Build epub book"
@echo "make pdf - Build pdf book"
@echo "make spell - Check splling"
@echo "make clean - Remove generated files"