{"thread":{"id":"32533","subject":"[PATCH] Documentation: fix man page dependency on asciidoc.conf","startedAt":"2013-01-05T16:00:17Z","lastAt":"2013-01-06T23:19:43Z","messageCount":6,"participants":["John Keeping","Jonathan Nieder","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"206033","messageId":"20130105160017.GD6440@serenity.lan","threadId":"32533","inReplyTo":null,"subject":"[PATCH] Documentation: fix man page dependency on asciidoc.conf","fromName":"John Keeping","fromEmail":"john@keeping.me.uk","sentAt":"2013-01-05T16:00:17Z","receivedAt":"2013-01-05T16:00:17Z","isPatch":true,"sender":{"key":"john@keeping.me.uk","avatar":"https://avatars.githubusercontent.com/u/1702081?v=4"},"body":"When building manual pages, the source text is transformed to XML with\nAsciiDoc before the man pages are generated from the XML with xmlto.\n\nFix the dependency in the Makefile so that the XML files are rebuilt\nwhen asciidoc.conf changes and not just the manual pages from unchanged\nXML.\n\nSigned-off-by: John Keeping <john@keeping.me.uk>\n---\n Documentation/Makefile | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/Documentation/Makefile b/Documentation/Makefile\nindex e53d333..71d2b4a 100644\n--- a/Documentation/Makefile\n+++ b/Documentation/Makefile\n@@ -178,7 +178,7 @@ all: html man\n \n html: $(DOC_HTML)\n \n-$(DOC_HTML) $(DOC_MAN1) $(DOC_MAN5) $(DOC_MAN7): asciidoc.conf\n+$(DOC_HTML) $(MAN_XML): asciidoc.conf\n \n man: man1 man5 man7\n man1: $(DOC_MAN1)\n-- \n1.8.0.2\n"},{"id":"206073","messageId":"20130105232800.GF3247@elie.Belkin","threadId":"32533","inReplyTo":"20130105160017.GD6440@serenity.lan","subject":"Re: [PATCH] Documentation: fix man page dependency on asciidoc.conf","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2013-01-05T23:28:00Z","receivedAt":"2013-01-05T23:28:00Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"John Keeping wrote:\n\n> When building manual pages, the source text is transformed to XML with\n> AsciiDoc before the man pages are generated from the XML with xmlto.\n>\n> Fix the dependency in the Makefile so that the XML files are rebuilt\n> when asciidoc.conf changes and not just the manual pages from unchanged\n> XML.\n\nGood catch, thanks.\n\nWould something like the following make sense, to make it more obvious\nhow the dependency needs to be adjusted if we change the $(ASCIIDOC)\ncommand line for some reason?\n\ndiff --git i/Documentation/Makefile w/Documentation/Makefile\nindex e53d333e..971977b8 100644\n--- i/Documentation/Makefile\n+++ w/Documentation/Makefile\n@@ -178,8 +178,6 @@ all: html man\n \n html: $(DOC_HTML)\n \n-$(DOC_HTML) $(DOC_MAN1) $(DOC_MAN5) $(DOC_MAN7): asciidoc.conf\n-\n man: man1 man5 man7\n man1: $(DOC_MAN1)\n man5: $(DOC_MAN5)\n@@ -257,7 +255,7 @@ clean:\n \t$(RM) $(cmds_txt) *.made\n \t$(RM) manpage-base-url.xsl\n \n-$(MAN_HTML): %.html : %.txt\n+$(MAN_HTML): %.html : %.txt asciidoc.conf\n \t$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \\\n \t$(ASCIIDOC) -b xhtml11 -d manpage -f asciidoc.conf \\\n \t\t$(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) -o $@+ $< && \\\n@@ -270,7 +268,7 @@ manpage-base-url.xsl: manpage-base-url.xsl.in\n \t$(QUIET_XMLTO)$(RM) $@ && \\\n \t$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $<\n \n-%.xml : %.txt\n+%.xml : %.txt asciidoc.conf\n \t$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \\\n \t$(ASCIIDOC) -b docbook -d manpage -f asciidoc.conf \\\n \t\t$(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) -o $@+ $< && \\\n@@ -286,7 +284,7 @@ technical/api-index.txt: technical/api-index-skel.txt \\\n \t$(QUIET_GEN)cd technical && '$(SHELL_PATH_SQ)' ./api-index.sh\n \n technical/%.html: ASCIIDOC_EXTRA += -a git-relative-html-prefix=../\n-$(patsubst %,%.html,$(API_DOCS) technical/api-index $(TECH_DOCS)): %.html : %.txt\n+$(patsubst %,%.html,$(API_DOCS) technical/api-index $(TECH_DOCS)): %.html : %.txt asciidoc.conf\n \t$(QUIET_ASCIIDOC)$(ASCIIDOC) -b xhtml11 -f asciidoc.conf \\\n \t\t$(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) $*.txt\n \ndiff --git i/t/test-terminal.perl w/t/test-terminal.perl\nindex 10172aee..1fb373f2 100755\n--- i/t/test-terminal.perl\n+++ w/t/test-terminal.perl\n@@ -31,7 +31,7 @@ sub finish_child {\n \t} elsif ($? & 127) {\n \t\tmy $code = $? & 127;\n \t\twarn \"died of signal $code\";\n-\t\treturn $code - 128;\n+\t\treturn $code + 128;\n \t} else {\n \t\treturn $? >> 8;\n \t}\n"},{"id":"206112","messageId":"7vbod2pzxd.fsf@alter.siamese.dyndns.org","threadId":"32533","inReplyTo":"20130105232800.GF3247@elie.Belkin","subject":"Re: [PATCH] Documentation: fix man page dependency on asciidoc.conf","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2013-01-06T06:51:10Z","receivedAt":"2013-01-06T06:51:10Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jonathan Nieder <jrnieder@gmail.com> writes:\n\n> John Keeping wrote:\n>\n>> When building manual pages, the source text is transformed to XML with\n>> AsciiDoc before the man pages are generated from the XML with xmlto.\n>>\n>> Fix the dependency in the Makefile so that the XML files are rebuilt\n>> when asciidoc.conf changes and not just the manual pages from unchanged\n>> XML.\n>\n> Good catch, thanks.\n>\n> Would something like the following make sense, to make it more obvious\n> how the dependency needs to be adjusted if we change the $(ASCIIDOC)\n> command line for some reason?\n\nI think such a more explicit approach is easier to understand, than\na separate \"By the way, I do not define any rule to build these\ntargets using asciidoc.conf, but I know they depend on it\" rule.\n\nCare to do a real patch?\n\nThanks.\n\n\n> diff --git i/Documentation/Makefile w/Documentation/Makefile\n> index e53d333e..971977b8 100644\n> --- i/Documentation/Makefile\n> +++ w/Documentation/Makefile\n> @@ -178,8 +178,6 @@ all: html man\n>  \n>  html: $(DOC_HTML)\n>  \n> -$(DOC_HTML) $(DOC_MAN1) $(DOC_MAN5) $(DOC_MAN7): asciidoc.conf\n> -\n>  man: man1 man5 man7\n>  man1: $(DOC_MAN1)\n>  man5: $(DOC_MAN5)\n> @@ -257,7 +255,7 @@ clean:\n>  \t$(RM) $(cmds_txt) *.made\n>  \t$(RM) manpage-base-url.xsl\n>  \n> -$(MAN_HTML): %.html : %.txt\n> +$(MAN_HTML): %.html : %.txt asciidoc.conf\n>  \t$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \\\n>  \t$(ASCIIDOC) -b xhtml11 -d manpage -f asciidoc.conf \\\n>  \t\t$(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) -o $@+ $< && \\\n> @@ -270,7 +268,7 @@ manpage-base-url.xsl: manpage-base-url.xsl.in\n>  \t$(QUIET_XMLTO)$(RM) $@ && \\\n>  \t$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $<\n>  \n> -%.xml : %.txt\n> +%.xml : %.txt asciidoc.conf\n>  \t$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \\\n>  \t$(ASCIIDOC) -b docbook -d manpage -f asciidoc.conf \\\n>  \t\t$(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) -o $@+ $< && \\\n> @@ -286,7 +284,7 @@ technical/api-index.txt: technical/api-index-skel.txt \\\n>  \t$(QUIET_GEN)cd technical && '$(SHELL_PATH_SQ)' ./api-index.sh\n>  \n>  technical/%.html: ASCIIDOC_EXTRA += -a git-relative-html-prefix=../\n> -$(patsubst %,%.html,$(API_DOCS) technical/api-index $(TECH_DOCS)): %.html : %.txt\n> +$(patsubst %,%.html,$(API_DOCS) technical/api-index $(TECH_DOCS)): %.html : %.txt asciidoc.conf\n>  \t$(QUIET_ASCIIDOC)$(ASCIIDOC) -b xhtml11 -f asciidoc.conf \\\n>  \t\t$(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) $*.txt\n>  \n> diff --git i/t/test-terminal.perl w/t/test-terminal.perl\n> index 10172aee..1fb373f2 100755\n> --- i/t/test-terminal.perl\n> +++ w/t/test-terminal.perl\n> @@ -31,7 +31,7 @@ sub finish_child {\n>  \t} elsif ($? & 127) {\n>  \t\tmy $code = $? & 127;\n>  \t\twarn \"died of signal $code\";\n> -\t\treturn $code - 128;\n> +\t\treturn $code + 128;\n>  \t} else {\n>  \t\treturn $? >> 8;\n>  \t}\n"},{"id":"206128","messageId":"20130106120153.GB22081@elie.Belkin","threadId":"32533","inReplyTo":"7vbod2pzxd.fsf@alter.siamese.dyndns.org","subject":"[PATCH] docs: manpage XML depends on asciidoc.conf","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2013-01-06T12:01:53Z","receivedAt":"2013-01-06T12:01:53Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"When building manual pages, the source text is transformed to XML with\nAsciiDoc before the man pages are generated from the XML with xmlto.\n\nFix the dependencies in the Makefile so that the XML files are rebuilt\nwhen asciidoc.conf changes and not just the manual pages from\nunchanged XML, and move the dependencies from a recipeless rule to the\nrules with commands that use asciidoc.conf to make the dependencies\neasier to understand and maintain.\n\nReported-by: John Keeping <john@keeping.me.uk>\nSigned-off-by: Jonathan Nieder <jrnieder@gmail.com>\n---\nJunio C Hamano wrote:\n\n> Care to do a real patch?\n\nHere you go.\n\n Documentation/Makefile | 8 +++-----\n 1 file changed, 3 insertions(+), 5 deletions(-)\n\ndiff --git a/Documentation/Makefile b/Documentation/Makefile\nindex e53d333e..971977b8 100644\n--- a/Documentation/Makefile\n+++ b/Documentation/Makefile\n@@ -178,8 +178,6 @@ all: html man\n \n html: $(DOC_HTML)\n \n-$(DOC_HTML) $(DOC_MAN1) $(DOC_MAN5) $(DOC_MAN7): asciidoc.conf\n-\n man: man1 man5 man7\n man1: $(DOC_MAN1)\n man5: $(DOC_MAN5)\n@@ -257,7 +255,7 @@ clean:\n \t$(RM) $(cmds_txt) *.made\n \t$(RM) manpage-base-url.xsl\n \n-$(MAN_HTML): %.html : %.txt\n+$(MAN_HTML): %.html : %.txt asciidoc.conf\n \t$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \\\n \t$(ASCIIDOC) -b xhtml11 -d manpage -f asciidoc.conf \\\n \t\t$(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) -o $@+ $< && \\\n@@ -270,7 +268,7 @@ manpage-base-url.xsl: manpage-base-url.xsl.in\n \t$(QUIET_XMLTO)$(RM) $@ && \\\n \t$(XMLTO) -m $(MANPAGE_XSL) $(XMLTO_EXTRA) man $<\n \n-%.xml : %.txt\n+%.xml : %.txt asciidoc.conf\n \t$(QUIET_ASCIIDOC)$(RM) $@+ $@ && \\\n \t$(ASCIIDOC) -b docbook -d manpage -f asciidoc.conf \\\n \t\t$(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) -o $@+ $< && \\\n@@ -286,7 +284,7 @@ technical/api-index.txt: technical/api-index-skel.txt \\\n \t$(QUIET_GEN)cd technical && '$(SHELL_PATH_SQ)' ./api-index.sh\n \n technical/%.html: ASCIIDOC_EXTRA += -a git-relative-html-prefix=../\n-$(patsubst %,%.html,$(API_DOCS) technical/api-index $(TECH_DOCS)): %.html : %.txt\n+$(patsubst %,%.html,$(API_DOCS) technical/api-index $(TECH_DOCS)): %.html : %.txt asciidoc.conf\n \t$(QUIET_ASCIIDOC)$(ASCIIDOC) -b xhtml11 -f asciidoc.conf \\\n \t\t$(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) $*.txt\n \n-- \n1.8.1\n"},{"id":"206131","messageId":"20130106123326.GF6440@serenity.lan","threadId":"32533","inReplyTo":"20130106120153.GB22081@elie.Belkin","subject":"Re: [PATCH] docs: manpage XML depends on asciidoc.conf","fromName":"John Keeping","fromEmail":"john@keeping.me.uk","sentAt":"2013-01-06T12:33:26Z","receivedAt":"2013-01-06T12:33:26Z","isPatch":true,"sender":{"key":"john@keeping.me.uk","avatar":"https://avatars.githubusercontent.com/u/1702081?v=4"},"body":"On Sun, Jan 06, 2013 at 04:01:53AM -0800, Jonathan Nieder wrote:\n> When building manual pages, the source text is transformed to XML with\n> AsciiDoc before the man pages are generated from the XML with xmlto.\n> \n> Fix the dependencies in the Makefile so that the XML files are rebuilt\n> when asciidoc.conf changes and not just the manual pages from\n> unchanged XML, and move the dependencies from a recipeless rule to the\n> rules with commands that use asciidoc.conf to make the dependencies\n> easier to understand and maintain.\n> \n> Reported-by: John Keeping <john@keeping.me.uk>\n> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>\n> ---\n\nThis fixes the problem I wanted to fix (as well as being clearer for the\nfuture), so FWIW:\n\nTested-by: John Keeping <john@keeping.me.uk>\n"},{"id":"206190","messageId":"7vtxqtlx0w.fsf@alter.siamese.dyndns.org","threadId":"32533","inReplyTo":"20130106123326.GF6440@serenity.lan","subject":"Re: [PATCH] docs: manpage XML depends on asciidoc.conf","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2013-01-06T23:19:43Z","receivedAt":"2013-01-06T23:19:43Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Thanks.\n"}]}