2017-05-27 2 views
0

Ich möchte ein Q & A mit Asciidoctor erstellen. Die meisten Antworten beinhalten Befehlszeilenbefehle, die ich in [source] -Abschnitten haben möchte. Es scheint jedoch, dass der [source] -Block das Ende des [qanda] -Blocks markiert.Quellblöcke in Qanda Antworten

Die zweite Frage wird als erstes Element einer beschrifteten Liste angezeigt.

Gibt es eine Möglichkeit, das in Asciidoctor auszudrücken?

Antwort

1

Sie sollten ein "+" in der Zeile vor [source,sh] hinzufügen. Die vollständige Datei sollte dann wie folgt aussehen:

[qanda] 
How do you show all the changes introduced in branchA since its common ancestor commit with branchB?:: 
Having branchA and branchB as valid pointers, run 
+ 
[source,sh] 
---- 
$ git log branchB..branchA 
---- 
You probably mean branchA and branchB to be recently related. 

How do you see the contents of a stash?:: 
`git stash show -p "stash{0}"`