Difference between revisions of "Help:Style"

From ArchWiki
Jump to: navigation, search
(this is based on Help:Reading, so ti does not require an initial discussion)
(if you want to discuss these rules, please do, I'm just trying to add some initial content to the article)
Line 18: Line 18:
 
*use <tt>#</tt> for root commands:
 
*use <tt>#</tt> for root commands:
 
  # pacman -S kernel26
 
  # pacman -S kernel26
 +
 +
Prefer using this method instead of writing <tt>$ sudo command</tt> unless it is really necessary.
 +
 +
<tt># sudo command</tt> is always wrong.
  
 
{{Note|Since <tt>#</tt> is also used to denote comments in text files, you should always make sure to avoid ambiguities, usually by explicitly writing to run the command or edit a text file.}}
 
{{Note|Since <tt>#</tt> is also used to denote comments in text files, you should always make sure to avoid ambiguities, usually by explicitly writing to run the command or edit a text file.}}

Revision as of 17:05, 5 May 2011

Tango-document-new.pngThis article is a stub.Tango-document-new.png

Notes: please use the first argument of the template to provide more detailed indications. (Discuss in Help talk:Style#)

This page aims to provide a guide for the standardization of style in the articles of this wiki.

Note:
  • This guide is a draft, it has not been officialized yet, and its rules cannot be considered in a definitive status.
  • You are warmly invited to discuss your additions or modifications in the talk page, before submitting them; you can also start discussions in the forum, but you should add a link to the thread in the talk page anyway.

Commands: regular user or root

When writing CLI commands, always make distinction whether each should be issued as a regular user, or as root:

  • use $ for regular user commands:
$ makepkg -s
  • use # for root commands:
# pacman -S kernel26

Prefer using this method instead of writing $ sudo command unless it is really necessary.

# sudo command is always wrong.

Note: Since # is also used to denote comments in text files, you should always make sure to avoid ambiguities, usually by explicitly writing to run the command or edit a text file.