Use new dbab to set proxy automatically

UPDATE: The latest version of this article is available here.

In the past, we’ve covered

Now let’s continue on that trend to auto proxy setting. I.e., DNSMasq gets DHCP and DNS together, and the dbab brings them both and ad blocking together, and now let’s move a step further to bring squid and auto proxy setting into the picture, and into the harmony.

Ever want to remove Ads and speed up your (iphone/ipad) mobile device browsing without even installing any apps to them?

Sounds too good to be true? Well, unless you install to your server the following. Let’s make the magic happen.

Continue reading

WordPress Markdown test

An exhibit of Markdown

[tags markdown]

This note demonstrates some of what wordpress Markdown is capable of doing.

[more]

References

http://www.markitdown.net/markdown

http://en.support.wordpress.com/markdown-quick-reference/

https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet

https://guides.github.com/features/mastering-markdown/

Markdown quick reference for wordpress

http://en.support.wordpress.com/markdown-quick-reference/

Special shortcodes can be embedded in email to configure the published post, e.g., [more], [delay +1 hour] etc.

Emphasize emphasize
Strong Strong

A link.

Some text with a link and another link.

Linked Images:
alt text

Footnotes: I have more 1 to say up here.

Lists

  1. Item
  2. Item
    • Mixed
    • Mixed
  3. Item
  • Unordered list can use asterisks
    • Or minuses
    • Or pluses

Preformatted

Begin each line with
two spaces or more to
make text look
e x a c t l y
like you type i
t.

Code block

#button {
    border: none;
}

Definition Lists

WordPress
A semantic personal publishing platform
Markdown
Text-to-HTML conversion tool

Abbreviations

Markdown converts text to HTML.

Definitions can be anywhere in the document

More Markdown Examples from Pandoc-Markdown

http://www.unexpected-vortices.com/sw/rippledoc/quick-markdown-example.html

Use 3 dashes for — an em-dash. Use 2 dashes for ranges (ex., “it’s all
in chapters 12–14”). Three dots … will be converted to an ellipsis.
Unicode is supported.

Inline math equations go in like so: $\omega = d\phi / dt$. Display
math should get its own line and be put in in double-dollarsigns:

$$I = \int \rho R^{2} dV$$

And note that you can backslash-escape any punctuation characters
which you wish to be displayed literally, ex.: `foo`, *bar*, etc.

Block quotes are
written like so.

They can span multiple paragraphs,
if you like.

Here’s a “line block”:

| Line one
| Line too
| Line tree

Tables can look like this:

size material color


9 leather brown
10 hemp canvas natural
11 glass transparent

Table: Shoes, their sizes, and what they’re made of

(The above is the caption for the table.)

[nextpage]

Emphasis

Emphasis, aka italics, with asterisks or underscores.

Strong emphasis, aka bold, with asterisks or underscores.

Combined emphasis with asterisks and underscores.

Strikethrough uses two tildes. ~~Scratch this~~.

Lists

  1. First ordered list item
  2. Another item
    • Unordered sub-list.
  3. Actual numbers don’t matter, just that it’s a number
    1. Ordered sub-list
  4. And another item.

    You can have properly indented paragraphs within list items. Notice the blank line above, and the leading spaces (at least one, but we’ll use three here to also align the raw Markdown).

    To have a line break without a paragraph, you will need to use two trailing spaces.
    Note that this line is separate, but within the same paragraph.
    (This is contrary to the typical GFM line break behaviour, where trailing spaces are not required.)

  • Unordered list can use asterisks
  • Or minuses
  • Or pluses

URLs

URLs can be made in a handful of ways:

  • http://github.com – automatic!
  • A named link to MarkItDown. The easiest way to do these is to select what you want to make a link and hit Ctrl+L.
  • Another named link to MarkItDown
  • Sometimes you just want a URL like .

Some text to show that the reference links can follow later.

internal links / named anchors

For Markdown’s support for internal links / named anchors,

http://stackoverflow.com/questions/2822089/how-to-link-to-part-of-the-same-document-in-markdown/6494918#6494918

obvious solution is to place your own anchor point in the page wherever you like, thus:

before the line you want to ‘link’ to. Don’t forget the quotation marks around it. Then a markdown link like:

link text
anywhere in the document takes you there.

It might be OK to put the anchor in the heading line you wish to link.

Images

Here’s our logo (hover to see the title text):

Inline-style:
alt text

Reference-style:
alt text

Code and Syntax Highlighting

Code blocks are part of the Markdown spec, but syntax highlighting isn’t. However, many renderers — like Github’s and Markdown Here — support syntax highlighting.

Inline code has back-ticks around it.

code blocks

Code blocks are very useful for developers and other people who look at code or other things that are written in plain text. As you can see, it uses a fixed-width font.

Blocks of code are either fenced by lines with three back-ticks “`, or are indented with four spaces. I recommend only using the fenced code blocks — they’re easier and only they support syntax highlighting.

var s = "JavaScript syntax highlighting";
alert(s);
s = "Python syntax highlighting"
print s
No language indicated, so no syntax highlighting. 
But let's throw in a <b>tag</b>.

Blockquotes

Blockquotes are very handy in email to emulate reply text.
This line is part of the same quote.

Quote break.

This is a very long line that will still be quoted properly when it wraps. Oh boy let’s keep writing to make sure this is long enough to actually wrap for everyone. Oh, you can put Markdown into a blockquote.

Inline HTML

You can also use raw HTML in your Markdown, and it’ll mostly work pretty well.

Definition list
Is something people use sometimes.
Markdown in HTML
Does *not* work **very** well. Use HTML tags.

Headings – H1, can also contain formatting

There are six levels of headings. They correspond with the six levels of HTML headings.

H2

H3

H4

H5
H6

[end]

everything after this shortcode is ignored (i.e. signatures). Make sure it’s on its own line with a blank line above it.


  1. To say down here. 

Markdown test for wordpress

An exhibit of Markdown

This note demonstrates some of what wordpress Markdown is capable of doing.

[more]

References

http://www.markitdown.net/markdown

http://en.support.wordpress.com/markdown-quick-reference/

https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet

https://guides.github.com/features/mastering-markdown/

Markdown quick reference for wordpress

http://en.support.wordpress.com/markdown-quick-reference/

Special shortcodes can be embedded in email to configure the published post, e.g., [more], [delay +1 hour] etc.

Emphasize emphasize
Strong Strong

A link.

Some text with a link and another link.

Linked Images:
alt text

Footnotes: I have more1 to say up here.

Lists

  1. Item
  2. Item
    • Mixed 1
    • Mixed 1
      • Mixed 2
      • Mixed 2
    • Or minuses
      • Or pluses
  3. Item

Break it apart.

  • Unordered list nicely aligned but not properly rendered
    • Or minuses
    • Or minuses
    • Or pluses
    • Or pluses

Now,

  • Unordered list properly rendered
    • Mixed 1
    • Mixed 1
      • Mixed 2
      • Mixed 2
    • Or minuses
      • Or pluses
  • Back to level one

Preformatted

Begin each line with
two spaces or more to
make text look
e x a c t l y
like you type i
t.

Code block

#button {
    border: none;
}

http://en.support.wordpress.com/code/posting-source-code/

The following languages are supported:

  • actionscript3
  • bash
  • clojure
  • coldfusion
  • cpp
  • csharp
  • css
  • delphi
  • erlang
  • fsharp
  • diff
  • groovy
  • html
  • javascript
  • java
  • javafx
  • matlab (keywords only)
  • objc
  • perl
  • php
  • text
  • powershell
  • python
  • r
  • ruby
  • scala
  • sql
  • vb
  • xml

Definition Lists

WordPress
A semantic personal publishing platform
Markdown
Text-to-HTML conversion tool

Abbreviations

Markdown converts text to HTML.

Definitions can be anywhere in the document

More Markdown Examples from Pandoc-Markdown

http://www.unexpected-vortices.com/sw/rippledoc/quick-markdown-example.html

Use 3 dashes for — an em-dash. Use 2 dashes for ranges (ex., “it’s all
in chapters 12–14”). Three dots … will be converted to an ellipsis.
Unicode is supported.

Inline math equations go in like so: $\omega = d\phi / dt$. Display
math should get its own line and be put in in double-dollarsigns:

$$I = \int \rho R^{2} dV$$

And note that you can backslash-escape any punctuation characters
which you wish to be displayed literally, ex.: `foo`, *bar*, etc.

Block quotes are
written like so.

They can span multiple paragraphs,
if you like.

Here’s a “line block”:

| Line one
| Line too
| Line tree

Tables can look like this:

size material color


9 leather brown
10 hemp canvas natural
11 glass transparent

Table: Shoes, their sizes, and what they’re made of

(The above is the caption for the table.) Pandoc also supports
multi-line tables:


keyword text


red Sunsets, apples, and
other red or reddish
things.

green Leaves, grass, frogs
and other things it’s
not easy being.


[nextpage]

Emphasis

Emphasis, aka italics, with asterisks or underscores.

Strong emphasis, aka bold, with asterisks or underscores.

Combined emphasis with asterisks and underscores.

Strikethrough uses two tildes. ~~Scratch this.~~

Lists

  1. First ordered list item
  2. Another item
    • Unordered sub-list.
  3. Actual numbers don’t matter, just that it’s a number
    1. Ordered sub-list
  4. And another item.

    You can have properly indented paragraphs within list items. Notice the blank line above, and the leading spaces (at least one, but we’ll use three here to also align the raw Markdown).

    To have a line break without a paragraph, you will need to use two trailing spaces.
    Note that this line is separate, but within the same paragraph.
    (This is contrary to the typical GFM line break behaviour, where trailing spaces are not required.)

  • Unordered list can use asterisks
  • Or minuses
  • Or pluses

URLs

URLs can be made in a handful of ways:

Some text to show that the reference links can follow later.

internal links / named anchors

For Markdown’s support for internal links / named anchors,

http://stackoverflow.com/questions/2822089/how-to-link-to-part-of-the-same-document-in-markdown/6494918#6494918

obvious solution is to place your own anchor point in the page wherever you like, thus:


before the line you want to ‘link’ to. Don’t forget the quotation marks around it. Then a markdown link like:

link text
anywhere in the document takes you there.

It might be OK to put the anchor in the heading line you wish to link.

Images

Here’s our logo (hover to see the title text):

Inline-style:
alt text

Linked Images:
alt text

Reference-style:
alt text

Code and Syntax Highlighting

Code blocks are part of the Markdown spec, but syntax highlighting isn’t. However, many renderers — like Github’s and Markdown Here — support syntax highlighting.

Inline code has back-ticks around it.

code blocks

Code blocks are very useful for developers and other people who look at code or other things that are written in plain text. As you can see, it uses a fixed-width font.

Blocks of code are either fenced by lines with three back-ticks “`, or are indented with four spaces. I recommend only using the fenced code blocks — they’re easier and only they support syntax highlighting.

var s = "JavaScript syntax highlighting";
alert(s);
s = "Python syntax highlighting"
print s
No language indicated, so no syntax highlighting. 
But let's throw in a <b>tag</b>.

Blockquotes

Blockquotes are very handy in email to emulate reply text.
This line is part of the same quote.

Quote break.

This is a very long line that will still be quoted properly when it wraps. Oh boy let’s keep writing to make sure this is long enough to actually wrap for everyone. Oh, you can put Markdown into a blockquote.

Inline HTML

You can also use raw HTML in your Markdown, and it’ll mostly work pretty well.

Definition list
Is something people use sometimes.
Markdown in HTML
Does *not* work **very** well. Use HTML tags.

Headings – H1, can also contain formatting

There are six levels of headings. They correspond with the six levels of HTML headings.

H2

H3

H4

H5
H6

[end]

everything after this shortcode is ignored (i.e. signatures). Make sure it’s on its own line with a blank line above it.


  1. To say down here. 

AsciiDoc Markup Syntax Summary

asciidoc --help syntax | sed 's/^  //' | tee MarkupTest.adoc

A summary of the most commonly used markup. For a complete reference see the AsciiDoc User Guide.


Text formatting

bold text (boldface font)
emphasized text (normally italics)
emphasized text
monospaced text (proportional font)
monospaced text (inline literal passthrough)


Document links

(define link target)
caption (link to target id)
caption (link to external HTML file)


URLs

Use normal URL and email addess syntax or:

caption (link to web page)
caption (link to mail recipient)


Images

image:filename     (inline image)
image::filename    (block image)

Document header

The Document Title
==================
author <email>
revision, date

author, email, revision and date are optional.


Section title underlines

Underlined:

Level 0                     (document title)
=======
Level 1
-------
Level 2
~~~~~~~
Level 3
^^^^^^^
Level 4                     (bottom level)
+++++++

Single line:

= Level 0 =                 (document title)
== Level 1 ==
=== Level 2 ===
==== Level 3 ====
===== Level 4 =====         (bottom level)

Level 1

Level 2

Level 3

Level 4

Paragraphs

A normal paragraph. (styles: literal,verse,quote,listing, NOTE,TIP,WARNING,IMPORTANT,CAUTION)

An indented literal
paragraph.

Delimited blocks

Delimiters must begin at left margin.

listing block
listing block

(styles: source,music,graphviz)

literal block
literal block

(styles: listing,verse)

sidebar block sidebar block

quote block quote block

cite
— author

(styles: quote,verse)

example block example block

(styles: NOTE,TIP,WARNING,IMPORTANT,CAUTION)

passthrough block passthrough block

(styles: pass,asciimath,latexmath)

[style]
--
open block
--
(styles: abstract,partintro)

More block elements

[attributes list]
.Block title
// Comment line
include::filename[]

Tables

Table 1. An example table
Column 1 Column 2
6
Three items
1
Item 1
2
Item 2
3
Item 3

Common attributes:

grid:    none,cols,rows,all
frame:   topbot,none,sides,all
options: header,footer
format:  psv,csv,dsv
valign:  top,bottom,middle
width:   1%..100%
cols:    colspec[,colspec,...]
colspec:    [multiplier*][align][width][style]
multiplier: 1...
width:      1... or 1%...100%
align:      [horiz][.vert]
             horiz: < (left), ^ (center), > (right)
             vert:  < (top),  ^ (middle), > (bottom)
style:      d[efault], e[mphasis], m[onospaced], a[sciidoc],
            s[trong], l[iteral], v[erse], h[eader]
cell:       [cellspec]|data
cellspec:   [span*|+][align][style]
span:       [colspan][.rowspan]
             colspan: 1...
             rowspan: 1...

Bulleted lists

  • item text
    • item text
      • item text
        • item text
          • item text
            • item text

(styles: callout,bibliography)


Numbered lists

  1. arabic (decimal) numbering
    1. loweralpha numbering
      1. upperalpha numbering
        1. lowerroman numbering
          1. upperroman numbering
            1. arabic (decimal) numbering
              1. loweralpha numbering
                1. lowerroman numbering
                  1. upperalpha numbering
                    1. upperroman numbering

(styles: arabic,loweralpha,upperalpha,lowerroman,upperroman)


Labeled lists

label
item text

label
item text

label
item text

label
item text

(styles: horizontal,vertical,glossary,qanda,bibliograpy)


More inline elements

[footnote text]
(document footnote)