Template:Readme file: Difference between revisions
Jump to navigation
Jump to search
(+ 'nopath' example) |
(Removing unnecessary README. prefix; clarification) |
||
Line 1: | Line 1: | ||
{{#if: {{{nopath|}}} | | <span style="font-size: 80%;">[[$FG_ROOT]]/Docs/</span>}}[http://sourceforge.net/p/flightgear/fgdata/ci/{{{2|next}}}/tree/Docs/{{{1|README}}} {{{1|README}} | {{#if: {{{nopath|}}} <!-- Should the path be removed? --> | ||
| <!-- Yes, remove the path --> | |||
| <!-- No, keep the path --><!-- | |||
--><span style="font-size: 80%;">[[$FG_ROOT]]/Docs/</span>}}[http://sourceforge.net/p/flightgear/fgdata/ci/{{{2|next}}}/tree/Docs/<!-- | |||
-->{{#if: {{{1|}}} <!-- Should the default file be linked to? --> | |||
| <!-- No, go to file path --><!-- | |||
-->README.{{{1}}} README.{{{1}}}] | |||
| <!-- Yes, go to the deafult --><!-- | |||
-->README README]<!-- | |||
-->}}<noinclude> | |||
{{Informative template|1= | {{Informative template|1= | ||
__NOTOC__ | __NOTOC__ | ||
== Goal == | == Goal == | ||
This template can be used to link to the readme files in [[$FG_ROOT]]/Docs. | This template can be used to link to the readme files in [[$FG_ROOT]]/Docs in the SourceForge repository. | ||
== Usage == | == Usage == | ||
{{obr}}'''readme file'''{{!}}''file | {{obr}}'''readme file'''{{!}}''file''{{!}}''commit'' {{!}}''nopath''={{cbr}} | ||
Both parameters are optional. | Both parameters are optional. | ||
; file | ; file: Readme file name, not including <code>README.</code>. If empty the link will go to <code>$FG_DATA/Docs/README</code> | ||
; commit: | ; commit: Optional SHA-1 commit reference to use instead of the latest commit. | ||
; nopath: | ; nopath: If not empty the path will not be shown. | ||
== Examples == | == Examples == | ||
<nowiki>* {{readme file| | <nowiki>* {{readme file|logging}}</nowiki> | ||
* {{readme file| | * {{readme file|logging}} | ||
<nowiki>* {{readme file| | <nowiki>* {{readme file|commands|0591afe42cf7d78280f7999657034a6cf15a5649}}</nowiki> | ||
* {{readme file| | * {{readme file|commands|0591afe42cf7d78280f7999657034a6cf15a5649}} | ||
<nowiki>* {{readme file| | <nowiki>* {{readme file|materials|nopath=1}}</nowiki> | ||
* {{readme file| | * {{readme file|materials|nopath=1}} | ||
}} | }} |
Revision as of 18:01, 19 May 2015
The following template description is not displayed when the template is inserted in an article.
Goal
This template can be used to link to the readme files in $FG_ROOT/Docs in the SourceForge repository.
Usage
{{readme file|file|commit |nopath=}}
Both parameters are optional.
- file
- Readme file name, not including
README.
. If empty the link will go to$FG_DATA/Docs/README
- commit
- Optional SHA-1 commit reference to use instead of the latest commit.
- nopath
- If not empty the path will not be shown.
Examples
* {{readme file|logging}}
- $FG_ROOT/Docs/README.logging
* {{readme file|commands|0591afe42cf7d78280f7999657034a6cf15a5649}}
- $FG_ROOT/Docs/README.commands
* {{readme file|materials|nopath=1}}