Last active
December 21, 2015 23:59
-
-
Save paulrayner/6386391 to your computer and use it in GitHub Desktop.
Asciidoc multi-part book chapter numbering problem
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| The problem is that I want 'Background and Context' to be chapter 1, but the numbering is messed up. The content | |
| for chapter 1 is coming in from 01_BackgroundAndContext.asc[]. I've tried several things to fix the numbering, | |
| but cannot figure out the correct combination/settings to do it. Maybe I just need to turn off numbering | |
| completely, and name each of the chapters explictly? This is what I had originally, but then I saw that I | |
| was able to get chapter numbers automatically with Asciidoctor & asciidoctor-fopdf. | |
| Here is the relevant part of the AsciiDoc book document: | |
| = BDD with Cucumber | |
| Richard Lawrence and Paul Rayner [email protected], [email protected] | |
| v1.0, 2013-05-06 | |
| :toc: | |
| :homepage: http://bddwithcucumber.com | |
| :numbered!: | |
| == Dedication | |
| The optional dedication goes here. | |
| :numbered!: | |
| == Acknowledgements | |
| Keep track of who to thank here, for example: | |
| * The team at Dominion Voting Systems in Denver for early feedback. | |
| * Dan Sharp | |
| * Phil Bohnenkamp | |
| * Kim Barnes | |
| * Dave Madouros | |
| * Dr. Z | |
| * Chris G | |
| :numbered!: | |
| == Preface Sub-section | |
| NOTE: Preface and appendix subsections start out of sequence at level | |
| 2 (level 1 is skipped). This only applies to multi-part book | |
| documents. | |
| :numbered!: | |
| == Example Preface | |
| The optional book preface goes here at section level zero. | |
| === Preface Sub-section | |
| NOTE: Preface and appendix subsections start out of sequence at level | |
| 2 (level 1 is skipped). This only applies to multi-part book | |
| documents. | |
| = Part I - The Basics | |
| [partintro] | |
| -- | |
| Here's where we cover the basics of getting started with doing BDD with Cucumber. We introduce the role | |
| of Cucumber in terms of which interactions it supports as part of an agile development process. We also | |
| walk through a simple example of how to use Cucumber to specify the behavior of an application. | |
| -- | |
| include::01_BackgroundAndContext.asc[] | |
| include::02_BasicBDDwithCucumber.asc[] | |
| ---- | |
| I'm running Asciidoctor (from the latest git pull off master) with the command: | |
| asciidoctor -b docbook -d book -a toc BDDwithCucumber.asc | |
| And here is the pdf table of contents output from asciidoctor-fopdf: | |
| Table of Contents | |
| 1. Dedication ............................................................................................................. 1 | |
| 2. Acknowledgements ............................................................................................... 2 | |
| 3. Preface Sub-section .............................................................................................. 3 | |
| 4. Example Preface ................................................................................................... 4 | |
| 4.1. Preface Sub-section .................................................................................... 4 | |
| I. Part I - The Basics ................................................................................................ 5 | |
| 5. Background and Context ............................................................................... 6 | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment