merged
authorOleksandr Gavenko <gavenkoa@gmail.com>
Sun, 20 Nov 2011 20:14:48 +0200
changeset 1092 639665016a27
parent 1037 49735af70121 (current diff)
parent 1090 d362fd4a1995 (diff)
child 1093 aa9974c8abeb
merged
bash.rst
cpp.rst
devel-ideal-proj.rst
devel-productivity.rst
html.rst
index-frame.html
proj-hosting.rst
refcard.rst
--- a/Makefile	Fri Oct 14 23:48:24 2011 +0300
+++ b/Makefile	Sun Nov 20 20:14:48 2011 +0200
@@ -34,7 +34,9 @@
 TXT_FILES := $(wildcard *.txt)
 
 HTML_DIR := tips-html
-HTML_FILES := $(patsubst %.rst,$(HTML_DIR)/%.html,$(RST_FILES)) $(HTML_DIR)/index.html $(HTML_DIR)/index-frame.html
+RST_HTML_FILES := $(patsubst %.rst,$(HTML_DIR)/%.html,$(RST_FILES))
+HTML_FILES := $(patsubst %.rst,$(HTML_DIR)/%.html,$(RST_FILES)) \
+        $(HTML_DIR)/index.html $(HTML_DIR)/frame.html $(HTML_DIR)/frame-index.html
 TXT__FILES := $(addprefix $(HTML_DIR)/,$(TXT_FILES))
 
 CHM_FILES := $(addprefix $(HTML_DIR)/,chm.hhp chm.hhc chm.stp)
@@ -53,9 +55,12 @@
 $(HTML_DIR)/%.html: %.rst rst.css | $(HTML_DIR)
 	$(RST2HTML) --stylesheet=rst.css $*.rst $@
 
-$(HTML_DIR)/index.html: index.sh $(filter-out $(HTML_DIR)/index.html,$(HTML_FILES)) | $(HTML_DIR)
+$(HTML_DIR)/frame-index.html: index.sh $(RST_HTML_FILES) | $(HTML_DIR)
 	./index.sh frame >$@
 
+$(HTML_DIR)/index.html: index.sh $(RST_HTML_FILES) | $(HTML_DIR)
+	./index.sh html >$@
+
 $(HTML_DIR)/%.html: %.html | $(HTML_DIR)
 	cp $< $@
 
@@ -76,7 +81,7 @@
 	./chm-hhc.sh >$@
 
 $(HTML_DIR)/index-chm.html: index.sh | $(HTML_DIR)
-	./index.sh chm >$@
+	./index.sh html >$@
 
 ################################################################
 # Init targets.
--- a/bash.rst	Fri Oct 14 23:48:24 2011 +0300
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,39 +0,0 @@
--*- mode: outline; coding: utf-8; -*-
-
-* How override PS1, PS2?
-
-When loading bash read ~/.bash_profile and ~/.bashrc.
-
-Put at end of these files
-
-  PS1='\u@\H$ '
-
-When xterm start bash - it start as non-login. So ~/.bash_profile and ~/.bashrc
-didn't read. To workaround this use
-
-  $ xterm -e bash -i -c "mc -x"
-
-That make bash interactive and init file was readed.
-
-* Command history.
-
-Bash allow accessing to command that you type previously. There are several
-options to control command history behavior. Set corresponding variables in
-your ~/.bashrc file (which is read by interactive shell):
-
-  #   ignorespace do not save lines that start with space
-  #   erasedups all previous lines matching the current line to be removed from
-  #             the history list before that line is saved
-  export HISTCONTROL=igrorespace:erasedups
-  export HISTIGNORE=" ?cd *":"e *":"sudo mv *":"sudo rm *":"sudo cp *":"sudo mkdir *":"sudo chmod *":"sudo chown *":ls:pwd:"vlc*"
-
-There are another options, with default values (which satisfy my needs, so
-I don't put they to ~/.bashrc):
-
-  export HISTFILE=~/.bash_history  # where is command history stored
-  export HISTFILESIZE=500          # how many lines been in $HISTFILE
-  export HISTSIZE=500              # how many lines been stored in bash process
-
-** mc (GNU Midnight Commander).
-
-You can also set special history rules for mc subshell in ~/.mc/bashrc file.
--- a/cmd.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/cmd.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -96,6 +96,12 @@
 
   $ for /f "tokens=1 delims=" %%s in (users.txt) do (echo %%S & command "%%S") >> outputfile.txt
 
+Resize cmd window.
+==================
+::
+
+  cmd# mode CON: COLS=120 LINES=40
+
 Limits.
 =======
 
--- a/cpp.rst	Fri Oct 14 23:48:24 2011 +0300
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,44 +0,0 @@
--*- mode: outline; coding: utf-8; -*-
-
-* How to see macros expansion?
-
-** GCC.
-
-  $ cpp <file>.c
-
-** MSVC.
-
-  $ cl /E <file>.c
-
-* Who to see predefined macros?
-
-See
-
-  http://predef.sourceforge.net/
-  http://en.wikipedia.org/wiki/C_preprocessor#Compiler-specific_predefined_macros
-
-** GNU C Compiler.
-
-  $ gcc -dM -E - < /dev/null
-
-** HP-UX ansi C compiler.
-
-  $ cc -v EMPTY.c
-
-** SCO OpenServer C compiler.
-
-  $ cc -## EMPTY.c
-
-** Sun Studio C/C++ compiler.
-
-  $ cc -## EMPTY.c
-
-** IBM AIX XL C/C++ compiler.
-
-  $ cc -qshowmacros -E EMPTY.c
-
-** Visual Studio compiler.
-
-  http://msdn.microsoft.com/en-us/library/b0084kay.aspx
-                Predefined Macros
-
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/css.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -0,0 +1,85 @@
+.. -*- coding: utf-8; -*-
+
+======
+ CSS.
+======
+.. contents::
+
+Adding CSS to HTML.
+===================
+
+Include in head tag::
+
+  <html>
+    <head>
+      <link href="path-to.css" rel="stylesheet" type="text/css">
+    </head>
+    ...
+  <html>
+
+or::
+
+  <head>
+   <style type="text/css">
+     h1 {border-width: 1; border: solid; text-align: center}
+   </style>
+  </head>
+
+To change style in specific tag use::
+
+  <b style="color: blue; font-family: ariel">Welcome!</b>
+
+Selectors.
+==========
+
+  tag {}
+  .class {}
+  #id {} для id разрешены символы
+  * {} - любой элемент
+
+  tag tag1 {} - выбор tag1, у которых есть предок tag
+  tag > tag {} - выбор дочернего элемента
+  tag + tag {} - выбор соседних элементов
+  tag ~ tag {} - выбор любого соседа
+
+  [attr] {}
+  [attr="..."] {}
+  [attr~="..."] {} - присутствует слово ... в поле атрибута
+  [attr*="..."] {} - присутствует набор символов ... в поле атрибута
+  [attr^="..."] {} - начинается с ... в поле атрибута
+  [attr$="..."] {} - заканчивается на ... в поле атрибута
+  tag [attr|="..."] {}
+
+  :link - не посещенные ссылки
+  :visited - посещенные ссылки
+  :active - нажатие на левую клавишу мыши на элементе
+  :hover - назначать при наведении
+  :focus - при фокусировке элемента
+  :first-child - первый подэлемент
+  :last-child - последний подэлемент
+
+  :first-line
+  :first-letter - выбрать первую букву (не приминимо к inline элементам)
+  :before{content:"..."}, ставит перед контентом элементов строку xxx (можно
+  использовать счетчики)
+  :after{} - тоже, что и before, только ставит текст после контента тега
+
+Emacs.
+======
+::
+
+  $ sudo apt-get install css-mode
+
+Graphical editor.
+=================
+::
+
+  $ sudo apt-get install cssed
+
+CSS browser support.
+====================
+
+  * http://www.quirksmode.org/css/contents.html
+  * http://en.wikipedia.org/wiki/Comparison_of_layout_engines_%28CSS%29
+  * http://www.css3.info/modules/selector-compat/
+
--- a/devel-ideal-proj.rst	Fri Oct 14 23:48:24 2011 +0300
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,82 +0,0 @@
--*- mode: outline; coding: utf-8; -*-
-
-* Ideal software development model.
-
-This file mainly discuss about open source software project.
-
-* Open source.
-
-Open source software project have freedom how develop project and which
-development toolchains use.
-
-* Close source.
-
-Close source projects have proprietary nature because of:
-
- * interest to make money (another parties can not easily reproduce project or
-   steal realisation ideas/code, allowing another party get same product and get
-   company money)
- * low code quality (to stop stain company good name or to stop malicious
-   attacks based on code analysis)
- * security consideration (to hide protocols and data format to make harder
-   malicious attack)
- * business model (closed data formats allow vendor lock)
-
-Disadvantage of closed source project (in many case):
-
- * you can not directly contact with developers (only through support)
- * low support quality
- * paid support (and you have no enough money)
- * can not access to product bug tracing system (you only can submit bug via
-   crash report application or technical support, publicly appear internal bug
-   tracing can damage product reputation
-
-* Component of software project.
-
- * Src (sources).
- * Doc (documentation).
- * VCS (version control system).
- * BTS (bug tracking).
- * News (project news/history/changelog).
-
-* Docs.
-
-TODO
-
-* Project home page.
-
-Project home page must provide:
-
- * project name
- * short info about project goal
- * project license
- * current project status
- * links to binary release
- * links to source release, how to get latest source from VCS
- * links to online/printed docs
- * how report bug (BUGS)
- * where send patch
- * contact info
-
-Additionally:
-
- * help welcome, requirement to join to project
- * mail/news list for users/developers, how to subscribe/unsubscribe, where
-   find archive, how search for keyword in archive
- * project history (NEWS, ChangeLog)
- * project policy (HACKING)
- * how build project (README, INSTALL)
- * list of contributor with contact info (MAINTAINERS, AUTHORS)
- * who use project
-
-* VCS.
-
-TAGS: VCS, version control system, SCM, source code management, DVCS,
-      distributed version control system.
-
- * CVS
- * SVN
- * Mercurial (hg)
- * git
- * bazaar
-
--- a/devel-productivity.rst	Fri Oct 14 23:48:24 2011 +0300
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,10 +0,0 @@
--*- mode: outline; coding: utf-8; -*-
-
-* Productivity statistic.
-
-KLOC (kilo lines of code), MM (man month).
-
-41 KLOC / 119 MM  == 11 LOC/day  | 5 people | hard task, high/middle skills, new to domain
-6 KLOC / 24 MM    == 8.3 LOC/day | 6 people | hard task, high skills
-26 KLOC / 46 MM   == 19 LOC/day  | 7 people | easy task, middle skills
-155 KLOC / 20 MM  == 260 LOC/day | 7 people | middle task, high skills, high level programming
--- a/devel-proj-branching.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/devel-proj-branching.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -16,12 +16,12 @@
  * For development on initial project stage.
  * Does not for experimental features!
 
-Names: dev, devel, master, trunk
+Names: dev, devel, master, trunk, default
 
 Feature branch.
 ---------------
 
- * For experimental features.
+ * For experimental features, that can be striped.
  * For large changes that can break main development.
  * For incompatable changes that can break main development.
 
@@ -37,7 +37,19 @@
    from release manager after reviewing code quality by QA team.
  * From release branch you make tags to product releases for customer.
 
-Names: vXX.YY.ZZ, maint
+Names: vXX.YY.ZZ, maint, stable
+
+Custom branches.
+----------------
+
+Custom branches intended to store modification to main release to make custom
+product build.
+
+Don't use custom branches at all. Instead redesign project to use customizable
+build. Expected problem:
+
+ * You must manually propagate bug fixed to all custom branches.
+ * It is not possible merge custom branches back to development branch.
 
 Workflows.
 ==========
@@ -58,3 +70,81 @@
 
 TODO
 
+Single line workflow.
+---------------------
+
+ * Only single development branch exist.
+ * Release means finish developing set of features and bug fixes on branches and
+   moving product build to release server..
+ * After testing and stabilising release was made. This means:
+
+   * VERSION file was updated.
+   * CHANGE file was filled with feature set, version, data and VCS revision
+     number.
+   * Mark release by tag in VCS.
+   * Invoke build of sources which marked by tag. Copy result to release server.
+
+ * If bug discovered in some version, it fixed at development branch and
+   released with new minor/fix product version.
+ * Previous major/minor releases do not supported (just use latest release).
+   Users always forced to update to latest release.
+ * Each new release placed in hierarchy::
+
+     /vendor/product/XX.YY.ZZ/*
+
+   and symlinked to::
+
+     /vendor/product/latest/
+
+Example of release timeline::
+
+  +--+------+------+------+------+------+------+------+------+---->
+  dev|      |      |      |      |      |      |      |      |
+     v      v      v      v      v      v      v      v      v
+    t0.1.0 t1.0.0 t1.0.1 t1.1.0 t1.1.1 t1.1.2 t1.2.0 t2.0.0 t2.1.0
+
+Single development branch with branches for bug fix in major versions.
+----------------------------------------------------------------------
+
+ * Each major release have **own** branch.
+ * Another single branch reserved for development.
+ * Latest major relase branch is active. All older major branches is passive.
+ * Passive major branches was used for **only** for minor bug fixes on latest
+   code from this major version series (no new features).
+ * Features developed in development branch. Before release in merged to active
+   major release branch.
+ * Bug was fixed in oldest major version branch for which it must be provided
+   and merged to all next major version branches and development branch.
+ * Release means finish developing set of features and bug fixes on branches and
+   moving product build to release server..
+ * After testing and stabilising release was made. This means:
+
+   * VERSION file was updated.
+   * CHANGE file was filled with feature set, version, data and VCS revision
+     number.
+   * Mark release by tag in VCS.
+   * Invoke build of sources which marked by tag. Copy result to release server.
+
+ * If bug discovered in some version, it fixed at development branch and
+   released with new minor/fix product version.
+ * Previous major/minor releases do not supported (just use latest release).
+   Users always forced to update to latest release.
+
+Example of release timeline::
+
+  +--+-----+----------------------+-----+----+------+------+----->
+  dev|     |            ^     ^   |     |    |      |      |
+     |     |            |     |   |     |    v      v      v
+     |     |            |     |   |     |    +--+------+------+-->
+     |     |            |     |   |     |    b2 |      |      |
+     |     |            |     |   |     |       v      v      v
+     |     |            |     |   |     |      t2.0.0 t2.0.1 t2.1.0
+     v     v            |     |   v     v
+    t0.1.0 +---+------+-+---+-+-----+------+------+------+------+--->
+           b1  |      |     |       |      |      |      |      |
+               v      v     v       v      v      v      v      v
+              t1.0.0 t1.0.1 t1.0.2 t1.1.0 t1.2.0 t1.2.1 t1.2.2 t1.2.3
+
+In this example we release tags **1.0.1** and **1.0.2** with bug fixes in branch
+**1** as development branch was not ready for production.
+
--- a/devel-proj-files.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/devel-proj-files.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -10,7 +10,9 @@
 
  * README
  * INSTALL
- * 
+ * COPYING/LICENSE
+ * AUTHORS
+ * CHANGES
 
 General info files.
 ===================
@@ -358,9 +360,12 @@
 Todo files.
 ===========
 
- * list of wanted, roadmap
+ * List of high level wanted, general project roadmap.
+ * Discussion about product limitations and how to modify product to resolve
+   them.
 
-::
+Similar::
+
   BACKLOG
   CHECKLIST
   TODO
--- a/devel-scm.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/devel-scm.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -66,13 +66,21 @@
 ---------
 
 How danger is bug or issue. For example it may be crash, corruption (of user
-data), misspelling.
+data), or misspelling.
+
+Possible values::
+
+  blocker critical major minor trivial
 
 Priority.
 ---------
 
 How important is to fix bug. What bugs are first to fix.
 
+Possible values::
+
+  highest high normal low lowest
+
 Resolution.
 -----------
 
--- a/devel-versioning.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/devel-versioning.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -71,6 +71,9 @@
 
 Prefixing version with a "v" seems to be less common.
 
+Versioning for libraries/modules/components.
+============================================
+
 Major version component.
 ------------------------
 
@@ -112,18 +115,61 @@
  * rc (release candidate) are believed to meet all of the criteria for release
    and can be installed on test instances of production systems.
 
+Versioning for products.
+========================
+
+Versioning for products differ from versioning for libraries.
+
+Product is a set of conponents fixed to some versions. Components can be
+switches as written for library versioning:
+
+ * Any fix release interchanged.
+ * Any minor release interchanged starting from some minor.
+ * Major release does not interchanged at all.
+
+Product update vs upgrade.
+--------------------------
+
+Product update involve:
+
+ * Replacing product executable files, resources files.
+ * Config files and user data stay unchanged.
+
+Product update involve:
+
+ * Replacing product executable files, resources files.
+ * Config files and used data require modification and performed by upgrade
+   scripts or manually by user.
+
 Release build version data.
 ===========================
 
  * Build number.
  * Build date.
- * Build version.
+ * VCS revision.
  * Branch-tag used.
  * Overnight build (Y/N).
  * QA tested (Y/N).
  * QA test results (Pass/Fail).
  * Location of full logs.
 
+Stop your VCS hook to update version!
+=====================================
+
+Don't update version without human decision.
+
+Why do not do this on success build:
+
+ * You can have several build machine which may concurrently update version.
+ * There not exist tools for easy querying for status of build (as ok/fail,
+   build configuration, date, coverage, lint checks, etc).
+ * Some part of development team may not have permission for bumping version and
+   after build they must revert some automatically updated files.
+
+Why do not do this from pre-/post-commit hooks:
+
+ * Some changes can only partially introduce feature/bugfix.
+
 Version ordering formula.
 =========================
 
@@ -144,14 +190,15 @@
 
 Semver version ordering formula.
 --------------------------------
+::
 
-if (A.major != B.major) return A.major > B.major;
-if (A.minor != B.minor) return A.minor > B.minor;
-if (A.patch != B.patch) return A.patch > B.patch;
-if (A.special == B.special) return 0;
-if (A.special == "") return 1;
-if (B.special == "") return -1;
-return A.special > B.special;
+  if (A.major != B.major) return A.major > B.major;
+  if (A.minor != B.minor) return A.minor > B.minor;
+  if (A.patch != B.patch) return A.patch > B.patch;
+  if (A.special == B.special) return 0;
+  if (A.special == "") return 1;
+  if (B.special == "") return -1;
+  return A.special > B.special;
 
 **NOTE** Accoding to this definition 1.0.1rc1 < 1.0.1rc10 < 1.0.1rc2 which is
 non meaningful.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/firefox.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -0,0 +1,489 @@
+.. -*- coding: utf-8; fill-column: 90 -*-
+
+==========
+ Firefox.
+==========
+
+How edit settings?
+==================
+
+Default settings stored in 'prefs.js'. If you don't want rewrite it
+edit/create 'user.js'::
+
+  $ emacs ~/.mozilla/firefox/xxxxxxx.default/user.js
+
+or open link::
+
+  about:config
+
+See
+
+  http://www.mozilla.org/unix/customizing.html#prefs
+
+Profiles.
+=========
+
+How create new profile.
+-----------------------
+
+Close all opened firefox windows (File -> Exit)! And run::
+
+  $ firefox -P
+
+and in GUI push "Create profile" button and type profile name.
+
+How run two firefox simultaneously.
+-----------------------------------
+::
+
+  $ firefox             # run firefox with default profile
+  $ firefox -P second-profile-name -no-remote
+  $ firefox -P third-profile-name -no-remote
+
+How backup and restore profile.
+-------------------------------
+
+Just save content of '~/.mozilla/firefox/Profiles/xxxxxxx.default'.
+To restore profile edit '~/.mozilla/firefox/profiles.ini'::
+
+  [Profile<N>]
+  Name=default
+  IsRelative=1
+  Path=Profiles/xxxxxxx.default
+  Default=1
+
+How to prevent links from opening a new window?
+===============================================
+
+Go to about:config and set::
+
+  browser.link.open_newwindow - 3. May be 1:cur 2:win 3:tab
+  browser.link.open_external - 3. May be 1:cur 2:win 3:tab
+  browser.link.open_newwindow.restriction - 0. May be 0, 1. 2
+
+See also:
+
+  http://kb.mozillazine.org/Browser.link.open_external
+  http://kb.mozillazine.org/Browser.link.open_newwindow.restriction
+
+How to prevent links from resize window?
+========================================
+::
+
+  Preference -> Content -> JavaScript ->
+                Advanced -> disable "Move and resize existing windows"
+
+How limit simultaneously connection counts?
+===========================================
+::
+
+  network.http.max-connections - 4
+
+or search by word 'connections' in 'about:config'.
+
+See:
+
+  http://kb.mozillazine.org/Network.http.max-connections
+
+Copy link without escaping non ASCII chars.
+===========================================
+
+Run about:config and set network.standard-url.escape-utf8 to false.
+
+Firefox downloading.
+====================
+
+  ftp://ftp.mozilla.org/pub/mozilla.org/firefox/releases/
+                Download older version.
+
+Privacy.
+========
+
+See
+
+  http://www.mozilla.com/en-US/privacy-policy.html
+  http://www.mozilla.com/en-US/legal/privacy/firefox-en.html
+
+Do not send anything through Breakpad.
+--------------------------------------
+
+Breakpad is crash report library. If firefox crash Breakpad can send core file
+to Mozilla.
+
+The breakpad report server linked to in about:crashes (you can see which and
+where report you send).
+
+breakpad.reportURL is URL where send report. Set it to http://localhost to
+not send report.
+
+  http://kb.mozillazine.org/Breakpad.reportURL
+
+Do not use "Report Broken Web Site Feature" and "Report Web Forgery Feature".
+-----------------------------------------------------------------------------
+
+This feature available through "Help" menu.
+
+Be careful with "Automated Update Service".
+-------------------------------------------
+
+It can be disabled through "Tools -> Advanced -> Update".
+
+Disable "Location-aware Feature".
+---------------------------------
+
+Beginning with Firefox 3.5, Firefox offers a Location-Aware Feature, parts of
+which may be provided by third party service providers.
+
+To disable Location-aware Feature set "geo.enabled" to "false".
+
+Per site permission can accesssed through "Navigate to the site" -> "Tools"
+menu -> "Page Info" -> "Permissions tab" -> "Share Location".
+
+See
+
+  http://www.mozilla.com/en-US/firefox/geolocation/
+
+Disable Google safe browsing.
+-----------------------------
+
+It can be disabled through "Tools -> Options -> Security tab", untick the
+checkboxes for attacks and forgeries.
+
+Set
+
+  browser.safebrowsing.enabled  "false"
+                do not use safebrowsing
+  browser.safebrowsing.malware.enabled "false"
+                do not download malware blacklists and do not check downloads
+  browser.safebrowsing.remoteLookups "false"
+                use local blacklist to determine a site's phishiness instead
+                submitting the URL to a third party (deprecated?)
+
+See
+
+  http://kb.mozillazine.org/Browser.safebrowsing.enabled
+  http://kb.mozillazine.org/Browser.safebrowsing.remoteLookups
+
+View_source.
+============
+
+  view_source.wrap_long_lines
+                True - HTML code will wrap in the view source window, false
+                (default).
+  view_source.syntax_highlight
+                True (default) - enable syntax highlighting in the view source
+                window. "View → Syntax Highlighting".
+
+Privacy.
+========
+
+  privacy.item.cache
+                True (default) - clear the cache when using the Clear Private Data feature
+                (Firefox 1.5 and above only). This can be changed via "Tools → Options →
+                Privacy → Settings..." (Firefox 1.5) or "Tools → Options → Privacy /
+                Private Data → Settings..." (Firefox 2.0 and above).
+  privacy.item.cookies
+                True - delete all cookies when using the Clear Private Data feature
+                (Firefox 1.5 and above only).
+                This can be changed via "Tools → Options → Privacy → Settings..." (Firefox
+                1.5) or "Tools → Options → Privacy / Private Data → Settings..." (Firefox
+                2.0 and above).
+  privacy.item.downloads
+                True (default) - clear history of downloaded files when using the Clear
+                Private Data feature (Firefox 1.5 and above only).
+                Note: This can be changed via "Tools → Options → Privacy → Settings..."
+                (Firefox 1.5) or "Tools → Options → Privacy / Private Data → Settings..."
+                (Firefox 2.0 and above).
+  privacy.item.formdata
+                True (default) - clear all saved form data when using the Clear Private
+                Data feature (Firefox 1.5 and above only).
+                This can be changed via "Tools → Options → Privacy → Settings..." (Firefox
+                1.5) or "Tools → Options → Privacy / Private Data → Settings..." (Firefox
+                2.0 and above).
+  privacy.item.history
+                True (default) - clear the browsing history when using the Clear Private
+                Data feature (Firefox 1.5 and above only).
+                This can be changed via "Tools → Options → Privacy → Settings..." (Firefox
+                1.5) or "Tools → Options → Privacy / Private Data → Settings..." (Firefox
+                2.0 and above).
+  privacy.item.offlineApps
+                True - clear the offline website data when using the Clear Private Data
+                feature (Firefox 3 and above only).
+                This can be changed via "Tools → Options → Privacy / Private Data → Settings...".
+  privacy.item.passwords
+                True - delete all saved passwords when using the Clear Private Data
+                feature (Firefox 1.5 and above only).
+                This can be changed via "Tools → Options → Privacy → Settings..." (Firefox
+                1.5) or "Tools → Options → Privacy / Private Data → Settings..." (Firefox
+                2.0 and above).
+  privacy.item.sessions
+                True (default) - clear all authenticated SSL sessions when using the Clear
+                Private Data feature (Firefox 1.5 and above only).
+                This can be changed via "Tools → Options → Privacy → Settings..." (Firefox
+                1.5) or "Tools → Options → Privacy / Private Data → Settings..." (Firefox
+                2.0 and above).
+  privacy.popups.firstTime
+                True (default) - the user has never hidden the popup blocker notification
+                bar before, so show a dialog explaining the status bar icon.
+                False - the user has been informed of the status bar icon.
+  privacy.popups.policy
+                Determines the popup blocker behavior. 1 - allow popups, 2 - reject popups.
+                Seems to be deprecated in favor of dom.disable_open_during_load.
+  privacy.popups.showBrowserMessage
+                True (default) - display a message at the top of the browser window when a
+                popup has been blocked.
+                False - display a status bar icon to indicate when a popup has been blocked.
+  privacy.sanitize.promptOnSanitize
+                True (default) - prompt before performing the Clear Private Data operation
+                (Firefox 1.5 and above only)
+                In Firefox 1.5 and above, this can be changed via "Tools → Options → Privacy → Settings...".
+  privacy.sanitize.sanitizeOnShutdown
+                True: Perform the Clear Private Data operation when closing the browser
+                (Firefox 1.5 and above only).
+                Note: In Firefox 1.5 and above, this can be changed via "Tools → Options →
+                Privacy → Settings..."
+
+Security.
+=========
+
+  security.warn_entering_secure
+                True (default) - display a dialog warning the user when
+                entering a secure site from an insecure one.
+  security.warn_entering_secure.show_once
+                True (default) - Leave the "Alert me whenever..." box
+                unchecked on the security warning dialog.
+  security.warn_entering_weak
+                True (default) - display a dialog warning the user when
+                entering an insecure site from a secure one.
+  security.warn_entering_weak.show_once
+                True (default) - leave the "Alert me whenever..." box
+                unchecked on the security warning dialog.
+  security.warn_leaving_secure
+                True (default) - display a dialog warning the user when leaving a secure site.
+  security.warn_leaving_secure.show_once
+                True (default) - leave the "Alert me whenever..." box
+                unchecked on the security warning dialog.
+  security.warn_submit_insecure
+                True (default) - display a dialog warning the user when
+                submitting a form to an insecure site.
+  security.warn_submit_insecure.show_once
+                True (default) - leave the "Alert me whenever..." box
+                unchecked on the security warning dialog.
+  security.warn_viewing_mixed
+                True (default) - display a dialog warning the user when a page
+                has both encrypted and non-encrypted content.
+  security.warn_viewing_mixed.show_once
+                True (default) - leave the "Alert me whenever..." box unchecked
+                on the security warning dialog.
+  security.xpconnect.plugin.unrestricted
+                True (default) - allow scripting of plugins by untrusted scripts.
+
+Signon.
+=======
+
+  signon.prefillForms
+                True (default) - allows auto-filling of stored usernames and
+                passwords on webpage forms.
+  signon.rememberSignons
+                True (default) - enable the Password Manager.
+
+JavaScript.
+===========
+
+  javascript.enabled (Boolean).
+                Set this to true should you desire support for JavaScript. The
+                same as the Enable JavaScript option in the Content tab.
+  dom.allow_scripts_to_close_windows (Boolean).
+                Setting this to true specifies that any window may be closed
+                and isn’t recommended. Entering false specifies that only
+                windows opened by script can be closed via close().
+  dom.disable_image_src_set (Boolean).
+                This option determines whether JavaScript is allowed to change
+                images. Set this to true to enable this feature and false to
+                disable it (recommended).
+  dom.disable_open_click_delay (Integer).
+                This option specifies the amount of time, in milliseconds,
+                that must be surpassed before a pop-up window created by
+                JavaScript setInterval() or setTimeout() calls aren’t managed
+                by current pop-up blocker settings. Beneath this threshold
+                existing pop-up blocker settings are applied. Default is 1000 (1 second).
+  dom.disable_open_during_load (Boolean).
+                Set this to true to enable Firefox’s built-in pop-up blocker, which disables the loading of much pop-up content on sites – which will mostly be advertisements (it’s worth noting this is not perfect and will also disable many legitimate pop-ups). Should a pop-up be blocked in this way an information bar will appear at the top of the window, from which you can select what action to take. Setting this to false disables the pop-up blocker (Not recommended). Note – This is the same as the Block pop-up windows option in the Options menu, Content tab.
+
+  dom.disable_window_flip (Boolean).
+                This option controls whether JavaScript may be used to bring windows into the foreground/background via focus(). Setting this to true disables such actions, which won’t affect new pop-ups from loading in the foreground, though can force existing ones to remain in the background unless switched to manually. Set this to false to allow the script to determine what happens. Note – This is the same as the Raise or lower windows option in Advanced JavaScript Settings.
+
+  dom.disable_window_move_resize (Boolean).
+                This option controls whether JavaScript can be used to move &/or resize windows, whereby setting this to false enables scripts to do this. It would perhaps be best to set this to true, allowing only yourself to resize/move windows. Note – This is the same as the Move or resize existing windows option in Advanced JavaScript Settings.
+
+  dom.disable_window_open_feature.close (Boolean).
+                Set this to false to enable the use of scripting to hide the close button of windows, true forces the close button to always be displayed (recommended).
+
+  dom.disable_window_open_feature.directories (Boolean).
+                Set this to false to enable the use of scripting to hide the bookmarks toolbar, true prevents the bookmarks toolbar from being hidden in this way.
+
+  dom.disable_window_open_feature.location (Boolean).
+                Set this to false to enable the use of scripting to hide the Location (Address) bar, true prevents the Address bar from being hidden.
+
+  dom.disable_window_open_feature.menubar (Boolean).
+                Set this to false to enable the use of scripting to hide the Menu bar, true disables the hiding of the Menu bar.
+
+  dom.disable_window_open_feature.minimizable (Boolean).
+                Set this to false to enable the use of scripting to disable the minimizing of windows, true enables the minimizing of such windows (recommended).
+
+  dom.disable_window_open_feature.resizable (Boolean).
+                Set this to true to enable the use of scripting to hide the close button of windows, false forces the close button to always be displayed (recommended).
+
+  dom.disable_window_open_feature.scrollbar (Boolean).
+                Set this to false to enable the use of scripting to hide the Scroll bar in windows, true disables the hiding of the Scroll bar in windows.
+
+  dom.disable_window_open_feature.status (Boolean).
+                This option controls whether JavaScript can be used to hide the status bar, whereby setting this to false enables scripts to do this. Set this to true to force the status bar to be displayed at all times. Note – This is the same as the Hide the status bar option in Advanced JavaScript Settings.
+
+  dom.disable_window_open_feature.titlebar (Boolean).
+                Set this to false to enable the use of scripting to hide the Title bar of windows, true forces the Title bar to always be displayed.
+
+  dom.disable_window_open_feature.toolbar (Boolean).
+                Set this to false to enable the use of scripting to hide the Navigation toolbar, i.e. Back, Forward, etc. buttons, false prevents the hiding of the Navigation toolbar.
+
+  dom.disable_window_status_change (Boolean).
+                This option controls whether JavaScript can be used to display custom text in the status bar, e.g. moving the mouse over a hyperlink normally would display where the link points to, though a script could be used to display something else instead. Set this to false to allow such custom status bar text displayed, while true will disable this. Note – This is the same as the Change status bar text option in Advanced JavaScript Settings.
+
+  dom.event.contextmenu.enabled (Boolean).
+                This option controls whether JavaScript can be used to alter, or even disable the context menu, e.g. right clicking could be disabled on certain pages. Set this to true if you wish to allow sites to be able to do this, while false ensures scripts can’t be used to alter this functionality. Note – This is the same as the Disable or replace context menus option in Advanced JavaScript Settings.
+
+  dom.max_script_run_time (Integer).
+                This specifies the amount of time, in seconds, that a script
+                in content may run before being prompted whether to continue
+                running it or not (default 10). Setting to 0 allows scripts to
+                run as long as required.
+  dom.max_chrome_script_run_time (Integer).
+                This specifies the amount the amount of time, in seconds, that
+                a script with chrome privileges may run before being prompted
+                whether to continue running it or not (default 20).
+  dom.popup_maximum (Integer).
+                This value specifies the maximum number of pop-up windows that
+                may be open simultaneously (default 20).
+
+See
+
+  http://kb.mozillazine.org/Dom.max_script_run_time
+  http://kb.mozillazine.org/Dom.max_chrome_script_run_time
+
+Plugin.
+=======
+
+  plugin.default_plugin_disabled
+                True (default) - when a plugin is needed, prompt the user.
+                False - don't prompt the user to install needed plugins.
+  plugin.expose_full_path
+                True - in about:plugins and navigator.plugins, reveal the full path to
+                plugin files.
+                False (default) - show only the plugin filename
+
+Download Manager.
+=================
+
+  browser.download.manager.flashCount
+                Set to 0 to stop flashing Download Manager.
+  browser.download.manager.showAlertOnComplete
+                Set to false to top flashing alter on complete download.
+  browser.download.manager.retention
+                Clear immediately the download history:
+                0 - upon successful download
+                1 - when the Firefox browser closes
+                2 - needs user to clear it manually (default)
+  browser.download.manager.closeWhenDone
+                Set to false to stop Firefox closing Download Manager when download is
+                complete.
+  browser.download.manager.scanWhenDone
+                Set to false to stop scaning for viruses.
+
+Search.
+=======
+
+OpenSearch.
+-----------
+
+  http://en.wikipedia.org/wiki/OpenSearch
+
+Smart Keywords.
+---------------
+
+Right-click in the search box, and you should see the context menu item Add a Keyword for
+this Search.
+
+Useful user plugin.
+===================
+
+Adblock Plus.
+-------------
+
+Block from loading ads and banners.
+
+  http://adblockplus.org/en/
+                home page
+  https://addons.mozilla.org/en-US/firefox/addon/4364
+                official mozilla download place
+
+NoScript.
+---------
+
+Add-on allows JavaScript, Java and Flash and other plugins to be executed only by trusted
+web sites of your choice (e.g. your online bank), and provides the most powerful Anti-XSS
+protection available in a browser.
+
+  http://noscript.net/
+                home page
+
+Cookie Monster.
+---------------
+
+Cookie Monster provides proactive cookie management on a site or domain level basis.
+
+  https://addons.mozilla.org/en-US/firefox/addon/4703
+                home page
+
+FlashGot.
+---------
+
+The best Firefox download manager integration.
+
+  http://flashgot.net
+                home page
+
+DownloadHelper.
+---------------
+
+  http://www.downloadhelper.net
+                home page
+
+GreaseMonkey.
+-------------
+
+Allows you to customize the way a webpage displays using small bits of JavaScript.
+
+  http://www.greasespot.net
+                home page
+  https://addons.mozilla.org/firefox/748
+                download page
+
+How to disable GZIP compression in Firefox?
+===========================================
+::
+
+  user_pref("network.http.accept-encoding", ""); // default - "gzip,deflate".
+
+Restart the Firefox in Safe Mode.
+=================================
+
+Poorly designed or incompatible extensions can cause problems with your browser, including
+make it crash, slow down page display, etc::
+
+  $ firefox -safe-mode
+
+Hot calc by Firefox.
+====================
+
+At URI type some thing like "javascript: 4+5"
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/frame.html	Sun Nov 20 20:14:48 2011 +0200
@@ -0,0 +1,10 @@
+<html>
+<head>
+    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+    <title>tips index</title>
+</head>
+<frameset cols="220,*">
+    <frame src="frame-index.html" name="toc">
+    <frame src="index.html" name="article">
+</frameset>
+</html>
--- a/git.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/git.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -175,6 +175,24 @@
   $ export GIT_CURL_VERBOSE=1
   $ git ...
 
+Push new repo to remote.
+========================
+::
+
+  $ mkdir $REPO
+  $ cd $REPO
+  $ git init
+  $ git add .
+  $ git commit -m "Initial commit"
+  $ git remote add origin https://$USER:$PASS@$HOST/$REPO
+  $ git push -u origin master
+
+Find most recent tag for revision.
+==================================
+::
+
+  $ git describe $REV
+
 Using git to work with SVN offline.
 ===================================
 
--- a/hg.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/hg.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -410,11 +410,19 @@
 
 Find greatest common ancestor of changesets.
 ============================================
+::
 
   $ hg help revsets
   $ hg log -r "ancestor($rev1,$rev2)"
   $ hg log -r "ancestor($rev1,ancestor($rev2,$rev3))"
 
+Find most recent tag for revision.
+==================================
+::
+
+  $ hg log -r "sort(tag() and ancestors($REV),-date)"
+  $ hg log -r $REV --template "{latesttag}-{latesttagdistance}-{node|short}\n"
+
 Hooks.
 ======
 
--- a/html.rst	Fri Oct 14 23:48:24 2011 +0300
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,12 +0,0 @@
--*- mode: outline; coding: utf-8 -*-
-
-* Page encoding.
-
-Place in HEAD tag (CHARSET is one among of defined by
-http://www.iana.org/assignments/character-sets):
-
-  <meta http-equiv="Content-Type" content="text/html; charset=CHARSET">
-
-See
-
-  http://www.w3.org/TR/REC-html40/charset.html#h-5.2.2
--- a/index-frame.html	Fri Oct 14 23:48:24 2011 +0300
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,10 +0,0 @@
-<html>
-<head>
-    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-    <title>tips index</title>
-</head>
-<frameset cols="220,*">
-    <frame src="index.html" name="toc">
-    <frame src="index.html" name="article">
-</frameset>
-</html>
--- a/index.sh	Fri Oct 14 23:48:24 2011 +0300
+++ b/index.sh	Sun Nov 20 20:14:48 2011 +0200
@@ -18,20 +18,12 @@
 
 for file in *.rst *.txt; do
   ext=${file##*.}
-  name=${file%.${ext}}
-  case $ext in
-    txt)
-      case "$1" in
-        chm) printf '  <li><a href="%s.txt">%s</a>\n' $name $name ;;
-        frame) printf '  <li><a href="%s.txt" target="article">%s</a>\n' $name $name ;;
-      esac
-      ;;
-    rst)
-      case "$1" in
-        chm) printf '  <li><a href="%s.html">%s</a>\n' $name $name ;;
-        frame) printf '  <li><a href="%s.html" target="article">%s</a>\n' $name $name ;;
-      esac
-      ;;
+  [ "$ext" = "rst" ] && ext=html
+  name=${file%.*}
+  case "$1" in
+    html) echo "  <li><a href=\"$name.$ext\">$name</a>" ;;
+    frame) echo "  <li><a href=\"$name.$ext\" target=\"article\">$name</a>" ;;
+    *) exit 1 ;;
   esac
 done
 
--- a/lang-comp.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/lang-comp.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -11,6 +11,20 @@
   http://en.wikipedia.org/wiki/Comparison_of_programming_languages
   http://en.wikipedia.org/wiki/Comparison_of_programming_languages_%28basic_instructions%29
 
+Lang popularity.
+================
+
+  http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html
+                TIOBE Programming Community Index
+  http://www.langpop.com/
+                Programming Language Popularity
+  http://www.google.com/trends
+                Google trends (history of search request count).
+  http://stackoverflow.com/questions/48997/what-programming-language-is-most-popular-today
+                what-programming-language-is-most-popular-today
+  http://www.koders.com/
+                Search code by lang/licence.
+
 shootout.alioth.debian.org.
 ===========================
 
--- a/music-soft.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/music-soft.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -5,6 +5,12 @@
 ========
 .. contents::
 
+Converting music formats.
+=========================
+::
+
+  $ sox $from $to
+
 Rosegarden.
 ===========
 
--- a/proj-hosting.rst	Fri Oct 14 23:48:24 2011 +0300
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,9 +0,0 @@
--*- mode: outline; coding: utf-8 -*-
-
-* freshmeat
-
-Provide link to project home page, sources, changelog, demo site.
-
-See
-
-  http://freshmeat.net
--- a/refcard.rst	Fri Oct 14 23:48:24 2011 +0300
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
--*- mode: outline; coding: utf-8; -*-
-
-* About.
-
-Usually constructed from TeX/LaTeX source.
-
-  http://en.wikipedia.org/wiki/Reference_card
-
-* Hosting site.
-
-  http://refcards.com
-  http://www.digilife.be/quickreferences/quickrefs.htm
-  http://www.cheat-sheets.org
-  http://www.addedbytes.com/cheat-sheets/
-  http://refcardz.dzone.com/
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/windows-reg.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -0,0 +1,36 @@
+
+=================
+ Registry files.
+=================
+
+::
+
+  cmd# regedit.exe /s path-to.reg
+
+  http://support.microsoft.com/kb/310516
+                How to add, modify, or delete registry subkeys and values by
+                using a registration entries (.reg) file.
+
+Syntax of .Reg Files.
+=====================
+
+A .reg file has the following syntax::
+
+  RegistryEditorVersion
+  Blank line
+  [RegistryPath1]
+  "DataItemName1"="DataType1:DataValue1"
+  DataItemName2"="DataType2:DataValue2"
+  Blank line
+  [RegistryPath2]
+  "DataItemName3"="DataType3:DataValue3"
+
+Deleting Registry Keys and Values.
+==================================
+::
+
+  [-HKEY_LOCAL_MACHINE\Software\Test]
+
+  [HKEY_LOCAL_MACHINE\Software\Test]
+  "TestValue"=-
+
--- a/windows.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/windows.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -420,6 +420,10 @@
 Change NTFS permission.
 =======================
 
+  http://support.microsoft.com/kb/919240
+                The Icacls.exe utility is available for Windows Server 2003 with
+                Service Pack 2
+
 Change NTFS permission with 'icacls'.
 -------------------------------------
 
@@ -434,7 +438,11 @@
 
 Recursively change the owner of all matching files to the specified user::
 
-  cmd> icacls /setowner %user% /t /c
+  cmd> icacls %dir% /setowner %user% /t /c
+
+or simply::
+
+  cmd> takeown /r /f %file%
 
 Recursively grand full access for everyone::
 
@@ -501,3 +509,10 @@
 
   cmd> systeminfo
 
+Automatically logon to Windows.
+===============================
+::
+
+  cmd# control userpasswords2
+
+
--- a/x.rst	Fri Oct 14 23:48:24 2011 +0300
+++ b/x.rst	Sun Nov 20 20:14:48 2011 +0200
@@ -91,7 +91,7 @@
                 hierarchy. A colon (:) is used to separate the resource
                 declaration from the actual value.
 
-Comment start with '!' char and goes up to end of line or C-like /* */.
+Comment start with '!' char and goes up to end of line or C-like ``/* */``.
 
 Use xprop utility to find classes and resources used by application.