1. Thejesh GN
  2. code.thejeshgn.com

Commits

Thejesh GN  committed 5377ad4

initial

  • Participants
  • Branches default

Comments (0)

Files changed (22)

File .hgignore

View file
  • Ignore whitespace
+syntax: glob
+
+html
+.tmp

File content/help/how.md

View file
  • Ignore whitespace
+#How to use this wiki?
+
+##Start
+This wiki is maintained in [version control](https://bitbucket.org/mavrix/docs/) for tracking and maintenance. This is based on the project called [markdoc](http://markdoc.org/) .
+
+You can install marcdoc by running **`pip install Markdoc`**. The actual content of this wiki is stored as markdown files in [content](https://bitbucket.org/mavrix/docs/src/tip/content) folder. You  need to build the wiki before viewing. Go to the **`docs`** repo folder and **`markdoc build`** which should generate html. Now you can browse the contents in your html folder using browser. If you want to share the docs with team. Run  **`markdoc serve`**.
+
+##Linking
+Every page in your wiki will likely link to several other pages. Markdoc does not require any special syntax for internal links; the usual Markdown format will work. An example of a link from this very page follows:
+
+For a comprehensive guide to the Markdown syntax, consult the \[markup reference documentation\]\(/ref/markup\). As you can see, the link href is an absolute path to the document, without any extension. Markdoc will process this and convert it into a relative path when rendering the corresponding HTML. This means that you can host Markdoc wikis under sub-directories on a web server, and the links will still work properly.
+
+If you split your wiki up into sub-directories (for example, in this wiki, there is an internals/ directory), the pattern remains the same. A link to the internals/rendering document looks like this:
+
+A link to the \[internals/rendering\]\(/internals/rendering\) document.
+
+Note that links will only be made relative if they begin with a / character; for example, a link to http://www.google.com/ will be left untouched.
+
+
+##[Markdown syntax](/help/markup.html)
+##[Code Syntax Highlighting](/help/syntax-highlighting.html)

File content/help/markup.md

View file
  • Ignore whitespace
+#Markdown Syntax Guide
+
+Adapted from <http://daringfireball.net/projects/markdown/syntax>.
+
+[TOC]
+
+* * *
+
+## Overview
+
+### Philosophy
+
+Markdown is intended to be as easy-to-read and easy-to-write as is feasible.
+
+Readability, however, is emphasized above all else. A Markdown-formatted
+document should be publishable as-is, as plain text, without looking like it's
+been marked up with tags or formatting instructions. While Markdown's syntax has
+been influenced by several existing text-to-HTML filters -- including
+[Setext] [1], [atx] [2], [Textile] [3], [reStructuredText] [4], [Grutatext] [5],
+and [EtText] [6] -- the single biggest source of inspiration for Markdown's
+syntax is the format of plain text email.
+
+  [1]: http://docutils.sourceforge.net/mirror/setext.html
+  [2]: http://www.aaronsw.com/2002/atx/
+  [3]: http://textism.com/tools/textile/
+  [4]: http://docutils.sourceforge.net/rst.html
+  [5]: http://www.triptico.com/software/grutatxt.html
+  [6]: http://ettext.taint.org/doc/
+
+To this end, Markdown's syntax is comprised entirely of punctuation characters,
+which punctuation characters have been carefully chosen so as to look like what
+they mean. E.g., asterisks around a word actually look like \*emphasis\*.
+Markdown lists look like, well, lists. Even blockquotes look like quoted
+passages of text, assuming you've ever used email.
+
+
+
+### Inline HTML
+
+Markdown's syntax is intended for one purpose: to be used as a format for
+*writing* for the web.
+
+Markdown is not a replacement for HTML, or even close to it. Its syntax is very
+small, corresponding only to a very small subset of HTML tags. The idea is *not*
+to create a syntax that makes it easier to insert HTML tags. In my opinion, HTML
+tags are already easy to insert. The idea for Markdown is to make it easy to
+read, write, and edit prose. HTML is a *publishing* format; Markdown is a
+*writing* format. Thus, Markdown's formatting syntax only addresses issues that
+can be conveyed in plain text.
+
+For any markup that is not covered by Markdown's syntax, you simply use HTML
+itself. There's no need to preface it or delimit it to indicate that you're
+switching from Markdown to HTML; you just use the tags.
+
+The only restrictions are that block-level HTML elements -- e.g. `<div>`,
+`<table>`, `<pre>`, `<p>`, etc. -- must be separated from surrounding content by
+blank lines, and the start and end tags of the block should not be indented with
+tabs or spaces. Markdown is smart enough not to add extra (unwanted) `<p>` tags
+around HTML block-level tags.
+
+For example, to add an HTML table to a Markdown article:
+
+    :::text
+    This is a regular paragraph.
+    
+    <table>
+        <tr>
+            <td>Foo</td>
+        </tr>
+    </table>
+    
+    This is another regular paragraph.
+
+Note that Markdown formatting syntax is not processed within block-level HTML
+tags. E.g., you can't use Markdown-style `*emphasis*` inside an HTML block.
+
+Span-level HTML tags -- e.g. `<span>`, `<cite>`, or `<del>` -- can be used
+anywhere in a Markdown paragraph, list item, or header. If you want, you can
+even use HTML tags instead of Markdown formatting; e.g. if you'd prefer to use
+HTML `<a>` or `<img>` tags instead of Markdown's link or image syntax, go right
+ahead.
+
+Unlike block-level HTML tags, Markdown syntax *is* processed within span-level
+tags.
+
+
+### Automatic Escaping for Special Characters
+
+In HTML, there are two characters that demand special treatment: `<` and `&`.
+Left angle brackets are used to start tags; ampersands are used to denote HTML
+entities. If you want to use them as literal characters, you must escape them as
+entities, e.g. `&lt;`, and `&amp;`.
+
+Ampersands in particular are bedeviling for web writers. If you want to write
+about 'AT&T', you need to write '`AT&amp;T`'. You even need to escape ampersands
+within URLs. Thus, if you want to link to:
+
+    :::text
+    http://images.google.com/images?num=30&q=larry+bird
+
+you need to encode the URL as:
+
+    :::text
+    http://images.google.com/images?num=30&amp;q=larry+bird
+
+in your anchor tag `href` attribute. Needless to say, this is easy to forget,
+and is probably the single most common source of HTML validation errors in
+otherwise well-marked-up web sites.
+
+Markdown allows you to use these characters naturally, taking care of all the
+necessary escaping for you. If you use an ampersand as part of an HTML entity,
+it remains unchanged; otherwise it will be translated into `&amp;`.
+
+So, if you want to include a copyright symbol in your article, you can write:
+
+    :::text
+    &copy;
+
+and Markdown will leave it alone. But if you write:
+
+    :::text
+    AT&T
+
+Markdown will translate it to:
+
+    :::text
+    AT&amp;T
+
+Similarly, because Markdown supports [inline HTML](#inline-html), if you use
+angle brackets as delimiters for HTML tags, Markdown will treat them as such.
+But if you write:
+
+    :::text
+    4 < 5
+
+Markdown will translate it to:
+
+    :::text
+    4 &lt; 5
+
+However, inside Markdown code spans and blocks, angle brackets and ampersands
+are *always* encoded automatically. This makes it easy to use Markdown to write
+about HTML code. (As opposed to raw HTML, which is a terrible format for writing
+about HTML syntax, because every single `<` and `&` in your example code needs
+to be escaped.)
+
+
+* * *
+
+
+## Block Elements
+
+
+### Paragraphs and Line Breaks
+
+A paragraph is simply one or more consecutive lines of text, separated by one or
+more blank lines. (A blank line is any line that looks like a blank line -- a
+line containing nothing but spaces or tabs is considered blank.) Normal
+paragraphs should not be indented with spaces or tabs.
+
+The implication of the "one or more consecutive lines of text" rule is that
+Markdown supports "hard-wrapped" text paragraphs. This differs significantly
+from most other text-to-HTML formatters (including Movable Type's "Convert Line
+Breaks" option) which translate every line break character in a paragraph into a
+`<br />` tag.
+
+When you *do* want to insert a `<br />` break tag using Markdown, you end a line
+with two or more spaces, then type return.
+
+Yes, this takes a tad more effort to create a `<br />`, but a simplistic "every
+line break is a `<br />`" rule wouldn't work for Markdown. Markdown's
+email-style [blockquoting][bq] and multi-paragraph [list items][l] work best --
+and look better -- when you format them with hard breaks.
+
+  [bq]: #blockquote
+  [l]:  #list
+
+
+
+### Headers
+
+Markdown supports two styles of headers, [Setext] [1] and [atx] [2].
+
+Setext-style headers are "underlined" using equal signs (for first-level
+headers) and dashes (for second-level headers). For example:
+
+    :::text
+    This is an H1
+    =============
+    
+    This is an H2
+    -------------
+
+Any number of underlining `=`'s or `-`'s will work.
+
+Atx-style headers use 1-6 hash characters at the start of the line,
+corresponding to header levels 1-6. For example:
+
+    :::text
+    # This is an H1
+    
+    ## This is an H2
+    
+    ###### This is an H6
+
+Optionally, you may "close" atx-style headers. This is purely cosmetic -- you
+can use this if you think it looks better. The closing hashes don't even need to
+match the number of hashes used to open the header. (The number of opening
+hashes determines the header level.) :
+
+    :::text
+    # This is an H1 #
+    
+    ## This is an H2 ##
+    
+    ### This is an H3 ######
+
+
+### Blockquotes
+
+Markdown uses email-style `>` characters for blockquoting. If you're familiar
+with quoting passages of text in an email message, then you know how to create a
+blockquote in Markdown. It looks best if you hard wrap the text and put a `>`
+before every line:
+
+    :::text
+    > This is a blockquote with two paragraphs. Lorem ipsum dolor sit amet,
+    > consectetuer adipiscing elit. Aliquam hendrerit mi posuere lectus.
+    > Vestibulum enim wisi, viverra nec, fringilla in, laoreet vitae, risus.
+    > 
+    > Donec sit amet nisl. Aliquam semper ipsum sit amet velit. Suspendisse
+    > id sem consectetuer libero luctus adipiscing.
+
+Markdown allows you to be lazy and only put the `>` before the first line of a
+hard-wrapped paragraph:
+
+    :::text
+    > This is a blockquote with two paragraphs. Lorem ipsum dolor sit amet,
+    consectetuer adipiscing elit. Aliquam hendrerit mi posuere lectus.
+    Vestibulum enim wisi, viverra nec, fringilla in, laoreet vitae, risus.
+    
+    > Donec sit amet nisl. Aliquam semper ipsum sit amet velit. Suspendisse
+    id sem consectetuer libero luctus adipiscing.
+
+Blockquotes can be nested (i.e. a blockquote-in-a-blockquote) by adding
+additional levels of `>`:
+
+    :::text
+    > This is the first level of quoting.
+    >
+    > > This is nested blockquote.
+    >
+    > Back to the first level.
+
+Blockquotes can contain other Markdown elements, including headers, lists, and
+code blocks:
+
+    :::text
+    > ## This is a header.
+    > 
+    > 1.   This is the first list item.
+    > 2.   This is the second list item.
+    > 
+    > Here's some example code:
+    > 
+    >     return shell_exec("echo $input | $markdown_script");
+
+Any decent text editor should make email-style quoting easy. For example, with
+BBEdit, you can make a selection and choose Increase Quote Level from the Text
+menu.
+
+
+### Lists
+
+Markdown supports ordered (numbered) and unordered (bulleted) lists.
+
+Unordered lists use asterisks, pluses, and hyphens -- interchangably -- as list
+markers:
+
+    :::text
+    *   Red
+    *   Green
+    *   Blue
+
+is equivalent to:
+
+    :::text
+    +   Red
+    +   Green
+    +   Blue
+
+and:
+
+    :::text
+    -   Red
+    -   Green
+    -   Blue
+
+Ordered lists use numbers followed by periods:
+
+    :::text
+    1.  Bird
+    2.  McHale
+    3.  Parish
+
+It's important to note that the actual numbers you use to mark the list have no
+effect on the HTML output Markdown produces. The HTML Markdown produces from the
+above list is:
+
+    :::text
+    <ol>
+    <li>Bird</li>
+    <li>McHale</li>
+    <li>Parish</li>
+    </ol>
+
+If you instead wrote the list in Markdown like this:
+
+    :::text
+    1.  Bird
+    1.  McHale
+    1.  Parish
+
+or even:
+
+    :::text
+    3. Bird
+    1. McHale
+    8. Parish
+
+you'd get the exact same HTML output. The point is, if you want to, you can use
+ordinal numbers in your ordered Markdown lists, so that the numbers in your
+source match the numbers in your published HTML. But if you want to be lazy, you
+don't have to.
+
+If you do use lazy list numbering, however, you should still start the list with
+the number 1. At some point in the future, Markdown may support starting ordered
+lists at an arbitrary number.
+
+List markers typically start at the left margin, but may be indented by up to
+three spaces. List markers must be followed by one or more spaces or a tab.
+
+To make lists look nice, you can wrap items with hanging indents:
+
+    :::text
+    *   Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
+        Aliquam hendrerit mi posuere lectus. Vestibulum enim wisi,
+        viverra nec, fringilla in, laoreet vitae, risus.
+    *   Donec sit amet nisl. Aliquam semper ipsum sit amet velit.
+        Suspendisse id sem consectetuer libero luctus adipiscing.
+
+But if you want to be lazy, you don't have to:
+
+    :::text
+    *   Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
+    Aliquam hendrerit mi posuere lectus. Vestibulum enim wisi,
+    viverra nec, fringilla in, laoreet vitae, risus.
+    *   Donec sit amet nisl. Aliquam semper ipsum sit amet velit.
+    Suspendisse id sem consectetuer libero luctus adipiscing.
+
+If list items are separated by blank lines, Markdown will wrap the items in
+`<p>` tags in the HTML output. For example, this input:
+
+    :::text
+    *   Bird
+    *   Magic
+
+will turn into:
+
+    :::html
+    <ul>
+    <li>Bird</li>
+    <li>Magic</li>
+    </ul>
+
+But this:
+
+    :::text
+    *   Bird
+    
+    *   Magic
+
+will turn into:
+
+    :::html
+    <ul>
+    <li><p>Bird</p></li>
+    <li><p>Magic</p></li>
+    </ul>
+
+List items may consist of multiple paragraphs. Each subsequent paragraph in a
+list item must be indented by either 4 spaces or one tab:
+
+    :::text
+    1.  This is a list item with two paragraphs. Lorem ipsum dolor
+        sit amet, consectetuer adipiscing elit. Aliquam hendrerit
+        mi posuere lectus.
+        
+        Vestibulum enim wisi, viverra nec, fringilla in, laoreet
+        vitae, risus. Donec sit amet nisl. Aliquam semper ipsum
+        sit amet velit.
+        
+    2.  Suspendisse id sem consectetuer libero luctus adipiscing.
+
+It looks nice if you indent every line of the subsequent paragraphs, but here
+again, Markdown will allow you to be lazy:
+
+    :::text
+    *   This is a list item with two paragraphs.
+    
+        This is the second paragraph in the list item. You're
+    only required to indent the first line. Lorem ipsum dolor
+    sit amet, consectetuer adipiscing elit.
+    
+    *   Another item in the same list.
+
+To put a blockquote within a list item, the blockquote's `>` delimiters need to
+be indented:
+
+    :::text
+    *   A list item with a blockquote:
+    
+        > This is a blockquote
+        > inside a list item.
+
+To put a code block within a list item, the code block needs to be indented
+*twice* -- 8 spaces or two tabs:
+
+    :::text
+    *   A list item with a code block:
+    
+            <code goes here>
+
+
+It's worth noting that it's possible to trigger an ordered list by accident, by
+writing something like this:
+
+    :::text
+    1986. What a great season.
+
+In other words, a *number-period-space* sequence at the beginning of a line. To
+avoid this, you can backslash-escape the period:
+
+    :::text
+    1986\. What a great season.
+
+
+
+### Code Blocks
+
+Pre-formatted code blocks are used for writing about programming or markup
+source code. Rather than forming normal paragraphs, the lines of a code block
+are interpreted literally. Markdown wraps a code block in both `<pre>` and
+`<code>` tags.
+
+To produce a code block in Markdown, simply indent every line of the block by at
+least 4 spaces or 1 tab. For example, given this input:
+
+    :::text
+    This is a normal paragraph:
+    
+        This is a code block.
+
+Markdown will generate:
+
+    :::html
+    <p>This is a normal paragraph:</p>
+    
+    <pre><code>This is a code block.
+    </code></pre>
+
+One level of indentation -- 4 spaces or 1 tab -- is removed from each line of
+the code block. For example, this:
+
+    :::text
+    Here is an example of AppleScript:
+    
+        tell application "Foo"
+            beep
+        end tell
+
+will turn into:
+
+    :::html
+    <p>Here is an example of AppleScript:</p>
+    
+    <pre><code>tell application "Foo"
+        beep
+    end tell
+    </code></pre>
+
+A code block continues until it reaches a line that is not indented (or the end
+of the article).
+
+Within a code block, ampersands (`&`) and angle brackets (`<` and `>`) are
+automatically converted into HTML entities. This makes it very easy to include
+example HTML source code using Markdown -- just paste it and indent it, and
+Markdown will handle the hassle of encoding the ampersands and angle brackets.
+For example, this:
+
+    :::text
+        <div class="footer">
+            &copy; 2004 Foo Corporation
+        </div>
+
+will turn into:
+
+    :::html
+    <pre><code>&lt;div class="footer"&gt;
+        &amp;copy; 2004 Foo Corporation
+    &lt;/div&gt;
+    </code></pre>
+
+Regular Markdown syntax is not processed within code blocks. E.g., asterisks are
+just literal asterisks within a code block. This means it's also easy to use
+Markdown to write about Markdown's own syntax.
+
+
+
+### Horizontal Rules
+
+You can produce a horizontal rule tag (`<hr />`) by placing three or more
+hyphens, asterisks, or underscores on a line by themselves. If you wish, you may
+use spaces between the hyphens or asterisks. Each of the following lines will
+produce a horizontal rule:
+
+    :::text
+    * * *
+    
+    ***
+    
+    *****
+    
+    - - -
+    
+    ---------------------------------------
+
+
+* * *
+
+## Span Elements
+
+### Links
+
+Markdown supports two style of links: *inline* and *reference*.
+
+In both styles, the link text is delimited by [square brackets].
+
+To create an inline link, use a set of regular parentheses immediately after the
+link text's closing square bracket. Inside the parentheses, put the URL where
+you want the link to point, along with an *optional* title for the link,
+surrounded in quotes. For example:
+
+    :::text
+    This is [an example](http://example.com/ "Title") inline link.
+    
+    [This link](http://example.net/) has no title attribute.
+
+Will produce:
+
+    :::html
+    <p>This is <a href="http://example.com/" title="Title">
+    an example</a> inline link.</p>
+    
+    <p><a href="http://example.net/">This link</a> has no
+    title attribute.</p>
+
+If you're referring to a local resource on the same server, you can use relative
+paths:
+
+    :::text
+    See my [About](/about/) page for details.   
+
+Reference-style links use a second set of square brackets, inside which you
+place a label of your choosing to identify the link:
+
+    :::text
+    This is [an example][id] reference-style link.
+
+You can optionally use a space to separate the sets of brackets:
+
+    :::text
+    This is [an example] [id] reference-style link.
+
+Then, anywhere in the document, you define your link label like this, on a line
+by itself:
+
+    :::text
+    [id]: http://example.com/  "Optional Title Here"
+
+That is:
+
+*   Square brackets containing the link identifier (optionally indented from the
+    left margin using up to three spaces);
+*   followed by a colon;
+*   followed by one or more spaces (or tabs);
+*   followed by the URL for the link;
+*   optionally followed by a title attribute for the link, enclosed in double or
+    single quotes, or enclosed in parentheses.
+
+The following three link definitions are equivalent:
+
+    :::text
+    [foo]: http://example.com/  "Optional Title Here"
+    [foo]: http://example.com/  'Optional Title Here'
+    [foo]: http://example.com/  (Optional Title Here)
+
+The link URL may, optionally, be surrounded by angle brackets:
+
+    :::text
+    [id]: <http://example.com/>  "Optional Title Here"
+
+You can put the title attribute on the next line and use extra spaces or tabs
+for padding, which tends to look better with longer URLs:
+
+    :::text
+    [id]: http://example.com/longish/path/to/resource/here
+        "Optional Title Here"
+
+Link definitions are only used for creating links during Markdown processing,
+and are stripped from your document in the HTML output.
+
+Link definition names may consist of letters, numbers, spaces, and punctuation
+-- but they are *not* case sensitive. E.g. these two links:
+
+    :::text
+    [link text][a]
+    [link text][A]
+
+are equivalent.
+
+The *implicit link name* shortcut allows you to omit the name of the link, in
+which case the link text itself is used as the name. Just use an empty set of
+square brackets -- e.g., to link the word "Google" to the google.com web site,
+you could simply write:
+
+    :::text
+    [Google][]
+
+And then define the link:
+
+    :::text
+    [Google]: http://google.com/
+
+Because link names may contain spaces, this shortcut even works for multiple
+words in the link text:
+
+    :::text
+    Visit [Daring Fireball][] for more information.
+
+And then define the link:
+
+    :::text
+    [Daring Fireball]: http://daringfireball.net/
+
+Link definitions can be placed anywhere in your Markdown document. I tend to put
+them immediately after each paragraph in which they're used, but if you want,
+you can put them all at the end of your document, sort of like footnotes.
+
+Here's an example of reference links in action:
+
+    :::text
+    I get 10 times more traffic from [Google] [1] than from
+    [Yahoo] [2] or [MSN] [3].
+    
+      [1]: http://google.com/        "Google"
+      [2]: http://search.yahoo.com/  "Yahoo Search"
+      [3]: http://search.msn.com/    "MSN Search"
+
+Using the implicit link name shortcut, you could instead write:
+
+    :::text
+    I get 10 times more traffic from [Google][] than from
+    [Yahoo][] or [MSN][].
+    
+      [google]: http://google.com/        "Google"
+      [yahoo]:  http://search.yahoo.com/  "Yahoo Search"
+      [msn]:    http://search.msn.com/    "MSN Search"
+
+Both of the above examples will produce the following HTML output:
+
+    :::html
+    <p>I get 10 times more traffic from <a href="http://google.com/"
+    title="Google">Google</a> than from
+    <a href="http://search.yahoo.com/" title="Yahoo Search">Yahoo</a>
+    or <a href="http://search.msn.com/" title="MSN Search">MSN</a>.</p>
+
+For comparison, here is the same paragraph written using Markdown's inline link
+style:
+
+    :::text
+    I get 10 times more traffic from [Google](http://google.com/ "Google")
+    than from [Yahoo](http://search.yahoo.com/ "Yahoo Search") or
+    [MSN](http://search.msn.com/ "MSN Search").
+
+The point of reference-style links is not that they're easier to write. The
+point is that with reference-style links, your document source is vastly more
+readable. Compare the above examples: using reference-style links, the paragraph
+itself is only 81 characters long; with inline-style links, it's 176 characters;
+and as raw HTML, it's 234 characters. In the raw HTML, there's more markup than
+there is text.
+
+With Markdown's reference-style links, a source document much more closely
+resembles the final output, as rendered in a browser. By allowing you to move
+the markup-related metadata out of the paragraph, you can add links without
+interrupting the narrative flow of your prose.
+
+
+### Emphasis
+
+Markdown treats asterisks (`*`) and underscores (`_`) as indicators of emphasis.
+Text wrapped with one `*` or `_` will be wrapped with an HTML `<em>` tag; double
+`*`'s or `_`'s will be wrapped with an HTML `<strong>` tag. E.g., this input:
+
+    :::text
+    *single asterisks*
+    
+    _single underscores_
+    
+    **double asterisks**
+    
+    __double underscores__
+
+will produce:
+
+    :::html
+    <em>single asterisks</em>
+    
+    <em>single underscores</em>
+    
+    <strong>double asterisks</strong>
+    
+    <strong>double underscores</strong>
+
+You can use whichever style you prefer; the lone restriction is that the same
+character must be used to open and close an emphasis span.
+
+Emphasis can be used in the middle of a word:
+
+    :::text
+    un*frigging*believable
+
+But if you surround an `*` or `_` with spaces, it'll be treated as a literal
+asterisk or underscore.
+
+To produce a literal asterisk or underscore at a position where it would
+otherwise be used as an emphasis delimiter, you can backslash escape it:
+
+    :::text
+    \*this text is surrounded by literal asterisks\*
+
+
+
+### Code
+
+To indicate a span of code, wrap it with backtick quotes (`` ` ``). Unlike a
+pre-formatted code block, a code span indicates code within a normal paragraph.
+For example:
+
+    :::text
+    Use the `printf()` function.
+
+will produce:
+
+    :::html
+    <p>Use the <code>printf()</code> function.</p>
+
+To include a literal backtick character within a code span, you can use multiple
+backticks as the opening and closing delimiters:
+
+    :::text
+    ``There is a literal backtick (`) here.``
+
+which will produce this:
+
+    :::html
+    <p><code>There is a literal backtick (`) here.</code></p>
+
+The backtick delimiters surrounding a code span may include spaces -- one after
+the opening, one before the closing. This allows you to place literal backtick
+characters at the beginning or end of a code span:
+
+    :::text
+    A single backtick in a code span: `` ` ``
+    
+    A backtick-delimited string in a code span: `` `foo` ``
+
+will produce:
+
+    :::html
+    <p>A single backtick in a code span: <code>`</code></p>
+    
+    <p>A backtick-delimited string in a code span: <code>`foo`</code></p>
+
+With a code span, ampersands and angle brackets are encoded as HTML entities
+automatically, which makes it easy to include example HTML tags. Markdown will
+turn this:
+
+    :::text
+    Please don't use any `<blink>` tags.
+
+into:
+
+    :::html
+    <p>Please don't use any <code>&lt;blink&gt;</code> tags.</p>
+
+You can write this:
+
+    :::text
+    `&#8212;` is the decimal-encoded equivalent of `&mdash;`.
+
+to produce:
+
+    :::html
+    <p><code>&amp;#8212;</code> is the decimal-encoded
+    equivalent of <code>&amp;mdash;</code>.</p>
+
+
+
+### Images
+
+Admittedly, it's fairly difficult to devise a "natural" syntax for placing
+images into a plain text document format.
+
+Markdown uses an image syntax that is intended to resemble the syntax for links,
+allowing for two styles: *inline* and *reference*.
+
+Inline image syntax looks like this:
+
+    :::text
+    ![Alt text](/path/to/img.jpg)
+    
+    ![Alt text](/path/to/img.jpg "Optional title")
+
+That is:
+
+*   An exclamation mark: `!`;
+*   followed by a set of square brackets, containing the `alt` attribute text
+    for the image;
+*   followed by a set of parentheses, containing the URL or path to the image,
+    and an optional `title` attribute enclosed in double or single quotes.
+
+Reference-style image syntax looks like this:
+
+    :::text
+    ![Alt text][id]
+
+Where "id" is the name of a defined image reference. Image references are
+defined using syntax identical to link references:
+
+    :::text
+    [id]: url/to/image  "Optional title attribute"
+
+As of this writing, Markdown has no syntax for specifying the dimensions of an
+image; if this is important to you, you can simply use regular HTML `<img>`
+tags.
+
+
+* * *
+
+
+## Miscellaneous
+
+### Automatic Links
+
+Markdown supports a shortcut style for creating "automatic" links for URLs and
+email addresses: simply surround the URL or email address with angle brackets.
+What this means is that if you want to show the actual text of a URL or email
+address, and also have it be a clickable link, you can do this:
+
+    :::text
+    <http://example.com/>
+
+Markdown will turn this into:
+
+    :::html
+    <a href="http://example.com/">http://example.com/</a>
+
+Automatic links for email addresses work similarly, except that Markdown will
+also perform a bit of randomized decimal and hex entity-encoding to help obscure
+your address from address-harvesting spambots. For example, Markdown will turn
+this:
+
+    :::text
+    <address@example.com>
+
+into something like this:
+
+    :::html
+    <a href="&#x6D;&#x61;i&#x6C;&#x74;&#x6F;:&#x61;&#x64;&#x64;&#x72;&#x65;
+    &#115;&#115;&#64;&#101;&#120;&#x61;&#109;&#x70;&#x6C;e&#x2E;&#99;&#111;
+    &#109;">&#x61;&#x64;&#x64;&#x72;&#x65;&#115;&#115;&#64;&#101;&#120;&#x61;
+    &#109;&#x70;&#x6C;e&#x2E;&#99;&#111;&#109;</a>
+
+which will render in a browser as a clickable link to "address@example.com".
+
+(This sort of entity-encoding trick will indeed fool many, if not most,
+address-harvesting bots, but it definitely won't fool all of them. It's better
+than nothing, but an address published in this way will probably eventually
+start receiving spam.)
+
+
+
+### Backslash Escapes
+
+Markdown allows you to use backslash escapes to generate literal characters
+which would otherwise have special meaning in Markdown's formatting syntax. For
+example, if you wanted to surround a word with literal asterisks (instead of an
+HTML `<em>` tag), you can use backslashes before the asterisks, like this:
+
+    :::text
+    \*literal asterisks\*
+
+Markdown provides backslash escapes for the following characters:
+
+    :::text
+    \   backslash
+    `   backtick
+    *   asterisk
+    _   underscore
+    {}  curly braces
+    []  square brackets
+    ()  parentheses
+    #   hash mark
+    +   plus sign
+    -   minus sign (hyphen)
+    .   dot
+    !   exclamation mark

File content/help/syntax-highlighting.md

View file
  • Ignore whitespace
+#Syntax Highlighting with Pygments
+
+[Markdown for Python][] supports syntax highlighting in your documents using [Pygments][]. Here’s how to set up and use it from Markdoc.
+
+  [markdown for python]: http://www.freewisdom.org/projects/python-markdown
+  [pygments]: http://pygments.org/
+
+First, install the extension in your `markdoc.yaml` file:
+
+    :::yaml
+    wiki-name: My Wiki
+    ## ...other settings...
+    markdown:
+      extensions:
+        - codehilite # the important bit
+
+Pygments should have been installed as a dependency when you installed Markdoc.
+
+Initially, syntax highlighting will be applied to every code block Markdown encounters. Pygments will guess which lexer to apply to each block. To specify the language of a block, add a `:::LANG` prefix to blocks of code. For example:
+
+    :::text
+    :::python
+    def hello():
+        print "Hello, World!"
+
+Will render to:
+
+    :::python
+    def hello():
+        print "Hello, World!"
+
+To switch syntax highlighting off for a block, use `:::text`.
+
+If you want a block to have line numbers, use `#!LANG` instead. For example:
+
+    :::text
+    #!ruby
+    class Foo
+      def bar
+        @baz
+      end
+    end
+
+Will render to:
+
+    #!ruby
+    class Foo
+      def bar
+        @baz
+      end
+    end
+
+If you add a shebang to a code block, like `#!/bin/bash` or `#!/usr/bin/env python`, the language will be guessed and the shebang included in the output. In the final text. So for example, the following:
+
+    :::text
+    #!/bin/bash
+    echo "Hello, World"
+
+Will render to:
+
+    #!/bin/bash
+    echo "Hello, World"

File content/index.md

View file
  • Ignore whitespace
+#Welcome to markwiki
+This is markwiki. This documentation itself is maintained in version control for tracking and maintenance. This is based on the project called [markdoc](http://markdoc.org/).
+
+You can install marcdoc by running **`pip install Markdoc`**. The actual content of this wiki is stored as markdown files in [content](https://bitbucket.org/mavrix/docs/src/tip/content) folder. You  need to build the wiki before viewing. Go to the **`docs`** repo folder and **`markdoc build`** which should generate html. Now you can browse the contents in your html folder using browser. If you want to share the docs with team. Run  **`markdoc serve`**. Read this [help](/help/how) documentation before you start editing.
+
+

File markdoc.yaml

View file
  • Ignore whitespace
+# Metadata
+wiki-name: "MarkWiki"
+google-analytics: "UA-XXXXXX-X"
+
+# Directories
+hide-prefix: "."
+wiki-dir: "content"
+static-dir: "static"
+html-dir: "html"
+template-dir: "templates"
+temp-dir: ".tmp"
+
+# Building
+document-extensions: [.md, .mdown, .markdown, .wiki, .text]
+generate-listing: always
+listing-filename: "_list.html"
+use-default-static: false
+use-default-templates: true
+
+# Rendering
+markdown:
+  extensions:
+    - codehilite
+    - def_list
+    - headerid
+    - toc
+
+# Serving
+server:
+  bind: '127.0.0.1'
+  port: 8010
+  num-threads: 10
+  name: 'localhost'
+  request-queue-size: 5
+  timeout: 10

File readme.markdown

View file
  • Ignore whitespace
+#Welcome
+This is an empty markwiki. This documentation itself is maintained in version control for tracking and maintenance. This is based on the project called [markdoc](http://markdoc.org/).
+## Install marcdoc 
+
+> pip install Markdoc
+
+
+## Editing 
+Contents are stored as markdown files in [content](https://bitbucket.org/mavrix/markwiki/src/tip/content) folder. 
+
+## View
+
+In your command prompt, go to docs repo folder
+> markdoc build
+
+Now you can browse the contents in your html folder using browser.
+
+
+If you want to share the docs with team. Run
+> markdoc serve
+
+
+
+

File static/media/css/pygments.css

View file
  • Ignore whitespace
+.codehilite  { background: #ffffff; }
+.codehilite .c { color: #999988; font-style: italic } /* Comment */
+.codehilite .err { color: #a61717; background-color: #e3d2d2 } /* Error */
+.codehilite .k { font-weight: bold } /* Keyword */
+.codehilite .o { font-weight: bold } /* Operator */
+.codehilite .cm { color: #999988; font-style: italic } /* Comment.Multiline */
+.codehilite .cp { color: #999999; font-weight: bold } /* Comment.Preproc */
+.codehilite .c1 { color: #999988; font-style: italic } /* Comment.Single */
+.codehilite .cs { color: #999999; font-weight: bold; font-style: italic } /* Comment.Special */
+.codehilite .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */
+.codehilite .gd .x { color: #000000; background-color: #ffaaaa } /* Generic.Deleted.Specific */
+.codehilite .ge { font-style: italic } /* Generic.Emph */
+.codehilite .gr { color: #aa0000 } /* Generic.Error */
+.codehilite .gh { color: #999999 } /* Generic.Heading */
+.codehilite .gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */
+.codehilite .gi .x { color: #000000; background-color: #aaffaa } /* Generic.Inserted.Specific */
+.codehilite .go { color: #888888 } /* Generic.Output */
+.codehilite .gp { color: #555555 } /* Generic.Prompt */
+.codehilite .gs { font-weight: bold } /* Generic.Strong */
+.codehilite .gu { color: #aaaaaa } /* Generic.Subheading */
+.codehilite .gt { color: #aa0000 } /* Generic.Traceback */
+.codehilite .kc { font-weight: bold } /* Keyword.Constant */
+.codehilite .kd { font-weight: bold } /* Keyword.Declaration */
+.codehilite .kp { font-weight: bold } /* Keyword.Pseudo */
+.codehilite .kr { font-weight: bold } /* Keyword.Reserved */
+.codehilite .kt { color: #445588; font-weight: bold } /* Keyword.Type */
+.codehilite .m { color: #009999 } /* Literal.Number */
+.codehilite .s { color: #d14 } /* Literal.String */
+.codehilite .na { color: #008080 } /* Name.Attribute */
+.codehilite .nb { color: #0086B3 } /* Name.Builtin */
+.codehilite .nc { color: #445588; font-weight: bold } /* Name.Class */
+.codehilite .no { color: #008080 } /* Name.Constant */
+.codehilite .ni { color: #800080 } /* Name.Entity */
+.codehilite .ne { color: #990000; font-weight: bold } /* Name.Exception */
+.codehilite .nf { color: #990000; font-weight: bold } /* Name.Function */
+.codehilite .nn { color: #555555 } /* Name.Namespace */
+.codehilite .nt { color: #000080 } /* Name.Tag */
+.codehilite .nv { color: #008080 } /* Name.Variable */
+.codehilite .ow { font-weight: bold } /* Operator.Word */
+.codehilite .w { color: #bbbbbb } /* Text.Whitespace */
+.codehilite .mf { color: #009999 } /* Literal.Number.Float */
+.codehilite .mh { color: #009999 } /* Literal.Number.Hex */
+.codehilite .mi { color: #009999 } /* Literal.Number.Integer */
+.codehilite .mo { color: #009999 } /* Literal.Number.Oct */
+.codehilite .sb { color: #d14 } /* Literal.String.Backtick */
+.codehilite .sc { color: #d14 } /* Literal.String.Char */
+.codehilite .sd { color: #d14 } /* Literal.String.Doc */
+.codehilite .s2 { color: #d14 } /* Literal.String.Double */
+.codehilite .se { color: #d14 } /* Literal.String.Escape */
+.codehilite .sh { color: #d14 } /* Literal.String.Heredoc */
+.codehilite .si { color: #d14 } /* Literal.String.Interpol */
+.codehilite .sx { color: #d14 } /* Literal.String.Other */
+.codehilite .sr { color: #009926 } /* Literal.String.Regex */
+.codehilite .s1 { color: #d14 } /* Literal.String.Single */
+.codehilite .ss { color: #990073 } /* Literal.String.Symbol */
+.codehilite .bp { color: #999999 } /* Name.Builtin.Pseudo */
+.codehilite .vc { color: #008080 } /* Name.Variable.Class */
+.codehilite .vg { color: #008080 } /* Name.Variable.Global */
+.codehilite .vi { color: #008080 } /* Name.Variable.Instance */
+.codehilite .il { color: #009999 } /* Literal.Number.Integer.Long */

File static/media/css/style.css

View file
  • Ignore whitespace
+html {
+  background-color: #f6f6f6;
+  font-size:15px; }
+
+body {
+  background-color: white;
+  margin: 0 auto;
+  width: 900px; }
+  body #breadcrumbs, body #content, body #footer, body #header {
+    background-color: white;
+    clear: both;
+    float: left;
+    overflow: hidden;
+    padding: 0 20px;
+    width: 900px; }
+  body #breadcrumbs {
+    border-bottom: 2px solid #f6f6f6;
+    height: 28px;
+    margin: 0;
+    padding-right: 20px;
+    width: 900px; }
+    body #breadcrumbs li {
+      float: left;
+      list-style: none;
+      margin: 0;
+      padding: 0; }
+      body #breadcrumbs li a {
+        display: block;
+        float: left;
+        padding: 0 8px; }
+      body #breadcrumbs li.last {
+        padding: 0 8px; }
+      body #breadcrumbs li.not-last:after {
+        content: "»";
+        float: right; }
+
+  body #header {
+    border-bottom: 2px solid #f6f6f6;
+    height: 45px;
+    padding: 0 20px 20px 20px ;
+  }
+
+  body #header h1 { font-size: 25px; }
+
+  body #footer {
+    border-top: 8px solid #f6f6f6;}
+
+  body .clear {
+    clear: both;
+    border-width: 0;
+    margin: 0;
+    visibility: hidden; }
+
+body.listing table#pages tr, body.listing table#subdirs tr, body.listing table#files tr {
+  border-bottom: 1px solid #777;
+  border-top: 1px solid #777; }
+body.listing table#pages td, body.listing table#subdirs td, body.listing table#files td {
+  border: none; }
+  body.listing table#pages td.size, body.listing table#subdirs td.size, body.listing table#files td.size {
+    background-color: #f6f6f6; }
+  body.listing table#pages td.name, body.listing table#subdirs td.name, body.listing table#files td.name {
+    padding: 0; }
+    body.listing table#pages td.name a, body.listing table#subdirs td.name a, body.listing table#files td.name a {
+      display: block;
+      margin: 0;
+      padding: 4px 8px; }
+
+blockquote {
+  background-color: #f6f6f6;
+  padding: 13px;
+  padding-bottom: 1px; }
+
+hr {
+  border-style: solid;
+  border: none;
+  border-top: 1px solid #777;
+  margin: 28px 0; }
+
+dl {
+  margin-left: 0; }
+  dl dd {
+    margin-bottom: 13px;
+    margin-left: 13px; }
+
+ul {
+  margin-top: 0; }
+  ul li {
+    list-style: square outside; }
+  ul ul {
+    margin-bottom: 0; }
+
+pre {
+  border-left: 1px solid gray;
+  margin-bottom: 13px;
+  margin-left: 30px;
+  padding-left: 12px; }
+
+.codehilite {
+  border-left: 1px solid gray;
+  margin-bottom: 13px;
+  margin-left: 30px;
+  padding-left: 12px; }
+  .codehilite pre {
+    border: none;
+    margin: 0;
+    padding: 0; }
+
+.codehilitetable {
+  margin-left: 0;
+  padding-left: 0; }
+  .codehilitetable tr td {
+    border: none;
+    padding: 3px 5px 0 5px; }
+    .codehilitetable tr td.linenos {
+      background-color: #f6f6f6;
+      border-right: 1px solid gray;
+      margin: 0;
+      padding-right: 6px;
+      text-align: right;
+      width: 19px; }
+      .codehilitetable tr td.linenos .linenodiv pre {
+        border: none;
+        margin: 0;
+        padding: 0; }
+    .codehilitetable tr td.code {
+      margin: 0;
+      padding-left: 12px; }
+      .codehilitetable tr td.code .codehilite {
+        border: none;
+        margin: 0;
+        padding: 0; }
+
+body {
+  font-family: "Ubuntu", 'Helvetica Neue', Helvetica, Arial, Geneva, sans-serif;
+  line-height: 21px; }
+  body #breadcrumbs li {
+    color: #aaa;
+    font-size: 13px;
+    font-weight: bold;
+    line-height: 28px; }
+    body #breadcrumbs li a {
+      text-decoration: none; }
+    body #breadcrumbs li .list-crumb {
+      font-weight: normal; }
+  body #footer {
+    color: #777;
+    font-size: 13px;
+    }
+  body.listing table#pages td.size, body.listing table#subdirs td.size {
+    font-family: "Ubuntu", Menlo, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', Courier, 'Courier 10 Pitch', 'Courier New', monospace;
+    text-align: right; }
+  body.listing table#subdirs td.name {
+    font-family: "Ubuntu", Courier, 'Courier 10 Pitch', 'Courier New', monospace; }
+
+h1, h2, h3, h4, h5, h6 {
+  line-height: 21px; }
+
+h1 {
+  font-size: 21px; }
+
+h2 {
+  font-size: 18px; }
+
+h3 {
+  font-size: 15px; }
+
+h4, h5, h6 {
+  font-size: 13px; }
+
+a {
+  color: #990000;
+  text-decoration: none; }
+  a:hover {
+    color: #4c0000; }
+  a[href^="http:"] {
+    text-decoration: underline; }
+
+dl dt {
+  font-weight: bold; }
+
+code {
+  font-family: Courier, 'Courier 10 Pitch', 'Courier New', monospace;
+  line-height: 18px; }
+
+pre {
+  font-family: Menlo, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', Courier, 'Courier 10 Pitch', 'Courier New', monospace;
+  font-size: 11px;
+  line-height: 18px; }
+
+#scrolltop { position: fixed; bottom: 5px; right: 10px; display: block; }

File static/media/img/thejeshgn-name.png

  • Ignore whitespace
Added
New image

File static/media/sass/_layout.sass

View file
  • Ignore whitespace
+html
+  :background-color #f6f6f6
+  :font-size 15px
+
+body
+  :background-color white
+  :margin 0 auto
+  :width 900px
+  
+  #breadcrumbs, #content, #footer
+    :background-color white
+    :clear both
+    :float left
+    :overflow hidden
+    :padding 0 20px
+    :width= 900px - (20px + 20px)
+  
+  #breadcrumbs
+    :border-bottom 2px solid #f6f6f6
+    :height 28px
+    :margin 0
+    :padding 20px
+    :width 900px
+    li
+      :float left
+      :list-style none
+      :margin 0
+      :padding 0
+      a
+        :display block
+        :float left
+        :padding 0 8px
+      &.last
+        :padding 0 8px
+      &.not-last:after
+        :content "»"
+        :float right
+  
+  #footer
+    :border-top 8px solid #f6f6f6
+    :padding-top 13px
+  
+  .clear
+    :clear both
+    :border-width 0
+    :margin 0
+    :visibility hidden
+
+
+body.listing
+  table#pages, table#subdirs, table#files
+    tr
+      :border-bottom 1px solid #777
+      :border-top 1px solid #777
+    td
+      :border none
+      &.size
+        :background-color #f6f6f6
+      &.name
+        :padding 0
+        a
+          :display block
+          :margin 0
+          :padding 4px 8px
+
+
+// Common elements
+
+blockquote
+  :background-color #f6f6f6
+  :padding 13px
+  :padding-bottom 1px
+
+hr
+  :border-style solid
+  :border none
+  :border-top 1px solid #777
+  :margin 28px 0
+
+
+// Lists
+
+dl
+  :margin-left 0
+  dd
+    :margin-bottom 13px
+    :margin-left 13px
+
+ul
+  :margin-top 0
+  li
+    :list-style square outside
+  ul
+    :margin-bottom 0
+
+
+// Code blocks
+
+=codeblock
+  :border-left 1px solid gray
+  :margin-bottom 13px
+  :margin-left 30px
+  :padding-left 12px
+
+pre
+  +codeblock
+
+.codehilite
+  +codeblock
+  pre
+    :border none
+    :margin 0
+    :padding 0
+
+.codehilitetable
+  :margin-left 0
+  :padding-left 0
+  tr td
+    :border none
+    :padding 3px 5px 0 5px
+    &.linenos
+      :background-color #f6f6f6
+      :border-right 1px solid gray
+      :margin 0
+      :padding-right 6px
+      :text-align right
+      :width= 30px - (5px + 6px)
+      .linenodiv pre
+        :border none
+        :margin 0
+        :padding 0
+    &.code
+      :margin 0
+      :padding-left 12px
+      .codehilite
+        :border none
+        :margin 0
+        :padding 0

File static/media/sass/_typography.sass

View file
  • Ignore whitespace
+!monospace_fonts_block = "Ubuntu", "Menlo", "'DejaVu Sans Mono'", "'Bitstream Vera Sans Mono'", "Courier", "'Courier 10 Pitch'", "'Courier New'", "monospace"
+!monospace_fonts_inline = "Ubuntu","Courier", "'Courier 10 Pitch'", "'Courier New'", "monospace"
+!sans_serif_fonts = "Ubuntu","'Helvetica Neue'", "Helvetica", "Arial", "Geneva", "sans-serif"
+
+body
+  :font-family= !sans_serif_fonts
+  :line-height 21px
+  
+  #breadcrumbs
+    li
+      :color #aaa
+      :font-size 13px
+      :font-weight bold
+      :line-height 28px
+      a
+        :text-decoration none
+      .list-crumb
+        :font-weight normal
+  
+  #footer
+    :color #777
+    :font-size 13px
+  
+  &.listing
+    table#pages, table#subdirs
+      td.size
+        :font-family= !monospace_fonts_block
+        :text-align right
+    table#subdirs
+      td.name
+        :font-family= !monospace_fonts_inline
+
+
+// Headers
+
+h1, h2, h3, h4, h5, h6
+  :line-height 21px
+
+h1
+  :font-size 21px
+
+h2
+  :font-size 18px
+
+h3
+  :font-size 15px
+
+h4, h5, h6
+  :font-size 13px
+
+
+// Links
+
+!link_color = #900
+
+a
+  :color= !link_color
+  :text-decoration none
+  &:hover
+    :color= !link_color * 0.5
+  &[href^="http:"]
+    :text-decoration underline
+
+
+// Lists
+
+dl
+  dt
+    :font-weight bold
+
+
+// Code
+
+code
+  :font-family= !monospace_fonts_inline
+  :line-height 18px
+
+pre
+  :font-family= !monospace_fonts_block
+  :font-size 11px
+  :line-height 18px

File static/media/sass/style.sass

View file
  • Ignore whitespace
+@import _layout.sass
+@import _typography.sass

File templates/404.html

View file
  • Ignore whitespace
+{% extends 'markdoc-default/404.html' %}

File templates/base.html

View file
  • Ignore whitespace
+{% extends 'markdoc-default/base.html' %}

File templates/document.html

View file
  • Ignore whitespace
+{% extends 'markdoc-default/document.html' %}

File templates/listing.html

View file
  • Ignore whitespace
+{% extends 'markdoc-default/listing.html' %}

File templates/macros/crumbs

View file
  • Ignore whitespace
+{% macro crumbs(breadcrumbs) %}
+  {% if breadcrumbs %}
+    <ol id="breadcrumbs">
+      {% for name, href in breadcrumbs %}
+        <li class="crumb-{{ loop.index0 }} {% if loop.last %}last{% else %}not-last{% endif %}">
+          {% if not href %}
+            {{ name|e }}
+          {% else %}
+            <a href="{{ make_relative(href)|e }}">{{ name|e }}</a>
+          {% endif %}
+        </li>
+      {% endfor %}
+    </ol> <!-- ol#breadcrumbs -->
+  {% endif %}
+{% endmacro %}

File templates/markdoc-default/404.html

View file
  • Ignore whitespace
+{% extends 'base.html' %}
+
+{% block title %}Not Found: {{ request.path_info|e }}{% endblock %}
+
+{% block content %}
+<h1>Not Found: <code>{{ request.path_info|e }}</code></h1>
+<p>
+  We couldn’t find what you were looking for.
+  {% if not is_index %}You could try going <a href="/">home</a>.{% endif %}
+</p>
+{% endblock %}

File templates/markdoc-default/base.html

View file
  • Ignore whitespace
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN"
+    "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+      {% block xmlns -%}
+      xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+      xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
+      xmlns:dc="http://purl.org/dc/elements/1.1/"
+      xmlns:foaf="http://xmlns.com/foaf/0.1/"
+      {%- endblock %}>
+  
+  {% import "macros/html" as html -%}
+  {% import "macros/crumbs" as breadcrumbs with context -%}
+  
+  <head>
+    {% block head %}
+    
+      {% block meta %}
+        <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />
+      {% endblock %}
+      
+      <title>
+        {% block title_prefix -%}
+          {% if 'wiki-name' in config %}{{ config['wiki-name']|e }} » {% endif %}
+        {%- endblock %}
+        {% block title -%}
+          {{ title }}
+        {%- endblock %}
+      </title>
+      
+      {% block css %}
+        {{ html.cssimport(make_relative("http://fonts.googleapis.com/css?family=Ubuntu")) }}
+        {{ html.cssimport(make_relative("/media/css/style.css")) }}
+        {{ html.cssimport(make_relative("/media/css/pygments.css")) }}
+      {% endblock %}
+      
+      {% block js %}{% endblock %}
+      
+      {% block analytics %}
+        {% if 'google-analytics' in config %}
+          <!-- Google Analytics -->
+          <script type="text/javascript">
+            var _gaq = _gaq || [];
+            _gaq.push(['_setAccount', '{{ config['google-analytics'] }}']);
+            _gaq.push(['_trackPageview']);
+            (function() {
+              var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
+              ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
+              (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(ga);
+            })();
+          </script>
+        {% endif %}
+      {% endblock analytics %}
+    {% endblock head %}
+  </head>
+  
+  <body {% block body_attrs %}{% endblock %}>
+    {% block body %}
+      <div id="header">
+          <h1>{% if 'wiki-name' in config %}{{ config['wiki-name']|e }}{% endif %}</h1>
+          <hr class="clear" />
+      </div>      
+      {% block body_header %}
+        {% block crumbs %}
+          {{ breadcrumbs.crumbs(crumbs) }}
+        {% endblock crumbs %}
+      {% endblock body_header %}
+      
+      <div id="content">
+        {% block content_header %}
+        {% endblock content_header %}
+        
+        {% block content %}
+        {% endblock content %}
+        
+        {% block content_footer %}
+        {% endblock content_footer %}
+        
+        <hr class="clear" />
+      </div> <!-- div#content -->
+      
+      {% block body_footer %}
+      <div id="footer">
+        <p>
+          <a href="http://thejeshgn.com/"><img width="100px" src="/media/img/thejeshgn-name.png"/></a>
+        </p>
+
+      </div>
+      {% endblock body_footer %}
+    
+    {% endblock body %}
+    
+    <hr class="clear" />
+    <a href="#" id="scrolltop">Scroll To Top</a>
+  </body>
+</html>

File templates/markdoc-default/document.html

View file
  • Ignore whitespace
+{% extends 'base.html' %}
+
+{% block content %}{{ content }}{% endblock %}

File templates/markdoc-default/listing.html

View file
  • Ignore whitespace
+{% extends 'base.html' %}
+
+{% block title %}ls /{{ directory|e }}{% endblock %}
+
+{% block body_attrs %}class="listing"{% endblock %}
+
+{% block content %}
+  <h1><code>ls /{{ directory|e }}</code></h1>
+
+  {% if sub_directories %}
+  <h2>Directories</h2>
+
+  <table id="subdirs">
+    {% for subdir in sub_directories %}
+      <tr>
+        <td class="name">
+          <a class="dirlink" href="{{ make_relative(subdir.href)|e }}">
+            {{ subdir.basename|e }}/
+          </a>
+        </td>
+      </tr>
+    {% endfor %}
+  </table>
+  {% endif %}
+
+  {% if pages %}
+  <h2>Pages</h2>
+
+  <table id="pages">
+    {% for page in pages %}
+      <tr>
+        <td class="size">{{ page.humansize }}</td>
+        <td class="name">
+          <a href="{{ make_relative(page.href)|e }}" title="{{ page.title|e }}">
+            {{ page.title|e }}
+          </a>
+        </td>
+      </tr>
+    {% endfor %}
+  </table>
+  {% endif %}
+
+  {% if files %}
+  <h2>Files</h2>
+
+  <table id="files">
+    {% for file in files %}
+      <tr>
+        <td class="size">{{ file.humansize }}</td>
+        <td class="name">
+          <a href="{{ make_relative(file.href)|e }}">
+            <code>{{ file.basename|e }}</code>
+          </a>
+        </td>
+      </tr>
+    {% endfor %}
+  </table>
+  {% endif %}
+{% endblock %}