added bullets to top comment information to make it more readable

This commit is contained in:
inxi-svn 2011-06-21 03:41:33 +00:00
parent 1ee1a843b0
commit 50dd14ce0d

79
inxi
View file

@ -78,38 +78,37 @@
#### -S For desktop environment, user must be in X and have xprop installed (in X11-utils) #### -S For desktop environment, user must be in X and have xprop installed (in X11-utils)
######################################################################## ########################################################################
#### CONVENTIONS: #### CONVENTIONS:
#### Indentation: TABS #### * Character Encoding: UTF-8 - this file contains special characters that must be opened and saved as UTF8
#### Do not use `....` (back quotes), those are totally non-reabable, use $(....). #### * Indentation: TABS
#### Do not use one liner flow controls. #### * Do not use `....` (back quotes), those are totally non-reabable, use $(....).
#### The ONLY time you should use ';' (semi-colon) is in this single case: if [[ condition ]];then. #### * Do not use one liner flow controls.
#### Never use compound 'if': ie, if [[ condition ]] && statement. #### The ONLY time you should use ';' (semi-colon) is in this single case: if [[ condition ]];then.
#### Note: [[ -n $something ]] - double brackets does not require quotes for variables: ie, "$something". #### Never use compound 'if': ie, if [[ condition ]] && statement.
#### Always use quotes, double or single, for all string values. #### * Note: [[ -n $something ]] - double brackets does not require quotes for variables: ie, "$something".
#### #### * Always use quotes, double or single, for all string values.
#### All new code/methods must be in a function. #### * All new code/methods must be in a function.
#### For all boolean tests, use 'true' / 'false'. #### * For all boolean tests, use 'true' / 'false'.
#### !! Do NOT use 0 or 1 unless it's a function return. #### !! Do NOT use 0 or 1 unless it's a function return.
#### Avoid complicated tests in the if condition itself. #### * Avoid complicated tests in the if condition itself.
#### To 'return' a value in a function, use 'echo <var>'. #### * To 'return' a value in a function, use 'echo <var>'.
#### #### * For gawk: use always if ( num_of_cores > 1 ) { hanging { starter for all blocks
#### For gawk: use always if ( num_of_cores > 1 ) { hanging { starter for all blocks #### This lets us use one method for all gawk structures, including BEGIN/END, if, for, etc
#### This lets us use one method for all gawk structures, including BEGIN/END, if, for, etc
#### ####
#### VARIABLE/FUNCTION NAMING: #### VARIABLE/FUNCTION NAMING:
#### All functions should follow standard naming--verb adjective noun. #### * All functions should follow standard naming--verb adjective noun.
#### ie, get_cpu_data #### ie, get_cpu_data
#### All variables MUST be initialized / declared explicitly. #### * All variables MUST be initialized / declared explicitly, either top of file, for Globals, or using local
#### All variables should clearly explain what they are, except counters like i, j. #### * All variables should clearly explain what they are, except counters like i, j.
#### Each word of variable must be separated by '_' (underscore) (camel form). #### * Each word of Bash variable must be separated by '_' (underscore) (camel form), like: cpu_data
#### Global variables are 'UPPER CASE', at top of script. #### * Each word of Gawk variable must be like this (first word lower, following start with upper): cpuData
#### ie, SOME_VARIABLE='' #### * Global variables are 'UPPER CASE', at top of script.
#### Local variables are 'lower case' and declared at the top of the function. #### ie, SOME_VARIABLE=''
#### ie, some_variable='' #### * Local variables are 'lower case' and declared at the top of the function using local, always.
#### Locals that will be inherited by child functions have first char capitalized (so you know they are inherited). #### ie: local some_variable=''
#### ie, Some_Variable #### * Locals that will be inherited by child functions have first char capitalized (so you know they are inherited).
#### #### ie, Some_Variable
#### Booleans should start with b_ (local) or B_ (global) and state clearly what is being tested. #### * Booleans should start with b_ (local) or B_ (global) and state clearly what is being tested.
#### Arrays should start with a_ (local) or A_ (global). #### * Arrays should start with a_ (local) or A_ (global).
#### ####
#### SPECIAL NOTES: #### SPECIAL NOTES:
#### * The color variable ${C2} must always be followed by a space unless you know what #### * The color variable ${C2} must always be followed by a space unless you know what
@ -129,20 +128,16 @@
################################################################################### ###################################################################################
#### KDE Konversation information. Moving from dcop(qt3/KDE3) to dbus(qt4/KDE4) #### KDE Konversation information. Moving from dcop(qt3/KDE3) to dbus(qt4/KDE4)
################################################################################### ###################################################################################
#### dcop and dbus -- these talk back to Konversation from this script #### * dcop and dbus -- these talk back to Konversation from this script
#### #### * Scripting info -- http://konversation.berlios.de/docs/scripting.html
#### Scripting info -- http://konversation.berlios.de/docs/scripting.html #### -- http://www.kde.org.uk/apps/konversation/
#### -- http://www.kde.org.uk/apps/konversation/ #### * dbus info -- http://dbus.freedesktop.org/doc/dbus-tutorial.html
#### #### view dbus info -- https://fedorahosted.org/d-feet/
#### dbus info -- http://dbus.freedesktop.org/doc/dbus-tutorial.html #### -- or run qdbus
#### view dbus info -- https://fedorahosted.org/d-feet/ #### * Konvi dbus/usage-- qdbus org.kde.konversation /irc say <server> <target-channel> <output>
#### -- or run qdbus #### * Python usage -- http://wiki.python.org/moin/DbusExamples (just in case)
#### Konvi dbus/usage-- qdbus org.kde.konversation /irc say <server> <target-channel> <output>
####
#### Python usage -- http://wiki.python.org/moin/DbusExamples (just in case)
#### ####
#### Because webpages come and go, the above information needs to be moved to inxi's wiki #### Because webpages come and go, the above information needs to be moved to inxi's wiki
####
######################################################################## ########################################################################
#### Valuable Resources #### Valuable Resources
#### gawk arrays: http://www.math.utah.edu/docs/info/gawk_12.html #### gawk arrays: http://www.math.utah.edu/docs/info/gawk_12.html