Difference between revisions of "Template:Modinfo"

From AlsaProject
Jump to: navigation, search
(revert (as it did not work...))
m (Typo)
 
(8 intermediate revisions by 2 users not shown)
Line 2: Line 2:
 
{| style="font-family:monospace"
 
{| style="font-family:monospace"
 
| description: 
 
| description: 
| {{{description|''no desciption included''}}}
+
| {{{description|''no description included''}}}
 
|-
 
|-
 
| author: 
 
| author: 
Line 9: Line 9:
 
|license:
 
|license:
 
| {{{license|GPL}}}
 
| {{{license|GPL}}}
{{#if: {{{1|}}} | <tr><td>parm;&nbsp;</td><td>{{{1}}}</td></tr> }}
+
|
|-
+
{{#if: {{{1|}}} | {{ModinfoParm|{{{1}}}}} }} {{#if: {{{2|}}} | {{ModinfoParm|{{{2}}}}} }} {{#if: {{{3|}}} | {{ModinfoParm|{{{3}}}}} }} {{#if: {{{4|}}} | {{ModinfoParm|{{{4}}}}} }} {{#if: {{{5|}}} | {{ModinfoParm|{{{5}}}}} }} {{#if: {{{6|}}} | {{ModinfoParm|{{{6}}}}} }} {{#if: {{{7|}}} | {{ModinfoParm|{{{7}}}}} }} {{#if: {{{8|}}} | {{ModinfoParm|{{{8}}}}} }} {{#if: {{{9|}}} | {{ModinfoParm|{{{9}}}}} }} {{#if: {{{10|}}} | {{ModinfoParm|{{{10}}}}} }} {{#if: {{{11|}}} | {{ModinfoParm|{{{11}}}}} }} {{#if: {{{12|}}} | {{ModinfoParm|{{{12}}}}} }} {{#if: {{{13|}}} | {{ModinfoParm|{{{13}}}}} }} {{#if: {{{14|}}} | {{ModinfoParm|{{{14}}}}} }} {{#if: {{{15|}}} | {{ModinfoParm|{{{15}}}}} }} {{#if: {{{16|}}} | {{ModinfoParm|{{{16}}}}} }} {{#if: {{{17|}}} | {{ModinfoParm|{{{17}}}}} }} {{#if: {{{18|}}} | {{ModinfoParm|{{{18}}}}} }} {{#if: {{{19|}}} | {{ModinfoParm|{{{19}}}}} }} {{#if: {{{20|}}} | {{ModinfoParm|{{{20}}}}} }} {{#if: {{{21|}}} | {{ModinfoParm|{{{21}}}}} }} {{#if: {{{22|}}} | {{ModinfoParm|{{{22}}}}} }} {{#if: {{{23|}}} | {{ModinfoParm|{{{23}}}}} }} {{#if: {{{24|}}} | {{ModinfoParm|{{{24}}}}} }} {{#if: {{{25|}}} | {{ModinfoParm|{{{25}}}}} }} {{#if: {{{26|}}} | {{ModinfoParm|{{{26}}}}} }} {{#if: {{{27|}}} | {{ModinfoParm|{{{27}}}}} }} {{#if: {{{28|}}} | {{ModinfoParm|{{{28}}}}} }} {{#if: {{{29|}}} | {{ModinfoParm|{{{29}}}}} }} {{#if: {{{30|}}} | {{ModinfoParm|{{{30}}}}} }}
| parm:&nbsp;
+
| {{{2|}}}
+
|-
+
| parm:&nbsp;
+
| {{{3|}}}
+
|-
+
| parm:&nbsp;
+
| {{{4|}}}
+
|-
+
| parm:&nbsp;
+
| {{{5|}}}
+
|-
+
| parm:&nbsp;
+
| {{{6|}}}
+
|-
+
| parm:&nbsp;
+
| {{{7|}}}
+
|-
+
| parm:&nbsp;
+
| {{{8|}}}
+
|-
+
| parm:&nbsp;
+
| {{{9|}}}
+
|-
+
| parm:&nbsp;
+
| {{{10|}}}
+
|-
+
| parm:&nbsp;
+
| {{{11|}}}
+
|-
+
| parm:&nbsp;
+
| {{{12|}}}
+
|-
+
| parm:&nbsp;
+
| {{{13|}}}
+
|-
+
| parm:&nbsp;
+
| {{{14|}}}
+
|-
+
| parm:&nbsp;
+
| {{{15|}}}
+
 
|}<noinclude>
 
|}<noinclude>
  
 +
 +
----
  
 
This template is intended to display the output of
 
This template is intended to display the output of
Line 59: Line 20:
 
in a typewriter style table.
 
in a typewriter style table.
  
{{Template:Note|For the moment there are '''15''' parameters hard-coded in this template! <br /> This is situation will change as soon as someone figures out how to use functions like <tt><nowiki>#if</nowiki></tt> in this Wiki.|Importaint}}
+
{{Note|For the moment there are '''30''' parameters hard-coded in this template. <br /> You may change it to add support for more parameters.}}
  
 
==Usage==
 
==Usage==
  
* You need to specify the <tt>module</tt> name.
+
* You ''need to'' specify the module name: <br /> <tt>module=</tt>
* You need to specify values for <tt>description</tt> and <tt>author</tt>.
+
* You ''need to'' give a description and specify the author(s): <br /> <tt>description=</tt> <br /> <tt>author=</tt>
* If the license is not the ''GNU General Public License'' (GPL) then you may also specify <tt>license</tt>.
+
* You ''may'' specify the license if it is not the ''GNU General Public License'' (GPL): <br /> <tt>license=</tt>
 
* All other parameters are the values for parm, as you get it from the <tt>modinfo</tt> output.
 
* All other parameters are the values for parm, as you get it from the <tt>modinfo</tt> output.
  
 
''Example:''
 
''Example:''
  <nowiki>{{Template:Modinfo
+
  <nowiki>{{Modinfo
 
|module=generic
 
|module=generic
 
|description=ALSA module for a sound card
 
|description=ALSA module for a sound card
Line 79: Line 40:
  
 
''That will give you:''
 
''That will give you:''
{{Template:Modinfo|module=generic|description=ALSA module for a sound card|author=Mr. Smith|parm1:on or off|parm2:0 or 1|parm3:debug or not debug, that is the question}}
+
{{Modinfo
 +
|module=generic
 +
|description=ALSA module for a sound card
 +
|author=Mr. Smith
 +
|parm1:on or off
 +
|parm2:0 or 1
 +
|parm3:debug or not debug, that is the question
 +
}}
  
 
</noinclude>
 
</noinclude>

Latest revision as of 16:03, 5 October 2007

[edit] The module options for snd-{{{module}}}

description:  no description included
author:  author unknown
license: GPL



This template is intended to display the output of

modinfo snd-soundcard

in a typewriter style table.

Note: 

For the moment there are 30 parameters hard-coded in this template.
You may change it to add support for more parameters.


[edit] Usage

  • You need to specify the module name:
    module=
  • You need to give a description and specify the author(s):
    description=
    author=
  • You may specify the license if it is not the GNU General Public License (GPL):
    license=
  • All other parameters are the values for parm, as you get it from the modinfo output.

Example:

{{Modinfo
|module=generic
|description=ALSA module for a sound card
|author=Mr. Smith
|parm1:on or off
|parm2:0 or 1
|parm3:debug or not debug, that is the question
}}

That will give you:

[edit] The module options for snd-generic

description:  ALSA module for a sound card
author:  Mr. Smith
license: GPL
parm: parm1:on or off
parm: parm2:0 or 1
parm: parm3:debug or not debug, that is the question


Custom Search
Personal tools
Namespaces

Variants
Actions
Navigation
wiki
Toolbox