Template:Repo link/doc git source: Difference between revisions

From FlightGear wiki
Jump to navigation Jump to search
(Changed the confusing 'repository' parameter name to 'label'.)
m (Some small edits.)
Line 2: Line 2:
__NOTOC__
__NOTOC__
== Goal ==
== Goal ==
This template is for creating links or URLs for the [[{{{label|MISSING}}}]] git version control repository.  It is a subtemplate of the master {{tl|repo link}} template designed to be specific for {{{label|MISSING}}}.
This template is for creating links or URLs for the [[{{{label|MISSING}}}]] git version control repository.  It is a subtemplate of the master {{tl|repo link}} template designed to be specific for the {{{label|MISSING}}} repository.


== Usage ==
== Usage ==
Line 27: Line 27:
; cmd: An optional command line tool name + options to prepend to the URL.  For example '''git clone'''.
; cmd: An optional command line tool name + options to prepend to the URL.  For example '''git clone'''.


; protocol: The URL protocol, for example '''https''', '''http''', '''git''', '''ssh''', '''svn'''.  This defaults to '''https'''.
; protocol: The URL protocol, for example '''https''', '''http''', '''git''', or '''ssh'''.  This defaults to '''https'''.


; type: Choose between the web interface or direct repository link.  This can be either '''git''' or '''git web'''.  The default is '''git web'''.
; type: Choose between the web interface or direct repository link.  This can be either '''git''' or '''git web'''.  The default is '''git web'''.
Line 47: Line 47:
; post: Text to append.
; post: Text to append.


; simplepath:  If set, this strips off the repository name from the URL label, leaving just the contents of the ''path'' parameter.
; simplepath:  If set, this strips off the repository name from the URL label, leaving just the contents of the '''path''' parameter.
: {{inote|The ''text'' parameter will override this.}}
: {{inote|The ''text'' parameter will override this.}}



Revision as of 13:59, 26 February 2016

The following template description is not displayed when the template is inserted in an article.

Goal

This template is for creating links or URLs for the MISSING git version control repository. It is a subtemplate of the master {{repo link}} template designed to be specific for the MISSING repository.

Usage

{{MISSING file
| cmd        =
| protocol   =
| type       =
| user       =
| branch     =
| path       =
| commit     =
| line       =

| view       = 
| text       = 
| pre        = 
| post       = 
| simplepath = 
| full       = 
}}

All parameters are optional.

cmd
An optional command line tool name + options to prepend to the URL. For example git clone.
protocol
The URL protocol, for example https, http, git, or ssh. This defaults to https.
type
Choose between the web interface or direct repository link. This can be either git or git web. The default is git web.
branch
The git branch or tag name. For git tags, simply append /~ to the tag name. This defaults to next.
path
The file path.
commit
The commit identifier (git hash). This defaults to next.
line
Line number of the file to display.
view
View to display, either tree or log. The default is tree.
text
Text to display as the link label. Overrides pre.
pre
Prefix to a link label.
post
Text to append.
simplepath
If set, this strips off the repository name from the URL label, leaving just the contents of the path parameter.
Note The text parameter will override this.
full
If set, the full URL will be shown.

Examples

MISSING

Related templates