User:Johan G/project infrastructure: Difference between revisions

Jump to navigation Jump to search
Extending
(+ Examples)
(Extending)
Line 6: Line 6:
   | url = http://build.flightgear.org:8080/{{{urn|}}}
   | url = http://build.flightgear.org:8080/{{{urn|}}}
   | link = [http://build.flightgear.org:8080/{{{urn|}}} {{{label|FlightGear build server}}}]
   | link = [http://build.flightgear.org:8080/{{{urn|}}} {{{label|FlightGear build server}}}]
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''buildserver'''|project infrastructure}}
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''buildserver'''|User:Johan G/project infrastructure}}
   }}
   }}
  | forum = {{#switch: {{{2|link}}}
  | forum = {{#switch: {{{2|link}}}
Line 12: Line 12:
   | url = http://forum.flightgear.org/{{{urn|}}}
   | url = http://forum.flightgear.org/{{{urn|}}}
   | link = [http://forum.flightgear.org/{{{urn|}}} {{{label|FlightGear forum}}}]
   | link = [http://forum.flightgear.org/{{{urn|}}} {{{label|FlightGear forum}}}]
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''forum'''|project infrastructure}}
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''forum'''|User:Johan G/project infrastructure}}
   }}
   }}
  | main = {{#switch: {{{2|link}}}
  | main = {{#switch: {{{2|link}}}
   | name = SourceForge
   | name = SourceForge
   | short = sf
   | code = sf
   | url = http://sourceforge.net/projects/flightgear/{{{urn|}}}
   | url = http://sourceforge.net/projects/flightgear/{{{urn|}}}
   | link = [http://sourceforge.net/projects/flightgear/{{{urn|}}} {{{label|Main FlightGear repository}}}]
   | link = [http://sourceforge.net/projects/flightgear/{{{urn|}}} {{{label|Main FlightGear repository}}}]
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''main'''|project infrastructure}}
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''main'''|User:Johan G/project infrastructure}}
   }}
   }}
  | mapserver = {{#switch: {{{2|link}}}
  | mapserver = {{#switch: {{{2|link}}}
Line 25: Line 25:
   | url = http://mapserver.flightgear.org/{{{urn|}}}
   | url = http://mapserver.flightgear.org/{{{urn|}}}
   | link = [http://mapserver.flightgear.org/{{{urn|}}} {{{label|FlightGear mapserver}}}]
   | link = [http://mapserver.flightgear.org/{{{urn|}}} {{{label|FlightGear mapserver}}}]
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''mapserver'''|project infrastructure}}
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''mapserver'''|User:Johan G/project infrastructure}}
   }}
   }}
  | website = {{#switch: {{{2|link}}}
  | website = {{#switch: {{{2|link}}}
Line 31: Line 31:
   | url = http://flightgear.org/{{{urn|}}}
   | url = http://flightgear.org/{{{urn|}}}
   | link = [http://flightgear.org/{{{urn|}}} {{{label|website}}}]
   | link = [http://flightgear.org/{{{urn|}}} {{{label|website}}}]
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''website'''|project infrastructure}}
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''website'''|User:Johan G/project infrastructure}}
   }}
   }}
  | wiki = {{#switch: {{{2|link}}}
  | wiki = {{#switch: {{{2|link}}}
Line 37: Line 37:
   | url = http://wiki.flightgear.org/{{{urn|}}}
   | url = http://wiki.flightgear.org/{{{urn|}}}
   | link = [http://wiki.flightgear.org/{{{urn|}}} {{{label|FlightGear wiki}}}]
   | link = [http://wiki.flightgear.org/{{{urn|}}} {{{label|FlightGear wiki}}}]
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''wiki'''|project infrastructure}}
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure '''wiki'''|User:Johan G/project infrastructure}}
   }}
   }}
<!-- |  = {{#switch: {{{2|link}}}
<!-- |  = {{#switch: {{{2|link}}}
Line 43: Line 43:
   | url =  
   | url =  
   | link = [ {{{label|}}}]
   | link = [ {{{label|}}}]
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure ''''''|project infrastructure}}
   | #default = {{error|Attribute '''{{{2}}}''' invalid for infrastructure ''''''|User:Johan G/project infrastructure}}
   }} -->
   }} -->
  | #default = {{error|Invalid '''infrastructure''' parameter|project infrastructure}}
  | #default = {{error|Invalid '''infrastructure''' parameter|User:Johan G/project infrastructure}}
}}<noinclude>
}}<noinclude>
{{Informative template|1=
{{Informative template|1=
__NOTOC__
__NOTOC__
== Goal ==
== Goal ==
This template can be used to...
This meta template is used by other templates as lookup table. It will return attributes associated with project infrastructure websites.
 
Adding this template to a page will automatically add [[:Category:...]] to that page.
 
{{icaution|Caution that might help prevent lost work, very complicated debugging etc...}}
 
{{inote|Note that might be helpful or lead the reader in the right direction.}}


== Usage ==
== Usage ==
Line 64: Line 58:


; infrastructure:  Name of the infrastucture, for example '''forum''', '''wiki''' or '''main'''.  Defaults to '''main-repo'''.
; infrastructure:  Name of the infrastucture, for example '''forum''', '''wiki''' or '''main'''.  Defaults to '''main-repo'''.
; attribute:  One of several attributes associated with the infrastructure, for example '''name''', '''url''' or '''link'''. Defaults to '''link'''.
; attribute:  Attribute associated with the infrastructure to return. Defaults to '''link'''.
:; code:  Returns an internal code for the host used by other templates (in essence an abbreviation)
:; link:  Returns an external link
:; name:  Returns the name of the infrastructure
:; url:  Returns an url to the infrastructure
; urn:  Optional string with path, queries, parameters and fragments to use with the '''url''' and '''link''' attributes.
; urn:  Optional string with path, queries, parameters and fragments to use with the '''url''' and '''link''' attributes.
; label:  Optional label to use with the '''link''' attribute.
; label:  Optional label to use with the '''link''' attribute.


Available parameters:
Available parameters and attributes:
{{{!}} class="wikitable"
{{{!}} class="wikitable"
! rowspan="2" valign="top" {{!}} Infrastructure
! rowspan="2" valign="top" {{!}} Infrastructure
! colspan="3" {{!}} Attribute
! colspan="4" {{!}} Attributes
{{!}} rowspan="2" valign="bottom" {{!}} urn
{{!}} rowspan="2" valign="bottom" {{!}} urn
{{!}} rowspan="2" valign="bottom" {{!}} label
{{!}} rowspan="2" valign="bottom" {{!}} label
{{!-}}
{{!-}}
{{!}} name {{!!}} url {{!!}} link
{{!}} code {{!!}} link {{!!}} name {{!!}} url
{{!-}}
{{!-}}
{{!}} buildserver {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}}
{{!}} buildserver
{{!}} {{n/a}} {{!!}} {{User:Johan G/project infrastructure|buildserver|link}} {{!!}} {{User:Johan G/project infrastructure|buildserver|name}} {{!!}} {{User:Johan G/project infrastructure|buildserver|url}}
{{!}} {{yes}} {{!!}} {{yes}}
{{!-}}
{{!-}}
{{!}} forum {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}}
{{!}} forum
{{!}} {{n/a}} {{!!}} {{User:Johan G/project infrastructure|forum|link}} {{!!}} {{User:Johan G/project infrastructure|forum|name}} {{!!}} {{User:Johan G/project infrastructure|forum|url}}
{{!}} {{yes}} {{!!}} {{yes}}
{{!-}}
{{!-}}
{{!}} main {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}}
{{!}} main
{{!}} {{User:Johan G/project infrastructure|main|code}} {{!!}} {{User:Johan G/project infrastructure|main|link}} {{!!}} {{User:Johan G/project infrastructure|main|name}} {{!!}} {{User:Johan G/project infrastructure|main|url}}
{{!}} {{yes}} {{!!}} {{yes}}
{{!-}}
{{!-}}
{{!}} mapserver {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}}
{{!}} mapserver
{{!}} {{n/a}} {{!!}} {{User:Johan G/project infrastructure|mapserver|link}} {{!!}} {{User:Johan G/project infrastructure|mapserver|name}} {{!!}} {{User:Johan G/project infrastructure|mapserver|url}}
{{!}} {{yes}} {{!!}} {{yes}}
{{!-}}
{{!-}}
{{!}} website {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}}
{{!}} website
{{!}} {{n/a}} {{!!}} {{User:Johan G/project infrastructure|website|link}} {{!!}} {{User:Johan G/project infrastructure|website|name}} {{!!}} {{User:Johan G/project infrastructure|website|url}}
{{!}} {{yes}} {{!!}} {{yes}}
{{!-}}
{{!-}}
{{!}} wiki {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}} {{!!}} {{yes}}
{{!}} wiki
{{!}} {{n/a}} {{!!}} {{User:Johan G/project infrastructure|wiki|link}} {{!!}} {{User:Johan G/project infrastructure|wiki|name}} {{!!}} {{User:Johan G/project infrastructure|wiki|url}}
{{!}} {{yes}} {{!!}} {{yes}}
<!-- {{!-}}
{{!}}
{{!}} {{User:Johan G/project infrastructure||code}} {{!!}} {{User:Johan G/project infrastructure||link}} {{!!}} {{User:Johan G/project infrastructure||name}} {{!!}} {{User:Johan G/project infrastructure||url}}
{{!}} {{yes}} {{!!}} {{yes}} -->
{{!}}}
{{!}}}


== Examples ==
== Examples ==
{{obr}}project infrastructure{{cbr}}
{{User:Johan G/project infrastructure}}
  {{obr}}project infrastructure{{!}}forum{{cbr}}
  {{obr}}project infrastructure{{!}}forum{{cbr}}
{{User:Johan G/project infrastructure|forum}}
{{User:Johan G/project infrastructure|forum}}
{{obr}}project infrastructure{{!}}forum{{!}}code{{cbr}}
{{User:Johan G/project infrastructure|forum|code}}


  {{obr}}project infrastructure{{!}}forum{{!}}link{{cbr}}
  {{obr}}project infrastructure{{!}}forum{{!}}link{{cbr}}
Line 107: Line 127:


== Known issues ==
== Known issues ==
Known issues and workarounds if such are known.


== Related templates ==
== Related templates ==
* {{tl|example}}
* {{tl|project infrastructure}}


}}
}}

Navigation menu