@matheusbsbs / matheus-bagliano / commits / 4392da4d5d
Fork 0

Documentation: support manual section (5) - file formats.

Signed-off-by: Junio C Hamano <junkio@cox.net>

Junio C Hamano committed Apr 19, 2007 at 20:47 UTC 4392da4d5d7585a9defa6869517cb354f7460f35
2 files changed +15 -7
Documentation/Makefile
+13 -6
@@ -2,9 +2,10 @@ MAN1_TXT= \
2 $(filter-out $(addsuffix .txt, $(ARTICLES) $(SP_ARTICLES)), \
3 $(wildcard git-*.txt)) \
4 gitk.txt
5 +MAN5_TXT=
6 MAN7_TXT=git.txt
7
7 -DOC_HTML=$(patsubst %.txt,%.html,$(MAN1_TXT) $(MAN7_TXT))
8 +DOC_HTML=$(patsubst %.txt,%.html,$(MAN1_TXT) $(MAN5_TXT) $(MAN7_TXT))
9
10 ARTICLES = tutorial
11 ARTICLES += tutorial-2
@@ -23,12 +24,14 @@ SP_ARTICLES = howto/revert-branch-rebase user-manual
24 DOC_HTML += $(patsubst %,%.html,$(ARTICLES) $(SP_ARTICLES))
25
26 DOC_MAN1=$(patsubst %.txt,%.1,$(MAN1_TXT))
27 +DOC_MAN5=$(patsubst %.txt,%.5,$(MAN1_TXT))
28 DOC_MAN7=$(patsubst %.txt,%.7,$(MAN7_TXT))
29
30 prefix?=$(HOME)
31 bindir?=$(prefix)/bin
32 mandir?=$(prefix)/man
33 man1dir=$(mandir)/man1
34 +man5dir=$(mandir)/man5
35 man7dir=$(mandir)/man7
36 # DESTDIR=
37
@@ -53,15 +56,19 @@ all: html man
56
57 html: $(DOC_HTML)
58
56 -$(DOC_HTML) $(DOC_MAN1) $(DOC_MAN7): asciidoc.conf
59 +$(DOC_HTML) $(DOC_MAN1) $(DOC_MAN5) $(DOC_MAN7): asciidoc.conf
60
58 -man: man1 man7
61 +man: man1 man5 man7
62 man1: $(DOC_MAN1)
63 +man5: $(DOC_MAN5)
64 man7: $(DOC_MAN7)
65
66 install: man
63 - $(INSTALL) -d -m755 $(DESTDIR)$(man1dir) $(DESTDIR)$(man7dir)
67 + $(INSTALL) -d -m755 $(DESTDIR)$(man1dir)
68 + $(INSTALL) -d -m755 $(DESTDIR)$(man5dir)
69 + $(INSTALL) -d -m755 $(DESTDIR)$(man7dir)
70 $(INSTALL) -m644 $(DOC_MAN1) $(DESTDIR)$(man1dir)
71 + : $(INSTALL) -m644 $(DOC_MAN5) $(DESTDIR)$(man5dir)
72 $(INSTALL) -m644 $(DOC_MAN7) $(DESTDIR)$(man7dir)
73
74
@@ -99,7 +106,7 @@ cmd-list.made: cmd-list.perl $(MAN1_TXT)
106 git.7 git.html: git.txt core-intro.txt
107
108 clean:
102 - rm -f *.xml *.xml+ *.html *.html+ *.1 *.7 howto-index.txt howto/*.html doc.dep
109 + rm -f *.xml *.xml+ *.html *.html+ *.1 *.5 *.7 howto-index.txt howto/*.html doc.dep
110 rm -f $(cmds_txt) *.made
111
112 %.html : %.txt
@@ -109,7 +116,7 @@ clean:
116 sed -e 's/@@GIT_VERSION@@/$(GIT_VERSION)/g' >$@+
117 mv $@+ $@
118
112 -%.1 %.7 : %.xml
119 +%.1 %.5 %.7 : %.xml
120 xmlto -m callouts.xsl man $<
121
122 %.xml : %.txt
Makefile
+2 -1
@@ -1030,9 +1030,10 @@ dist-doc:
1030 gzip -n -9 -f $(htmldocs).tar
1031 :
1032 rm -fr .doc-tmp-dir
1033 - mkdir .doc-tmp-dir .doc-tmp-dir/man1 .doc-tmp-dir/man7
1033 + mkdir -p .doc-tmp-dir/man1 .doc-tmp-dir/man5 .doc-tmp-dir/man7
1034 $(MAKE) -C Documentation DESTDIR=./ \
1035 man1dir=../.doc-tmp-dir/man1 \
1036 + man5dir=../.doc-tmp-dir/man5 \
1037 man7dir=../.doc-tmp-dir/man7 \
1038 install
1039 cd .doc-tmp-dir && $(TAR) cf ../$(manpages).tar .