74
74
# translate txt docs to html
76
76
txt_files := $(wildcard $(addsuffix /*.txt, $(doc_dir))) doc/bzr_man.txt
77
htm_files := $(patsubst %.txt, %.htm, $(txt_files))
77
htm_files := $(patsubst %.txt, %.html, $(txt_files))
78
78
dev_txt_files := $(wildcard $(addsuffix /*.txt, doc/developers))
79
dev_htm_files := $(patsubst %.txt, %.htm, $(dev_txt_files))
79
dev_htm_files := $(patsubst %.txt, %.html, $(dev_txt_files))
81
81
pretty-html-docs: pretty_files
84
84
python -c "import os; os.mkdir('$(PRETTYDIR)')"
86
pretty_files: $(patsubst doc/%.txt, $(PRETTYDIR)/%.htm, $(txt_files))
88
doc/developers/%.htm: doc/developers/%.txt
89
python tools/rst2html.py --link-stylesheet --stylesheet=../default.css --footnote-references=superscript $< $@
91
doc/developers/HACKING.htm: doc/developers/HACKING
92
python tools/rst2html.py --link-stylesheet --stylesheet=../default.css --footnote-references=superscript $< $@
86
pretty_files: $(patsubst doc/%.txt, $(PRETTYDIR)/%.html, $(txt_files))
88
doc/developers/%.html: doc/developers/%.txt
89
python tools/rst2html.py --link-stylesheet --stylesheet=../default.css --footnote-references=superscript $< $@
95
92
python tools/rst2html.py --link-stylesheet --stylesheet=default.css --footnote-references=superscript $< $@
97
$(PRETTYDIR)/%.htm: pretty_docs doc/%.txt
94
$(PRETTYDIR)/%.html: pretty_docs doc/%.txt
98
95
python tools/rst2prettyhtml.py doc/bazaar-vcs.org.kid doc/$*.txt \
101
98
MAN_DEPENDENCIES = bzrlib/builtins.py \
102
99
bzrlib/bundle/commands.py \
113
110
man1/bzr.1: $(MAN_DEPENDENCIES)
114
111
python generate_docs.py -o $@ man
116
ALL_DOCS = $(htm_files) $(MAN_PAGES) doc/developers/HACKING.htm $(dev_htm_files) doc/developers/performance.png
113
ALL_DOCS = $(htm_files) $(MAN_PAGES) $(dev_htm_files) doc/developers/performance.png
117
114
docs: $(ALL_DOCS)
120
117
python tools/win32/ostools.py copytodir $(htm_files) \
121
118
doc/default.css NEWS README \
122
119
win32_bzr.exe/doc
123
python tools/win32/ostools.py copytodir doc/developers/HACKING.htm \
120
python tools/win32/ostools.py copytodir $(dev_htm_files) \
125
121
win32_bzr.exe/doc/developers
127
123
# clean produced docs
160
156
# clean on win32 all installer-related files and directories
157
clean-win32: clean-docs
162
158
python tools/win32/ostools.py remove build
163
159
python tools/win32/ostools.py remove win32_bzr.exe
164
160
python tools/win32/ostools.py remove py2exe.log
165
python tools/win32/ostools.py remove doc/*.htm
166
python tools/win32/ostools.py remove doc/developers/*.htm
167
161
python tools/win32/ostools.py remove doc/bzr_man.txt
168
162
python tools/win32/ostools.py remove tools/win32/bzr.iss
169
163
python tools/win32/ostools.py remove bzr-setup*.exe