Feature #11351

Extract code snippets from a project's VCS directly into the wiki

Added by Maher Gamal over 9 years ago.

Status:NewStart date:
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:Wiki
Target version:-
Resolution:

Description

I believe this can be an extension to the current source syntax of the wiki.

For example :

source:src/test/java/pkg1/MyClass.java#L20_L30

OR

<pre><code class="java" source="src/test/java/pkg1/MyClass.java#L20_L30">
    Lines 20 to 30 from MyClass.java appear here.
</code>


Would result in line 20 to 30 embedded as a < code > section in the wiki. This comes in handy when referring to code sections throughout a design document. Of course, referring to specific commits is much more reliable to always retrieve the same set of lines.

What do you think of this ? Do you have an another idea to achieve the same thing ?

Also available in: Atom PDF