All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Jonas Fonseca" <jonas.fonseca@gmail.com>
To: "Martin Waitz" <tali@admingilde.org>
Cc: "Scott Lamb" <slamb@slamb.org>, "Junio C Hamano" <junkio@cox.net>,
	git@vger.kernel.org
Subject: Re: [PATCH] catch asciidoc failures
Date: Fri, 1 Jun 2007 10:55:03 +0200	[thread overview]
Message-ID: <2c6b72b30706010155k4a3745b0i3ac2d22fa5a4f534@mail.gmail.com> (raw)
In-Reply-To: <20070601083621.GB3521@admingilde.org>

On 6/1/07, Martin Waitz <tali@admingilde.org> wrote:
> On Thu, May 31, 2007 at 11:23:57PM -0700, Scott Lamb wrote:
> > If pipefail is available (GNU bash >= 3.00), fail when asciidoc returns
> > error rather than possibly later during XSLT.
>
> perhaps we should simply change the pipe ordering to get asciidoc
> to the end of the pipeline so that all shells respect its exit code?

For tig I also adopted the nice man page headers git has. However, I have
used  asciidoc attributes provided on the command line avoid having to
use sed. I can make a patch later if nobody beats me. The required changes
are outlined below.

> > --- a/Documentation/Makefile
> > +++ b/Documentation/Makefile
> > @@ -111,6 +111,7 @@ clean:
> >
> >  %.html : %.txt
> >       rm -f $@+ $@
> > +     set -o pipefail 2>/dev/null; \
> >       $(ASCIIDOC) -b xhtml11 -d manpage -f asciidoc.conf \
> >               $(ASCIIDOC_EXTRA) -o - $< | \
> >               sed -e 's/@@GIT_VERSION@@/$(GIT_VERSION)/g' >$@+
>
> something like (untested):
>         sed -e 's/@@GIT_VERSION@@/$(GIT_VERSION)/g' $< |
>                 $(ASCIIDOC) -b xhtml11 -d manpage -f asciidoc.conf \
>                         $(ASCIIDOC_EXTRA) -o $@+ -

More untested stuff. Use -a to define git_version attribute:

$(ASCIIDOC) -b xhtml11 -d manpage -f asciidoc.conf \
                         $(ASCIIDOC_EXTRA) -agit_version=$(GIT_VERSION) -o $@ $<

Then change the @@GIT_VERSION@@ symbol in asciidoc.conf to {git_version}.

-- 
Jonas Fonseca

  reply	other threads:[~2007-06-01  8:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-01  6:23 [PATCH] catch asciidoc failures Scott Lamb
2007-06-01  8:36 ` Martin Waitz
2007-06-01  8:55   ` Jonas Fonseca [this message]
2007-06-01  9:10   ` Jeff King
2007-06-01  9:39     ` Martin Waitz
2007-06-01  9:43       ` Jeff King
2007-06-01  9:46     ` Scott Lamb

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2c6b72b30706010155k4a3745b0i3ac2d22fa5a4f534@mail.gmail.com \
    --to=jonas.fonseca@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=junkio@cox.net \
    --cc=slamb@slamb.org \
    --cc=tali@admingilde.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.