Skip to content

Commit

Permalink
Improved make clean target to be more resilient.
Browse files Browse the repository at this point in the history
  • Loading branch information
ahonor committed Nov 30, 2010
1 parent afd5de7 commit 750c812
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 33 deletions.
4 changes: 2 additions & 2 deletions docs/en/Makefile
Expand Up @@ -18,9 +18,9 @@ $(DIST)/html : dist

html : $(DIST)/html
$(ECHO) Generating HTML book
$(PANDOC) --number-sections --toc -s 0[1-9]-*/*.md --css=$(CSS) --template=templates/html.template --include-before=templates/before.html --include-after=templates/after.html -o $(DIST)/html/RunDeck-Guide.html
$(PANDOC) --number-sections --toc -s 0[0-9]-*/*.md --css=$(CSS) --template=templates/html.template --include-before=templates/before.html --include-after=templates/after.html -o $(DIST)/html/RunDeck-Guide.html
cp $(CSS) $(DIST)/html

clean :
rm -r $(DIST)
rm -fr $(DIST)
$(MAKE) -C manpages clean
35 changes: 6 additions & 29 deletions docs/en/manpages/Makefile
@@ -1,34 +1,11 @@
include ../../Makefile.inc

DIST = ../dist
.SUFFIXES: .1.gz .1
DIRS = man1 man5

manpages: dispatch.1.gz job-v20.1.gz rd-jobs.1.gz rd-options.1.gz rd-setup.1.gz rd-queue.1.gz resource-v10.1.gz run.1

rundeck-guide.1:
pandoc -s -w man ../0[1-9]-*/*.md -o rundeck-guide.1

%.1.gz: %.1
gzip < $< > $@

%.1:
pandoc -s -w man $@.md -o $@

PAGES = dispatch.1 job-v20.1 rd-jobs.1 rd-options.1 rd-setup.1 rd-queue.1 resource-v10.1 run.1

publish : roff html

roff :
$(ECHO) Generating system man pages
mkdir -p $(DIST)/man/man1
-for f in $(PAGES); do ( $(PANDOC) -s -w man $$f.md -o $(DIST)/man/man1/$$f; ); done

html :
$(ECHO) Generating html for system man pages
mkdir -p $(DIST)/html
-for f in $(PAGES); do ( $(PANDOC) -s -w html $$f.md -o $(DIST)/html/$$f.html; ); done

clean :
rm *.1 *.1.gz
.PHONY: all clean

all : $(DIRS)
$(MAKE) -C $<

clean : $(DIRS)
$(MAKE) -C $< clean
2 changes: 1 addition & 1 deletion docs/en/manpages/man1/Makefile
Expand Up @@ -29,6 +29,6 @@ html :
-for f in $(PAGES); do ( $(PANDOC) -s -w html $$f.md -o $(DIST)/html/$$f.html; ); done

clean :
rm *.1 *.1.gz
rm -f *.1 *.1.gz


2 changes: 1 addition & 1 deletion docs/en/manpages/man5/Makefile
Expand Up @@ -26,6 +26,6 @@ html :
-for f in $(PAGES); do ( $(PANDOC) -s -w html $$f.md -o $(DIST)/html/$$f.html; ); done

clean :
rm *.5 *.5.gz
rm -f *.5 *.5.gz


0 comments on commit 750c812

Please sign in to comment.