Top Banner
AERT - Notes Documentation Release 1.0 a.e.r.t January 17, 2014
27

AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

May 24, 2020

Download

Documents

dariahiddleston
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes DocumentationRelease 1.0

a.e.r.t

January 17, 2014

Page 2: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down
Page 3: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

Contents

1 Contents 31.1 Project Management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31.2 .NET . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31.3 Python . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41.4 Javascript . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41.5 Git . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51.6 Design / CSS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61.7 Analytics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61.8 reST . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

2 Indexs and tables 19

Bibliography 21

Python Module Index 23

i

Page 4: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

ii

Page 5: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

Project management & other technical notes.

See also:

• Online reading

• Git & GitHub

Contents 1

Page 6: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

2 Contents

Page 7: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

CHAPTER 1

Contents

1.1 Project Management

1.1.1 Meeting Minutes

Exemples : Gnome Board Meeting Minutes

1.2 .NET

1.2.1 Guidelines

• http://www.mono-project.com/Coding_Guidelines

• http://git.gnome.org/browse/banshee/tree/HACKING

• http://msdn.microsoft.com/en-us/library/ms229042.aspx

1.2.2 CMS

+++++ Orchard Web CMS (ASP.NET MVC)

1.2.3 Dependency Management

+++++ NuGet Visual Studio extension that makes it easy to install and update open source libraries+++++ Autofac Dependency Injection - Fast+++-- NInject Dependency Injection - Easy

1.2.4 Testing

+++++ SpecFlow Binding business requirements to code (BDD)

1.2.5 Helpers - Other

+++++ FluentPath FluentPath implements a modern wrapper around System.IO (Lambdas)

3

Page 8: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

1.3 Python

1.3.1 Django

+++++ django-extensions Custom extensions+++++ Satchmo eCommerce+++++ Haystack Modular search for django++++- djangopackages Index...++++- django-guardian Implementation of per object permissions for Django 1.2+++++- django-compressor Compresses linked and inline javascript or CSS into a single cached file+++-- dse Simplified “bulk” insert/update/delete for Django.

1.3.2 Utils

+++++ psutils A process utilities module for Python (Ram, disk, ...)

1.3.3 GUI

++++- camelot Framework RAD reposant sur QT et SQL Alchemy

1.4 Javascript

1.4.1 UI Frameworks

+++++ Kendo UI Complete Framework for HTML5 apps

1.4.2 Charting

+++++ Flot Charts Attractive JavaScript plotting for jQuery+++++ Peity jQuery plugin that converts data to canvas+++++ Highcharts JS ...+++-- JqPlot Plotting and charting plugin for the jQuery

1.4.3 Vector Graphics

++++- Raphaël JS ...

1.4.4 Spreadsheet / Excel

++++- SlickGrid A lightening fast JavaScript grid/spreadsheet

4 Chapter 1. Contents

Page 9: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

1.4.5 Navigation / Menu / Tree

++++- JQuery Superfish jQuery menu plugin++++- jsTree Cross browser tree component

1.4.6 Caroussel

++++- jQuery CyclePlugin

The jQuery Cycle Plugin is a slideshow plugin that supports many different typesof transition effects.

1.4.7 Tooltips

++++- JQuery Tipsy Tooltips

1.4.8 Calendar

++++- JQuery FullCalendar Full-sized drag & drop event calendar (jQuery plugin)

1.4.9 HTML 5

++++- html5shim JavaScript shim for IE to recognise and style the HTML5 elements+++-- Modernizr Tests browser’s html5 capabilities and manages js dependancies

1.5 Git

1.5.1 Guidelines

• http://live.gnome.org/Git/Developers

1.5.2 My Aliases

[alias]lg = log --graph --pretty=format:’%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset’ --abbrev-commit --date=relativeco = commit -a

1.5.3 Contributing

See Contributing

1.5.4 Get Total Commits Number in git

$ git rev-list --all | wc-l

1.5. Git 5

Page 10: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

1.5.5 List Branches and Tracking Info

$ git branch -avv

1.5.6 Combine multiple commits into one

Use git rebase than interactively pick and squash ( see here<http://feeding.cloud.geek.nz/2010/08/combining-multiple-commits-into-one.html>)

1.6 Design / CSS

1.6.1 Resources

+++++ FamFam-Fam

Silk is a smooth, free icon set, containing over 700 16-by-16 pixel icons instrokably-soft PNG format

1.6.2 CSS Frameworks

+++++ Bootstrap Twitter HTML, CSS, and JS toolkit from Twitter+++++ {wrap}bootstrap Themes & templates for bootstrap++--- 960.gs CSS Grid System

1.6.3 Templates

++--- JustFreeTemplates example

1.6.4 Colorschemes

+++++ Solarized Light + Dark

1.7 Analytics

1.7.1 Web Analytics

+++++ Piwik Piwik aims to be an open source alternative to Google Analytics

1.8 reST

A simple markup language for plain text files.

6 Chapter 1. Contents

Page 11: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

1.8.1 Structural elements

Sectioning

Emacs

C-c C-a or C-= Format the text above as a title or move it down in the decoration hierarchy.C-- C-c C-a Move the title one level up in the hierarchy.C-c C-h Display the title decoration hierarchy.

Titles are under- (and over-)lined (decorated) by =*-^"~ as below. The exact order of the decoration is notimportant, the one below is the Python convention.

####Part####

*******Chapter*******

Section=======

Subsection----------

Subsubsection^^^^^^^^^^^^^

Paragraph"""""""""

Normal paragraphs are separated by a blank line.

Transitions

Any repetition of 4 or more punctuation characters with preceding and trailing blank line is a transition, and lookslike this:

1.8.2 Inline markup

*emphasize* emphasize**emphasize strongly** emphasize strongly‘‘code‘‘ code‘don’t know‘ don’t know

Code for example

Asterisk \*, back-quote \‘and a **mark**\ up.

The following example illustrates special cases:

Asterisk *, back-quote ‘ and a markup.

1.8. reST 7

Page 12: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

1.8.3 Lists

Bullet list

Code for examples

- First item with some lengthytext wrapping hopefullyacross several lines.

- Second item

2. We start with point number 2#. Automatically numbered item.

a) Point ab) Point b#) Automatic point c.

• First item with some lengthy text wrapping hopefully across several lines.

• Second item

Enumerated list

2. We start with point number 2

3. Automatically numbered item.

1. Point a

2. Point b

3. Automatic point c.

Note: Automatic alphabetic numbering works wrongly in Sphinx, but does work with plain rst2html.

Definition list

Code for example

whatDefinition of "what". We add a fewwords to show the line wrapping.

howDefinition of "how".

what Definition of “what”. We add a few words to show the line wrapping.

how Definition of “how”.

.

Field list

8 Chapter 1. Contents

Page 13: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

Code for examples

:Name: Christoph Reller:Long: Here we insert more

text to show the effect ofmany lines (in Pygments).

:Remark:Start on the next line.

-v An option-o file Same with value--delta A long option--delta=len Same with value

Name Christoph Reller

Long Here we insert more text to show the effect of many lines (in Pygments).

Remark Start on the next line.

Options list

E.g. for listing command line options.

-v An option

-o file Same with value

--delta A long option

--delta=len Same with value

1.8.4 Blocks

Literal Blocks

Code for example

Block one::

**No** interpretation of|special| characters.

Another block! ::

In the text body,indentation is

preserved

A block which is not interpreted at all is preceded by a :: and a blank line. The block must be intended. If nowhite space is preceding the :: then it is displayed as ”:”.

Block one:

**No** interpretation of|special| characters.

Another block!

1.8. reST 9

Page 14: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

In the text body,indentation is

preserved

Line blocks

Code for example

| Line block| New line and we are still onthe same line

| Yet a new line

In a line block every line is preceded with | and at least one space.

Line blockNew line and we are still on the same line

Yet a new line

Block quotes

Code for example

blah blah blah

blah blah blah blah blahblah blah blah blah blahblah blah blah blah blah

blah blah blah.

The different indentation levels of paragraphs are preserved.

blah blah blah

blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah

blah blah blah.

1.8.5 Tables

Simple tables

10 Chapter 1. Contents

Page 15: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

Code for the examples

== ==aA bBcC dD== ==

===== ======Vokal Umlaut===== ======aA äÄoO öÖ===== ======

===== ===== ======Inputs Output------------ ------A B A or B

===== ===== ======False False------------ ------True False TrueFalse True TrueTrue True============ ======

=========== ================1. Hallo | blah blah blah

blah blah blahblah

| blah blah2. Here We can wrap the

text in source32. There **aha**=========== ================

Tables are preceded and ended with a sequence of “=” to indicate the columns, e.g:

aA bBcC dD

Headers are indicated by another sequence of “=”, e.g:

Vokal UmlautaA äÄoO öÖ

Column spans are followed by a sequence of “-” (except for the last header or last row of the table where we musthave “=”), e.g:

Inputs OutputA B A or BFalse FalseTrue False TrueFalse True TrueTrue True

Table cells are treated like a small document on their own up to line breaks, e.g:

1.8. reST 11

Page 16: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

1. Halloblah blah blah blah blah blah blahblah blah

2. HereWe can wrap the text in source

32. Thereaha

Grid tables

Code for example

+--------+--------+-----------+| Header | Header with 2 cols |+========+========+===========+| A | Lists: | **C** |+--------+ - aha +-----------+| B:: | - yes | | a block || | | of text || *hey* | #. hi | | a break |+--------+--------+-----------+

Grid tables have a more difficult syntax but can express more complex tables.

Header Header with 2 colsA yes

1. hi

C

B:

*hey*

a block of texta break

1.8.6 Explicit Markup

They all begin with two periods and a white space.

Footnotes

12 Chapter 1. Contents

Page 17: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

Code for example

In the text [2]_.

.. [2] In the footnote.

First automatic [#]_.Another automatic [#]_.

.. [#] The first automatic.

.. [#] The other automatic.

A labeled automatic [#one]_.Another of these [#two]_.

.. [#one] footnote.

.. [#two] labeled footnotes.

An autosymbol [*]_.More autosymbol [*]_.

.. rubric:: Footnotes

.. [*] footnote.

.. [*] footnotes.

.. [2] precedes the definition of the footnote 2. It is referenced by [2]_. E.g.

In the text 1.

First automatic 2. Another automatic 3.

A labeled automatic 4. Another of these 5.

An autosymbol 6. More autosymbol 7.

There is no labeled version of these autosymbol footnotes.

Citations

Code for example

We cite [REL09]_ or REL09_or even rel09_.

.. [REL09] Citation

.. [REL2009] is followed by the definition of the citation REL2009. It is referenced as [REL2009]_ orREL2009_. Citation labels can contain underlines, hyphens and fullstops. Case is not significant. In Sphinx,definition and reference can reside in different files.

We cite [REL09] or REL09 or even rel09.1 In the footnote.2 The first automatic.3 The other automatic.4 footnote.5 labeled footnotes.6 footnote.7 footnotes.

1.8. reST 13

Page 18: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

Hypertext links

External

There exist two version for doing this. Either in a citation style or in an inline style.

Code for examples

A link_ in citation style.

.. _link: http://www.google.ch

In-line versions are‘link <http://www.google.ch>‘__or ‘<http://www.google.ch>‘__or (in Sphinx) http://www.google.ch.

Citation style:

A link in citation style.

In printed documents the link will be listed similar as a citation, as opposed to HTML documents.

In-line style:

In-line versions are link or http://www.google.ch or (in Sphinx) http://www.google.ch.

Note: The syntax ‘link <URI>‘_ produces both a link and a link name as if you would have written .._link: URI . This means that you can re-reference the same target later in the document as ‘link‘_.

To create an anonymous link (a link without specifying a name) use double underscores ‘link <URI>‘__.This form is necessary if you want many links to have the same name, and it is the preferred form for one-time-usedlinks and for links of the form ‘<URI>‘__.

Internal

To define a label for any text location, precede it with:

.. _‹label›:

plus a blank line. There are two ways of referencing a label.

The Sphinx way (preferred)

To reference ‹label› defined in any document of the project use:

:ref:‘‹displayed text› <‹label›>‘

If the ‹label› definition is followed by a section title then ‹displayed text› can be omitted and will bereplaced by the title.

E.g. this section is preceded with .. _internal:, so we have:

:ref:‘internal‘ Internal:ref:‘This section <internal>‘ This section

This is the preferred way because it allows linking across files. E.g. :ref:subversion repository URL<svnRepoURL> links to my document on subversion.

In Sphinx it is possible to reference a document as follows

:doc:‘reST‘ reST

14 Chapter 1. Contents

Page 19: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

The reST way

Given a definition of ‹label› has been made in the document, the following will be substituted by ‹label›and link to it:

‘‹label›‘_

Section titles, footnotes, and citations automatically are link targets. ‘Internal‘_ produces Internal.

1.8.7 Directives

Directives are a general-purpose extension mechanism. The general syntax is similar to Explicit Markup:

.. ‹name›:: ‹argument 1›‹argument 2›

:‹option 1›: ‹value›

‹body›

reST directives

Create a table of contents containing (sub)titles ranging from level 1 to level ‹number›:

.. contents:: ‘Table of contents‘:depth: ‹number›

Include an image:

.. image:: ‹file name›

General replacements:

.. |‹something›| ‹directive›:: here we define what ‹something› is

here |‹something›| will be replaced by its definition.

Possible ‹directive›s are replace or image.

Including a reST file:

.. include:: ‹file name›

Note: Don’t use the same file name extension as your source files. Otherwise Sphinx will mistake this file as oneof your regular source files.

Raw code can be written as:

.. raw:: ‹writer›

‹code›

where ‹writer› is html or latex (or some other output writer) and ‹code› is the actual code to be inserted.

1.8. reST 15

Page 20: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

Sphinx directives

Create a table of contents across files:

.. toctree:::maxdepth: ‹depth›:glob:

‹file 1 without file name extension›‹file 2 without file name extension›

A glob option enables to use wildcards in the filenames, e.g. /comp/*means all files under the directory comp.

Note: Don’t try to reference the file which contains the toctree directive, otherwise a recursive loop occurs.Use the normal :ref: reST table of contents <reST-tableOfContents>‘ directive instead.

Note: The depth can be further restricted per file by inserting the following Field list type element in the veryfirst line of the file:

:tocdepth: ‹depth›

Entries in the index are created automatically from all information units (like functions, classes or attributes).Explicit manual entries are made as:

.. index:: ‹keyword 1›, ‹keyword 2›, ...

.. index::single: ‹keyword›; ‹sub-keyword›

.. index::pair: ‹keyword 1st part›; ‹keyword 2nd part›

The first two versions create single (sub-)entries, while the last version creates two entries “‹keyword 1st part›;‹keyword 2nd part›” and “‹keyword 2nd part›; ‹keyword 1st part›”.

A glossary is created as follows:

.. glossary::

‹reST definition list›

Set Pygment to ‹language› for code highlighting in Literal Blocks globally for the whole file:

.. highlight:: ‹language›:linenothreshold: ‹number›

The additional linenothreshold option switches on line numbering for blocks of size beyond ‹number› lines.

Specify the highlighting for a single literal block:

.. code-block:: ‹language›:linenos:

‹body›

16 Chapter 1. Contents

Page 21: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

The linenos option switches on line numbering.

Including a file as a literal block:

.. literalinclude:: ‹filename›:language: ‹language›:linenos:

The options language and linenos set the highlighting to ‹language› and enables line numbers respec-tively.

Create a sidebar with ‹Title› and ‹body› which is treated like a document on its own:

.. sidebar:: ‹Title›

‹body›

Create a boxed note with ‹text›:

.. note:: ‹text›

Note: This is a note.

Create a boxed warning with ‹text›:

.. warning:: ‹text›

Warning: This is a warning.

Create a see also box:

.. seealso::

‹reST definition list›

See also:

Apples A kind of fruit.

Create a title not appearing in the table of contents by:

.. rubric:: ‹Title›

Create a centered, boldface text block with:

.. centered:: ‹text block›

There are very powerful directives in Sphinx for documenting source code.

1.8. reST 17

Page 22: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

Comments

Code for example

.. CommentEven more comment

Not comment anymore

Everything starting like a directive with two periods and a space but is followed by normal text is a comment.Mark the indentation in the example:

Not comment anymore

1.8.8 Sphinx

Project

To start a Sphinx project use the interactive sphinx-quickstart command. This will ask you all the neces-sary questions.You can choose to build with a Makefile.

Customization is done in the file conf.py and the Makefile.

18 Chapter 1. Contents

Page 23: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

CHAPTER 2

Indexs and tables

• genindex

• modindex

• search

19

Page 24: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

20 Chapter 2. Indexs and tables

Page 25: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

Bibliography

[REL09] Citation

21

Page 26: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

AERT - Notes Documentation, Release 1.0

22 Bibliography

Page 27: AERT - Notes Documentation€¦ · AERT - Notes Documentation, Release 1.0 1.8.1Structural elements Sectioning Emacs C-c C-a or C-= Format the text above as a title or move it down

Python Module Index

aAnalytics, 6

dDesign, 6DotNet, 3

gGit, 5

jJavascript, 4

pProjectManagement, 3Python, 4

rreST, 6

23