Difference between revisions of "WritingRules"

From ArmadeusWiki
Jump to: navigation, search
(language)
(adding syntax highlighting)
Line 14: Line 14:
 
  {{LanguageBar|Page_English_Name|Page_French_Name|Page_German_Name}}
 
  {{LanguageBar|Page_English_Name|Page_French_Name|Page_German_Name}}
 
</pre>
 
</pre>
 +
 +
==Source code syntax highlighting==
 +
* When you write source code directly in the Wiki, you can use the automatic syntax highlighting feature by using the ''"source"'' tag; for example:
 +
<pre>
 +
<source lang="c">
 +
#include <stdio.h>
 +
#include <stdlib.h>
 +
 +
int main(int argc, char *argv[])
 +
{
 +
    printf( "APF9328 says: Hello World ! ;-)\n" );
 +
    exit(0);
 +
}
 +
</source>
 +
</pre>
 +
will give you:
 +
<source lang="c">
 +
#include <stdio.h>
 +
#include <stdlib.h>
 +
 +
int main(int argc, char *argv[])
 +
{
 +
    printf( "APF9328 says: Hello World ! ;-)\n" );
 +
    exit(0);
 +
}
 +
</source>

Revision as of 20:14, 4 June 2008

On this page are explained the rules to follow when writing articles for this wiki

Shell commands

  • If you're speaking about a command launched as a normal user on your development Host then use:
[  ] $ command
  • If you're speaking about a command launched as root on your development Host then use:
[  ] # command
  • If you're speaking about a command launched on the target then use:
# command

Traduction

  • Use the "LanguageBar" Template to add multiple languages selection to your page:
 {{LanguageBar|Page_English_Name|Page_French_Name|Page_German_Name}}

Source code syntax highlighting

  • When you write source code directly in the Wiki, you can use the automatic syntax highlighting feature by using the "source" tag; for example:
<source lang="c">
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
    printf( "APF9328 says: Hello World ! ;-)\n" );
    exit(0);
}
</source>

will give you:

#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
    printf( "APF9328 says: Hello World ! ;-)\n" );
    exit(0);
}