Login  Register

Re: Include sections of files

Posted by mojavelinux on Apr 18, 2013; 1:03am
URL: https://discuss.asciidoctor.org/Include-sections-of-files-tp106p147.html

On Wed, Apr 17, 2013 at 3:10 PM, glaforge [via Asciidoctor :: Discussion] <[hidden email]> wrote:
By the way, a quick question: the comments / tag lines are not included in the document?

Say if we have:

1: import foo
2: // tag classdef
3: class Bar {}
4: // tag classdef

The included snippet is just line 3?

That is correct.
 

Just so the artificial comment that we use doesn't appear in the final produced documentation :-)

Exactly. It's a throwaway line.

Btw, I updated the syntax to be more AsciiDoc-like and less likely to match something it shouldn't:

// tag::classdef[]
class Bar {}
// end::classdef[]

Cheers,

-Dan


--
Dan Allen
Principal Software Engineer, Red Hat | Author of Seam in Action
Registered Linux User #231597

http://google.com/profiles/dan.j.allen
http://mojavelinux.com
http://mojavelinux.com/seaminaction