This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
Re: Including only a part of an external source code
On Fri, Jan 24, 2003 at 01:57:01PM +0100, Joachim Ziegler wrote:
> cbbrowne@acm.org wrote:
> >When I was working on a book last year, writing using DocBook, I wound
> >up splitting the files into fragments, and having a Makefile manage
>
> Thank you. That's a good idea.
>
> In my case, it would suffice to only specify the line numbers from
> (between) which source code should be extracted. Is this possible?
You could just use a combination of "head" and "tail" commands to
generate your fragments. Something like:
file-18-24: file
tail +18 $< | head -6 > $@
(untested, there may be one-off bugs in this code)
--
Yann Dirson <Yann.Dirson@fr.alcove.com> http://www.alcove.com/
Technical support manager Responsable de l'assistance technique
Senior Free-Software Consultant Consultant senior en Logiciels Libres
Debian developer (dirson@debian.org) Développeur Debian