doublesing 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: ad13d9d3deeaf901709a596512ff350e6e97a0ec
4
+ data.tar.gz: 5303605eead6d34bdabc2f3a2e47fd0b032ea7cb
5
+ SHA512:
6
+ metadata.gz: ed9c583d855e0fae38fff938c948b1e898caeaa3391f2a2b3f486cf72bd7832c9c8e30d817e61f47d9be960053fb6b19e00efbeab4c5d8b2dc596fcdea8d7ee0
7
+ data.tar.gz: 1cb9ba4adcf2f8c423108105c6011b8c97b8a0e95523cfa0fe7606bfb872d0e6fea25fd60bab8bf480b92181fef8aa6809ce54dc2621a7b70f4afb36fee81462
data/.gitignore ADDED
@@ -0,0 +1,11 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
10
+ *.pdf
11
+
data/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --format documentation
2
+ --color
data/.travis.yml ADDED
@@ -0,0 +1,9 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.1.1
4
+ - 2.2.0
5
+
6
+ addons:
7
+ code_climate:
8
+ repo_token:
9
+ secure: "hqU+bvvtga7nqyvxgTV1G0T8IwGeDa4AnM2FwhIXMRbmNrasrG459NkEUZFraKnsAtAb46MCRZTKzAqi8EgdsjwIyH1uY8f3Dmujja7S6v7oc5sDzku7zDLfmSRkTlCiMP3j1JZiHJ84rVPvuTOXL8PXSb1++cB3q6zFYhPq4sM="
@@ -0,0 +1,7 @@
1
+ # Contributor Code of Conduct
2
+ # Developer Code of Conduct
3
+
4
+ 1. Do not be a jerk for no reason.
5
+ 2. Be nice to new people
6
+ 3. If you're going to yell at somebody, make sure you know them well enough beforehand. Ideally don't even yell at all.
7
+ 4. Don't bring up somebody's personal background, it's almost certainly irrelevant.
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in doublesing.gemspec
4
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2015 Anthony Super
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,106 @@
1
+ ![Doublesing Logo](https://cdn.rawgit.com/AnthonySuper/Doublesing/master/assets/logo-opt.svg)
2
+
3
+ [![Build Status](https://travis-ci.org/AnthonySuper/Doublesing.svg)](https://travis-ci.org/AnthonySuper/Doublesing)
4
+ [![Test Coverage](https://codeclimate.com/github/AnthonySuper/Doublesing/badges/coverage.svg)](https://codeclimate.com/github/AnthonySuper/Doublesing)
5
+ [![Code Climate](https://codeclimate.com/github/AnthonySuper/Doublesing/badges/gpa.svg)](https://codeclimate.com/github/AnthonySuper/Doublesing)
6
+
7
+ Doublesing is a wiki markup language based on TeX.
8
+ It's very simple and extremely flexible.
9
+ You can register your own tags (including over-riding builtin ones) to suit your needs, effectively allowing a custom dialect to be built with just ruby objects.
10
+
11
+
12
+ ## Installation
13
+
14
+ Add this line to your application's Gemfile:
15
+
16
+ ```ruby
17
+ gem 'doublesing'
18
+ ```
19
+
20
+ And then execute:
21
+
22
+ $ bundle
23
+
24
+ Or install it yourself as:
25
+
26
+ $ gem install doublesing
27
+
28
+ ## Usage
29
+
30
+ Doublesing is a TeX-like language designed to be used for online markup.
31
+ It takes the relatively simple form of:
32
+ ```
33
+ \BLOCK_ID{ARGUMENT}{ARGUMENT}{ARGUMENT}
34
+ ```
35
+ Here, maybe a use case will help:
36
+
37
+ ```
38
+ \bold{This text becomes bold!}
39
+ ```
40
+ Becomes:
41
+ ```
42
+ <b>This text becomes bold!</b>
43
+ ```
44
+ You can have blocks that take multiple arguments:
45
+ ```
46
+ \header{1}{This is a header}
47
+ ```
48
+
49
+ ```
50
+ <h1>This is a header</h1>
51
+ ```
52
+
53
+ Parsing this is easy:
54
+ ```
55
+ Doublesing.setup! # Must call once, probably in an initializer
56
+ Doublesing.parse(str) #=> Processed HTML
57
+ ```
58
+
59
+ Where it gets interesting is the fact that you can register your own block types.
60
+ A common use case of this might be to add site-specific functionality.
61
+ Let's say you're making a website about pictures of famous dogs.
62
+ You probably want your user to be able to reference dogs pretty quickly.
63
+ Well, with Doublesing, you can do something like:
64
+
65
+ ```ruby
66
+ class DogFinder
67
+ def initialize(args)
68
+ @dog_name = args.first
69
+ @body = args[1]
70
+ end
71
+
72
+ def find_dog
73
+ dog = Dog.where(name: @dog_name).pluck(:id).first
74
+ "/dogs/#{dog.id}"
75
+ end
76
+
77
+ def to_s
78
+ "<a href=\"#{find_dog}\">#{@body.to_s}</a>"
79
+ end
80
+ end
81
+ ```
82
+ Then, register it:
83
+
84
+ ```ruby
85
+ Doublesing.register("dog", DogFinder)
86
+ ```
87
+
88
+ Now, assuming you're using Doublesing to parse comments, a user can say:
89
+ ```
90
+ \dog{Rowlf}{My favorite musical dog!}
91
+ ```
92
+
93
+ To easily get a link to the page on the piano player of the Muppets.
94
+ Pretty neat, huh?
95
+
96
+ Run `rake specification` to generate a .pdf with the full specification of built-in blocks.
97
+
98
+ There aren't that many right now, but you're free to submit a pull request with one!
99
+ Note: You gotta have PDFLatex installed for that to work.
100
+ ## Contributing
101
+
102
+ 1. Fork it ( https://github.com/AnthonySuper/Doublesing/fork )
103
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
104
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
105
+ 4. Push to the branch (`git push origin my-new-feature`)
106
+ 5. Create a new Pull Request
data/Rakefile ADDED
@@ -0,0 +1,12 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+
4
+ RSpec::Core::RakeTask.new(:spec)
5
+
6
+ task :default => :spec
7
+
8
+ task :specification do
9
+ 5.times{`pdflatex ./tex/spec.tex`}
10
+ `rm ./spec.log`
11
+ `rm ./spec.aux`
12
+ end
@@ -0,0 +1,31 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
+ <!-- Created with Inkscape (http://www.inkscape.org/) -->
3
+ <svg id="svg2" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://www.w3.org/2000/svg" height="382.2" width="321.13" version="1.1" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/">
4
+ <metadata id="metadata8">
5
+ <rdf:RDF>
6
+ <cc:Work rdf:about="">
7
+ <dc:format>image/svg+xml</dc:format>
8
+ <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
9
+ <dc:title/>
10
+ </cc:Work>
11
+ </rdf:RDF>
12
+ </metadata>
13
+ <path id="path2987" stroke-linejoin="miter" d="m46.517,259.69s23.891,26.701,31.386,38.413c7.4952,11.711,13.117,32.323,26.701,31.854,13.585-0.46845,44.034-1.4054,44.034-1.4054s45.908-35.602,52.466-43.565c6.5582-7.9636,21.548-14.99,31.854-58.087,10.31-43.09,7.03-200.95-26.69-200.02-33.73,0.937-154.59,7.963-166.3,23.422-11.711,15.459-20.143,113.84-20.143,113.84l2.8107,3.2791s6.0898,13.585,4.216,21.08c-1.8738,7.4952-1.4054,32.323-1.4054,32.323s19.675,24.828,21.08,38.881z" stroke="#827372" stroke-linecap="butt" stroke-width="2.52960968px" fill="#776968"/>
14
+ <path id="path3769" fill-opacity="0" d="m297.14,106.98s-29.044-55.277-53.871-74.483c-24.828-19.206-58.556-30.917-91.347-30.449-32.791,0.46844-61.835,0-80.573,15.459s-38.413,9.8374-55.277,40.286c-16.867,30.446-13.119,111.02-13.119,111.02s14.99,69.798,22.954,71.672c0,0-0.46846-13.117-0.46846-36.07,0-22.954-7.9636-50.124,4.216-64.177s28.575-46.845,37.944-53.403c9.3689-6.5582,27.638-24.359,45.439-32.791s29.981-17.333,34.197-17.801c4.216-0.46845,17.332-3.7476,17.332-3.7476s-1.4053,7.0267-6.0898,10.306c-4.6844,3.2791-39.349,53.403-41.692,65.114,0,0,34.665-49.655,40.755-49.655,0,0,5.1529,1.4053-0.46843,9.3689-5.6214,7.9636-22.017,35.602-22.954,47.313,0,0-1.4053,11.711,0.93689,9.3689,0,0,34.197-43.097,37.476-49.655,3.2791-6.5582-17.332,51.529-17.332,51.529l20.612-31.854,1.8738,36.07v15.459s5.6214,7.4951,10.774-2.3422c5.1529-9.8374,7.4951-32.791,7.4951-32.791s2.8107,33.26,1.4053,37.007c-1.4053,3.7476,0.46846,31.854,4.216,33.26,3.7476,1.4054,8.9005-3.2791,14.522-3.7476,5.6214-0.46846,40.286,48.25,40.286,57.15,0,8.9005-11.243,14.522-9.8374,26.701,1.4053,12.18,3.2791,29.512,3.7476,31.386,0.46846,1.8738,0,18.738,3.7476,22.017,3.7476,3.2791,24.828,29.512,29.512-20.612,4.6845-50.124,2.8107-89.942,2.8107-89.942z" stroke-opacity="0"/>
15
+ <path id="path3791" stroke-linejoin="miter" d="m221.72,181.46s-16.864,19.675-20.143,25.765c-3.2791,6.0898-5.1529-18.269-5.1529-18.269s0-21.549,0.46846-23.891c0.46843-2.3422-2.3422-52.466-2.3422-52.466l-16.864,38.413,1.8738-58.087-24.359,42.16,15.927-55.745-37.007,46.845s16.396-51.529,21.549-57.619c0,0-6.0898-8.9005-37.007,41.223,0,0-6.0898,6.0898-4.6844,3.2791s36.539-65.114,36.539-65.114l3.2791-10.774s-69.33,21.08-89.942,52.934-38.413,66.051-38.413,66.051-2.3422,14.522-0.46843,19.206c1.8738,4.6845-0.93689,49.187-0.93689,49.187s-14.99-15.459-17.801-22.954c-2.8107-7.4951-6.5582-54.808-4.216-59.493,2.3422-4.6845-1.4053-59.961,4.6845-63.24,0,0,19.206-55.277,61.835-61.835,42.629-6.5582,112.43-8.9005,125.54-2.3422,13.116,6.5582,66.988,32.791,75.42,52.466s-20.612,120.39-20.612,120.39z" stroke="#000" stroke-linecap="butt" stroke-width="2.52960968px" fill="#000"/>
16
+ <path id="path3787" stroke-linejoin="miter" d="m292.82,212.03s1.6562,28.156-26.168,44.055c-27.824,15.9-38.424,14.906-38.424,14.906" stroke="#8b8b8b" stroke-linecap="butt" stroke-miterlimit="4" stroke-dasharray="none" stroke-width="7.58882952" fill="none"/>
17
+ <path id="path3789" stroke-linejoin="miter" d="m229.56,269.67s-24.843,7.6186-30.143,6.2936c-5.2999-1.325-16.562,1.9874-15.568,5.9623,0.99374,3.9749,0.99374,8.9435,7.2873,8.281,6.2936-0.66248,18.218-4.6374,22.856-7.2873,4.6374-2.6499,8.281-3.9749,12.918-5.2999,4.6374-1.325,2.6499-7.9498,2.6499-7.9498z" stroke="#000" stroke-linecap="butt" stroke-width="2.52960968px" fill="#000"/>
18
+ <path id="path3775" stroke-linejoin="miter" d="m270.96,105.37s-1.6562-21.531-20.868-40.08c-19.212-18.55-50.017-50.68-83.142-51.674-33.124-0.99373-79.167-1.6562-85.792,1.9874h-7.9498s29.812-20.868,102.02-12.256c72.211,8.6123,121.23,99.372,121.9,103.02,5.6311,1.325,12.256,25.506,20.206,40.411,7.9498,14.906-4.9686,34.118-9.9372,49.355s-18.218,17.225-22.524,19.874c-4.3061,2.65-13.581-1.325-13.581,0.33126,0,1.6562-4.9686,5.2999-6.2936,6.2936-1.325,0.99373-12.587,9.2748-18.55,9.2748-5.9623,0-21.531-8.281-25.174-59.623-3.6436-51.342,21.199-66.248,24.843-66.911,3.6436-0.66248,24.843,0,24.843,0z" stroke="#242424" stroke-linecap="butt" stroke-width="2.52960968px" fill="#282828"/>
19
+ <g id="flowRoot3793" style="letter-spacing:0px;word-spacing:0px;" font-weight="normal" transform="matrix(2.5296098,0,0,2.5296098,-575.6928,-113.50023)" font-size="8px" font-style="normal" font-family="Sans" line-height="125%" fill="#000">
20
+ <path id="path3813" d="m241.6,183.98,0,7.9365,1.668,0c1.4082,0,2.4382-0.31901,3.0898-0.95703,0.65624-0.63802,0.98436-1.6452,0.98437-3.0215-0.00001-1.3672-0.32813-2.3675-0.98437-3.001-0.6517-0.63801-1.6816-0.95702-3.0898-0.95703h-1.668m-1.3809-1.1348,2.8369,0c1.9779,0.00001,3.4294,0.41245,4.3545,1.2373,0.92512,0.82032,1.3877,2.1055,1.3877,3.8555,0,1.7591-0.46485,3.0511-1.3945,3.876-0.92969,0.82487-2.3789,1.2373-4.3476,1.2373h-2.8369v-10.206"/>
21
+ <path id="path3815" d="m253.9,186.27c-0.67448,0.00001-1.2077,0.26433-1.5996,0.79297-0.39193,0.5241-0.58789,1.2442-0.58789,2.1602,0,0.91602,0.19368,1.6384,0.58105,2.167,0.39193,0.52409,0.92741,0.78614,1.6064,0.78613,0.66992,0.00001,1.2008-0.26432,1.5928-0.79296,0.39192-0.52865,0.58789-1.2487,0.58789-2.1602,0-0.9069-0.19597-1.6247-0.58789-2.1533-0.39193-0.5332-0.92285-0.7998-1.5928-0.79981m0-1.0664c1.0937,0.00001,1.9528,0.35547,2.5772,1.0664,0.62434,0.71095,0.93651,1.6953,0.93652,2.9531-0.00001,1.2533-0.31218,2.2376-0.93652,2.9531-0.62436,0.71094-1.4834,1.0664-2.5772,1.0664-1.0983,0-1.9596-0.35547-2.584-1.0664-0.6198-0.71549-0.92969-1.6999-0.92969-2.9531,0-1.2578,0.30989-2.2422,0.92969-2.9531,0.62434-0.71093,1.4857-1.0664,2.584-1.0664"/>
22
+ <path id="path3817" d="m259.37,190.03,0-4.6348,1.2578,0,0,4.5869c-0.00001,0.72461,0.14127,1.2692,0.42382,1.6338,0.28255,0.36003,0.70638,0.54004,1.2715,0.54004,0.67903,0,1.2145-0.21647,1.6064-0.64941,0.39648-0.43294,0.59472-1.0231,0.59473-1.7705v-4.3408h1.2578v7.6562h-1.2578v-1.1758c-0.30534,0.46484-0.66081,0.8112-1.0664,1.0391-0.40104,0.22331-0.86816,0.33496-1.4014,0.33496-0.87956,0-1.5472-0.27344-2.0029-0.82031-0.45573-0.54688-0.6836-1.3467-0.6836-2.3994m3.165-4.8193"/>
23
+ <path id="path3819" d="m273.88,189.23c-0.00001-0.92513-0.19141-1.6497-0.57422-2.1738-0.37826-0.52864-0.90007-0.79296-1.5654-0.79297-0.66537,0.00001-1.1895,0.26433-1.5723,0.79297-0.37826,0.5241-0.56739,1.2487-0.56739,2.1738,0,0.92513,0.18913,1.652,0.56739,2.1807,0.3828,0.52409,0.90689,0.78614,1.5723,0.78614,0.66536,0,1.1872-0.26205,1.5654-0.78614,0.38281-0.52864,0.57421-1.2555,0.57422-2.1807m-4.2793-2.6728c0.26432-0.45572,0.597-0.79296,0.99805-1.0117,0.40559-0.2233,0.88867-0.33495,1.4492-0.33496,0.92968,0.00001,1.6839,0.36915,2.2627,1.1074,0.58333,0.73829,0.875,1.709,0.875,2.9121s-0.29167,2.1738-0.875,2.9121c-0.57878,0.73828-1.333,1.1074-2.2627,1.1074-0.56055,0-1.0436-0.10937-1.4492-0.32812-0.40105-0.22331-0.73373-0.56283-0.99805-1.0186v1.1484h-1.2646v-10.637h1.2646v4.1426"/>
24
+ <path id="path3821" d="m277.27,182.41,1.2578,0,0,10.637-1.2578,0,0-10.637"/>
25
+ <path id="path3823" d="m287.7,188.91,0,0.61523-5.7832,0c0.0547,0.86589,0.31445,1.5267,0.7793,1.9824,0.4694,0.45117,1.1211,0.67676,1.9551,0.67675,0.48306,0.00001,0.95019-0.0592,1.4014-0.17773,0.45573-0.11849,0.9069-0.29622,1.3535-0.5332v1.1894c-0.45118,0.19141-0.91374,0.33724-1.3877,0.4375s-0.95475,0.15039-1.4424,0.15039c-1.2214,0-2.1898-0.35547-2.9053-1.0664-0.71094-0.71093-1.0664-1.6725-1.0664-2.8848,0-1.2532,0.33724-2.2467,1.0117-2.9805,0.67903-0.73827,1.5928-1.1074,2.7412-1.1074,1.0299,0.00001,1.8434,0.33269,2.4404,0.99804,0.60156,0.66082,0.90234,1.5609,0.90235,2.7002m-1.2578-0.36914c-0.009-0.68815-0.2028-1.2373-0.58105-1.6475-0.37371-0.41015-0.87045-0.61523-1.4902-0.61524-0.70182,0.00001-1.2646,0.19825-1.6885,0.59473-0.41928,0.39649-0.66081,0.95476-0.72461,1.6748l4.4844-0.007"/>
26
+ <path id="path3825" d="m294.65,185.62,0,1.1895c-0.35548-0.18229-0.72462-0.31901-1.1074-0.41016-0.38282-0.0911-0.77931-0.13671-1.1895-0.13672-0.62435,0.00001-1.0938,0.0957-1.4082,0.28711-0.3099,0.19141-0.46485,0.47852-0.46484,0.86133-0.00001,0.29167,0.11165,0.52181,0.33496,0.69043,0.2233,0.16407,0.67219,0.32129,1.3467,0.47168l0.43066,0.0957c0.89322,0.19141,1.5267,0.46257,1.9004,0.81348,0.37825,0.34636,0.56738,0.83171,0.56738,1.456,0,0.71094-0.28255,1.2738-0.84765,1.6885-0.56055,0.41471-1.333,0.62207-2.3174,0.62207-0.41015,0-0.83854-0.041-1.2852-0.12305-0.44206-0.0775-0.90918-0.19596-1.4014-0.35547v-1.2988c0.46484,0.24153,0.92285,0.42383,1.374,0.54687,0.45117,0.11849,0.89779,0.17774,1.3398,0.17774,0.59244,0,1.0482-0.10026,1.3672-0.30079,0.319-0.20507,0.47851-0.49218,0.47851-0.86132,0-0.3418-0.11621-0.60384-0.34863-0.78614-0.22787-0.18228-0.73145-0.35774-1.5107-0.52636l-0.4375-0.10254c-0.7793-0.16406-1.3421-0.41471-1.6885-0.75196-0.34635-0.34179-0.51953-0.80891-0.51953-1.4014,0-0.72005,0.25521-1.276,0.76562-1.668,0.51042-0.39192,1.235-0.58788,2.1738-0.58789,0.46484,0.00001,0.90234,0.0342,1.3125,0.10254,0.41015,0.0684,0.78841,0.1709,1.1348,0.30761"/>
27
+ <path id="path3827" d="m297.07,185.39,1.2578,0,0,7.6562-1.2578,0,0-7.6562m0-2.9805,1.2578,0,0,1.5928-1.2578,0,0-1.5928"/>
28
+ <path id="path3829" d="m307.31,188.43,0,4.6211-1.2578,0,0-4.5801c-0.00001-0.7246-0.14128-1.2669-0.42383-1.627-0.28256-0.36002-0.70639-0.54004-1.2715-0.54004-0.67904,0-1.2145,0.21648-1.6064,0.64941-0.39193,0.43295-0.58789,1.0231-0.58789,1.7705v4.3272h-1.2646v-7.6562h1.2646v1.1894c0.30078-0.46028,0.65397-0.80435,1.0596-1.0322,0.41015-0.22785,0.88183-0.34178,1.415-0.34179,0.87955,0.00001,1.5449,0.27344,1.9961,0.82031,0.45117,0.54232,0.67675,1.3421,0.67676,2.3994"/>
29
+ <path id="path3831" d="m314.87,189.13c-0.00001-0.91146-0.18914-1.6178-0.56739-2.1191-0.3737-0.5013-0.90007-0.75195-1.5791-0.75196-0.67448,0.00001-1.2008,0.25066-1.5791,0.75196-0.3737,0.5013-0.56055,1.2077-0.56055,2.1191,0,0.9069,0.18685,1.611,0.56055,2.1123,0.37825,0.5013,0.90462,0.75195,1.5791,0.75195,0.67903,0,1.2054-0.25065,1.5791-0.75195,0.37825-0.5013,0.56738-1.2054,0.56739-2.1123m1.2578,2.9668c-0.00001,1.3034-0.2894,2.2718-0.86816,2.9053-0.57879,0.63801-1.4652,0.95702-2.6592,0.95703-0.44207-0.00001-0.85906-0.0342-1.251-0.10254-0.39193-0.0638-0.77246-0.16407-1.1416-0.30078v-1.2236c0.36914,0.20052,0.73372,0.34864,1.0938,0.44434,0.36002,0.0957,0.72688,0.14355,1.1006,0.14356,0.82487-0.00001,1.4424-0.21648,1.8525-0.64942,0.41015-0.42839,0.61523-1.0778,0.61524-1.9482v-0.62207c-0.25977,0.45117-0.59246,0.78841-0.99805,1.0117-0.4056,0.2233-0.89095,0.33496-1.456,0.33496-0.93881,0-1.6953-0.35775-2.2695-1.0732-0.57422-0.7155-0.86132-1.6634-0.86132-2.8438,0-1.1849,0.2871-2.1351,0.86132-2.8506,0.57422-0.71549,1.3307-1.0732,2.2695-1.0732,0.5651,0.00001,1.0504,0.11166,1.456,0.33496,0.40559,0.22331,0.73828,0.56055,0.99805,1.0117v-1.1621h1.2578v6.706"/>
30
+ </g>
31
+ </svg>
data/assets/logo.svg ADDED
@@ -0,0 +1,146 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
+ <!-- Created with Inkscape (http://www.inkscape.org/) -->
3
+
4
+ <svg
5
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
6
+ xmlns:cc="http://creativecommons.org/ns#"
7
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
8
+ xmlns:svg="http://www.w3.org/2000/svg"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
11
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
12
+ id="svg2"
13
+ version="1.1"
14
+ inkscape:version="0.48.4 r9939"
15
+ width="321.12659"
16
+ height="382.203"
17
+ sodipodi:docname="logo.svg"
18
+ inkscape:export-filename="/home/anthony/Desktop/doubsing.png"
19
+ inkscape:export-xdpi="7089.8486"
20
+ inkscape:export-ydpi="7089.8486">
21
+ <metadata
22
+ id="metadata8">
23
+ <rdf:RDF>
24
+ <cc:Work
25
+ rdf:about="">
26
+ <dc:format>image/svg+xml</dc:format>
27
+ <dc:type
28
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
29
+ <dc:title />
30
+ </cc:Work>
31
+ </rdf:RDF>
32
+ </metadata>
33
+ <defs
34
+ id="defs6" />
35
+ <sodipodi:namedview
36
+ pagecolor="#ffffff"
37
+ bordercolor="#666666"
38
+ borderopacity="1"
39
+ objecttolerance="10"
40
+ gridtolerance="10"
41
+ guidetolerance="10"
42
+ inkscape:pageopacity="0"
43
+ inkscape:pageshadow="2"
44
+ inkscape:window-width="1215"
45
+ inkscape:window-height="776"
46
+ id="namedview4"
47
+ showgrid="false"
48
+ inkscape:zoom="0.675"
49
+ inkscape:cx="147.45395"
50
+ inkscape:cy="85.501527"
51
+ inkscape:window-x="65"
52
+ inkscape:window-y="24"
53
+ inkscape:window-maximized="1"
54
+ inkscape:current-layer="svg2"
55
+ fit-margin-top="0"
56
+ fit-margin-left="0"
57
+ fit-margin-right="0"
58
+ fit-margin-bottom="0" />
59
+ <path
60
+ style="fill:#776968;fill-opacity:1;stroke:#827372;stroke-width:2.52960968px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
61
+ d="m 46.516505,259.6907 c 0,0 23.890774,26.70145 31.385906,38.41261 7.495158,11.71115 13.116508,32.32277 26.701449,31.85433 13.58494,-0.46845 44.03396,-1.40535 44.03396,-1.40535 0,0 45.90771,-35.6019 52.46598,-43.56549 6.55824,-7.96359 21.5485,-14.99027 31.85433,-58.08734 C 243.26394,183.8024 239.98483,25.936011 206.25669,26.872901 172.52856,27.809791 51.669422,34.836491 39.958264,50.295211 28.247107,65.753941 19.815081,164.12765 19.815081,164.12765 l 2.810675,3.27913 c 0,0 6.089809,13.58494 4.216026,21.08007 -1.873784,7.49516 -1.40535,32.3228 -1.40535,32.3228 0,0 19.674749,24.82767 21.080073,38.88105 z"
62
+ id="path2987"
63
+ inkscape:connector-curvature="0" />
64
+ <path
65
+ style="fill:#000000;fill-opacity:0;stroke:#000000;stroke-width:2.52960968px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0"
66
+ d="m 297.13528,106.97721 c 0,0 -29.04367,-55.276659 -53.87134,-74.482949 -24.82764,-19.2063 -58.55579,-30.9174596 -91.34702,-30.4490096 -32.79123,0.46844 -61.834893,0 -80.57275,15.4587196 -18.737857,15.45873 -38.412605,9.83738 -55.276655,40.28638 C -0.79655901,88.239361 2.9510073,168.81213 2.9510073,168.81213 c 0,0 14.9902907,69.79849 22.9538837,71.67227 0,0 -0.468459,-13.11651 -0.468459,-36.07036 0,-22.95386 -7.963592,-50.12377 4.216025,-64.17714 12.17959,-14.05339 28.575206,-46.844629 37.944147,-53.402879 9.368916,-6.55825 27.638314,-24.3592 45.439286,-32.79124 17.80096,-8.43203 29.98055,-17.33251 34.19658,-17.80095 4.21602,-0.46845 17.3325,-3.74757 17.3325,-3.74757 0,0 -1.40532,7.02669 -6.08981,10.30581 -4.68445,3.27913 -39.34947,53.40288 -41.69171,65.114029 0,0 34.66504,-49.655299 40.75482,-49.655299 0,0 5.15292,1.40534 -0.46843,9.36893 -5.62135,7.96358 -22.01699,35.601909 -22.95388,47.313069 0,0 -1.40533,11.71116 0.93689,9.36892 0,0 34.19658,-43.097049 37.47571,-49.655299 3.27914,-6.55825 -17.3325,51.529089 -17.3325,51.529089 l 20.61164,-31.854349 1.87378,36.070359 0,15.45873 c 0,0 5.62135,7.49513 10.77427,-2.34222 5.15289,-9.83738 7.49513,-32.79125 7.49513,-32.79125 0,0 2.81067,33.25969 1.40532,37.00725 -1.40532,3.74757 0.46846,31.85434 4.21603,33.25969 3.74756,1.40535 8.90048,-3.27913 14.52183,-3.74756 5.62135,-0.46846 40.2864,48.24995 40.2864,57.15043 0,8.90049 -11.24274,14.52183 -9.83739,26.70146 1.40533,12.17959 3.27914,29.5121 3.74757,31.38588 0.46846,1.87378 0,18.73786 3.74757,22.01699 3.74757,3.27911 24.82767,29.5121 29.51213,-20.61164 4.68446,-50.12377 2.81067,-89.9417 2.81067,-89.9417 z"
67
+ id="path3769"
68
+ inkscape:connector-curvature="0" />
69
+ <path
70
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:2.52960968px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
71
+ d="m 221.71541,181.46018 c 0,0 -16.86405,19.67472 -20.14318,25.76453 -3.27913,6.08981 -5.15292,-18.2694 -5.15292,-18.2694 0,0 0,-21.54853 0.46846,-23.89077 0.46843,-2.34222 -2.34224,-52.46597 -2.34224,-52.46597 l -16.86405,38.4126 1.87378,-58.087349 -24.3592,42.160169 15.92715,-55.745109 -37.00725,46.844629 c 0,0 16.39564,-51.529089 21.54853,-57.618889 0,0 -6.08978,-8.90048 -37.00726,41.223269 0,0 -6.08978,6.0898 -4.68445,3.27912 1.40535,-2.81067 36.53882,-65.114029 36.53882,-65.114029 l 3.27911,-10.77426 c 0,0 -69.330058,21.08008 -89.941672,52.93443 -20.611641,31.854339 -38.412606,66.050929 -38.412606,66.050929 0,0 -2.342217,14.52183 -0.468434,19.20629 1.873784,4.68446 -0.936892,49.18685 -0.936892,49.18685 0,0 -14.9902908,-15.45873 -17.8009656,-22.95386 -2.8106747,-7.49513 -6.55824097,-54.80822 -4.2160247,-59.49268 2.3422416,-4.68446 -1.40532469,-59.961119 4.6844579,-63.240239 0,0 19.2063174,-55.27666 61.8349214,-61.83491 42.628605,-6.55825 112.427095,-8.9004796 125.543605,-2.34223 13.11648,6.55825 66.98781,32.79124 75.41984,52.46598 8.43205,19.67474 -20.61162,120.390679 -20.61162,120.390679 z"
72
+ id="path3791"
73
+ inkscape:connector-curvature="0"
74
+ sodipodi:nodetypes="cscsccccccccsccscscsscssscc" />
75
+ <path
76
+ style="fill:none;stroke:#8b8b8b;stroke-width:7.58882952;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
77
+ d="m 292.8225,212.03105 c 0,0 1.65621,28.15551 -26.16808,44.05511 -27.8243,15.89961 -38.42403,14.90588 -38.42403,14.90588"
78
+ id="path3787"
79
+ inkscape:connector-curvature="0" />
80
+ <path
81
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:2.52960968px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
82
+ d="m 229.55535,269.66708 c 0,0 -24.84312,7.61855 -30.14298,6.29359 -5.29986,-1.32498 -16.56206,1.98744 -15.56836,5.96234 0.99374,3.9749 0.99374,8.94351 7.28733,8.28103 6.29359,-0.66248 18.21827,-4.63738 22.85566,-7.2873 4.63738,-2.64994 8.28103,-3.9749 12.91841,-5.29988 4.63738,-1.32496 2.64994,-7.94978 2.64994,-7.94978 z"
83
+ id="path3789"
84
+ inkscape:connector-curvature="0"
85
+ sodipodi:nodetypes="csssssc" />
86
+ <path
87
+ style="fill:#282828;fill-opacity:1;stroke:#242424;stroke-width:2.52960968px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
88
+ d="m 270.96055,105.37126 c 0,0 -1.65622,-21.530699 -20.86823,-40.080219 -19.21201,-18.54953 -50.01747,-50.67995 -83.14162,-51.67368 -33.12415,-0.99373 -79.166722,-1.65621 -85.791543,1.98745 l -7.949804,0 c 0,0 29.811727,-20.8682196 102.022407,-12.2559396 72.21064,8.6122796 121.23439,99.3724586 121.89687,103.0161186 5.63108,1.32497 12.25593,25.5056 20.20573,40.41146 7.94981,14.90587 -4.9686,34.11788 -9.93724,49.35499 -4.96863,15.2371 -18.21827,17.22456 -22.52443,19.87448 -4.30613,2.64995 -13.58089,-1.32496 -13.58089,0.33126 0,1.65621 -4.96864,5.29986 -6.2936,6.29359 -1.32495,0.99373 -12.58719,9.27476 -18.54953,9.27476 -5.96234,0 -21.5307,-8.28103 -25.17435,-59.62348 -3.64365,-51.34244 21.19945,-66.2483 24.84312,-66.91079 3.64365,-0.66248 24.84311,0 24.84311,0 z"
89
+ id="path3775"
90
+ inkscape:connector-curvature="0" />
91
+ <g
92
+ transform="matrix(2.5296098,0,0,2.5296098,-575.6928,-113.50023)"
93
+ style="font-size:8px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
94
+ id="flowRoot3793">
95
+ <path
96
+ d="m 241.59863,183.97695 0,7.93652 1.66797,0 c 1.4082,0 2.43815,-0.31901 3.08985,-0.95703 0.65624,-0.63802 0.98436,-1.64518 0.98437,-3.02148 -1e-5,-1.36718 -0.32813,-2.36751 -0.98437,-3.00098 -0.6517,-0.63801 -1.68165,-0.95702 -3.08985,-0.95703 l -1.66797,0 m -1.38086,-1.13477 2.83692,0 c 1.97786,10e-6 3.42935,0.41245 4.35449,1.23731 0.92512,0.82032 1.38769,2.10547 1.38769,3.85547 0,1.75911 -0.46485,3.05111 -1.39453,3.87597 -0.92969,0.82487 -2.37891,1.23731 -4.34765,1.23731 l -2.83692,0 0,-10.20606"
97
+ style="font-size:14px"
98
+ id="path3813"
99
+ inkscape:connector-curvature="0" />
100
+ <path
101
+ d="m 253.90332,186.27382 c -0.67448,1e-5 -1.20769,0.26433 -1.59961,0.79297 -0.39193,0.5241 -0.58789,1.24415 -0.58789,2.16016 0,0.91602 0.19368,1.63835 0.58105,2.16699 0.39193,0.52409 0.92741,0.78614 1.60645,0.78613 0.66992,1e-5 1.20084,-0.26432 1.59277,-0.79296 0.39192,-0.52865 0.58789,-1.2487 0.58789,-2.16016 0,-0.9069 -0.19597,-1.62467 -0.58789,-2.15332 -0.39193,-0.5332 -0.92285,-0.7998 -1.59277,-0.79981 m 0,-1.0664 c 1.09374,10e-6 1.95279,0.35547 2.57715,1.0664 0.62434,0.71095 0.93651,1.69532 0.93652,2.95313 -10e-6,1.25326 -0.31218,2.23763 -0.93652,2.95312 -0.62436,0.71094 -1.48341,1.06641 -2.57715,1.06641 -1.09831,0 -1.95964,-0.35547 -2.58398,-1.06641 -0.6198,-0.71549 -0.92969,-1.69986 -0.92969,-2.95312 0,-1.25781 0.30989,-2.24218 0.92969,-2.95313 0.62434,-0.71093 1.48567,-1.06639 2.58398,-1.0664"
102
+ style="font-size:14px"
103
+ id="path3815"
104
+ inkscape:connector-curvature="0" />
105
+ <path
106
+ d="m 259.36523,190.02675 0,-4.63476 1.25782,0 0,4.58691 c -10e-6,0.72461 0.14127,1.26921 0.42382,1.63379 0.28255,0.36003 0.70638,0.54004 1.27149,0.54004 0.67903,0 1.21451,-0.21647 1.60644,-0.64941 0.39648,-0.43294 0.59472,-1.02311 0.59473,-1.77051 l 0,-4.34082 1.25781,0 0,7.65625 -1.25781,0 0,-1.17578 c -0.30534,0.46484 -0.66081,0.8112 -1.06641,1.03906 -0.40104,0.22331 -0.86816,0.33496 -1.40136,0.33496 -0.87956,0 -1.54721,-0.27344 -2.00293,-0.82031 -0.45573,-0.54688 -0.6836,-1.34668 -0.6836,-2.39942 m 3.16504,-4.81933 0,0"
107
+ style="font-size:14px"
108
+ id="path3817"
109
+ inkscape:connector-curvature="0" />
110
+ <path
111
+ d="m 273.87793,189.22695 c -10e-6,-0.92513 -0.19141,-1.64973 -0.57422,-2.17383 -0.37826,-0.52864 -0.90007,-0.79296 -1.56543,-0.79297 -0.66537,1e-5 -1.18946,0.26433 -1.57226,0.79297 -0.37826,0.5241 -0.56739,1.2487 -0.56739,2.17383 0,0.92513 0.18913,1.65202 0.56739,2.18066 0.3828,0.52409 0.90689,0.78614 1.57226,0.78614 0.66536,0 1.18717,-0.26205 1.56543,-0.78614 0.38281,-0.52864 0.57421,-1.25553 0.57422,-2.18066 m -4.2793,-2.67285 c 0.26432,-0.45572 0.597,-0.79296 0.99805,-1.01172 0.40559,-0.2233 0.88867,-0.33495 1.44922,-0.33496 0.92968,10e-6 1.68391,0.36915 2.26269,1.10742 0.58333,0.73829 0.875,1.70899 0.875,2.91211 0,1.20313 -0.29167,2.17383 -0.875,2.91211 -0.57878,0.73828 -1.33301,1.10742 -2.26269,1.10742 -0.56055,0 -1.04363,-0.10937 -1.44922,-0.32812 -0.40105,-0.22331 -0.73373,-0.56283 -0.99805,-1.01856 l 0,1.14844 -1.26465,0 0,-10.63672 1.26465,0 0,4.14258"
112
+ style="font-size:14px"
113
+ id="path3819"
114
+ inkscape:connector-curvature="0" />
115
+ <path
116
+ d="m 277.26855,182.41152 1.25782,0 0,10.63672 -1.25782,0 0,-10.63672"
117
+ style="font-size:14px"
118
+ id="path3821"
119
+ inkscape:connector-curvature="0" />
120
+ <path
121
+ d="m 287.7002,188.90566 0,0.61523 -5.78321,0 c 0.0547,0.86589 0.31445,1.5267 0.7793,1.98243 0.4694,0.45117 1.12109,0.67676 1.95508,0.67675 0.48306,1e-5 0.95019,-0.0592 1.40136,-0.17773 0.45573,-0.11849 0.9069,-0.29622 1.35352,-0.5332 l 0,1.18945 c -0.45118,0.19141 -0.91374,0.33724 -1.3877,0.4375 -0.47396,0.10026 -0.95475,0.15039 -1.44238,0.15039 -1.22136,0 -2.18978,-0.35547 -2.90527,-1.06641 -0.71094,-0.71093 -1.06641,-1.67252 -1.06641,-2.88476 0,-1.25325 0.33724,-2.24674 1.01172,-2.98047 0.67903,-0.73827 1.59277,-1.10741 2.74121,-1.10742 1.02994,10e-6 1.84342,0.33269 2.44043,0.99804 0.60156,0.66082 0.90234,1.56088 0.90235,2.7002 m -1.25782,-0.36914 c -0.009,-0.68815 -0.2028,-1.2373 -0.58105,-1.64746 -0.37371,-0.41015 -0.87045,-0.61523 -1.49024,-0.61524 -0.70182,1e-5 -1.26465,0.19825 -1.68847,0.59473 -0.41928,0.39649 -0.66081,0.95476 -0.72461,1.67481 l 4.48437,-0.007"
122
+ style="font-size:14px"
123
+ id="path3823"
124
+ inkscape:connector-curvature="0" />
125
+ <path
126
+ d="m 294.64551,185.61757 0,1.18946 c -0.35548,-0.18229 -0.72462,-0.31901 -1.10742,-0.41016 -0.38282,-0.0911 -0.77931,-0.13671 -1.18946,-0.13672 -0.62435,1e-5 -1.09375,0.0957 -1.4082,0.28711 -0.3099,0.19141 -0.46485,0.47852 -0.46484,0.86133 -1e-5,0.29167 0.11165,0.52181 0.33496,0.69043 0.2233,0.16407 0.67219,0.32129 1.34668,0.47168 l 0.43066,0.0957 c 0.89322,0.19141 1.52669,0.46257 1.90039,0.81348 0.37825,0.34636 0.56738,0.83171 0.56738,1.45605 0,0.71094 -0.28255,1.27377 -0.84765,1.68848 -0.56055,0.41471 -1.33301,0.62207 -2.31739,0.62207 -0.41015,0 -0.83854,-0.041 -1.28515,-0.12305 -0.44206,-0.0775 -0.90918,-0.19596 -1.40137,-0.35547 l 0,-1.29882 c 0.46484,0.24153 0.92285,0.42383 1.37402,0.54687 0.45117,0.11849 0.89779,0.17774 1.33985,0.17774 0.59244,0 1.04817,-0.10026 1.36719,-0.30079 0.319,-0.20507 0.47851,-0.49218 0.47851,-0.86132 0,-0.3418 -0.11621,-0.60384 -0.34863,-0.78614 -0.22787,-0.18228 -0.73145,-0.35774 -1.51074,-0.52636 l -0.4375,-0.10254 c -0.7793,-0.16406 -1.34213,-0.41471 -1.68848,-0.75196 -0.34635,-0.34179 -0.51953,-0.80891 -0.51953,-1.40136 0,-0.72005 0.25521,-1.27604 0.76562,-1.66797 0.51042,-0.39192 1.23503,-0.58788 2.17383,-0.58789 0.46484,10e-6 0.90234,0.0342 1.3125,0.10254 0.41015,0.0684 0.78841,0.1709 1.13477,0.30761"
127
+ style="font-size:14px"
128
+ id="path3825"
129
+ inkscape:connector-curvature="0" />
130
+ <path
131
+ d="m 297.06543,185.39199 1.25781,0 0,7.65625 -1.25781,0 0,-7.65625 m 0,-2.98047 1.25781,0 0,1.59277 -1.25781,0 0,-1.59277"
132
+ style="font-size:14px"
133
+ id="path3827"
134
+ inkscape:connector-curvature="0" />
135
+ <path
136
+ d="m 307.3125,188.42714 0,4.6211 -1.25781,0 0,-4.58008 c -10e-6,-0.7246 -0.14128,-1.26692 -0.42383,-1.62695 -0.28256,-0.36002 -0.70639,-0.54004 -1.27149,-0.54004 -0.67904,0 -1.21452,0.21648 -1.60644,0.64941 -0.39193,0.43295 -0.58789,1.02312 -0.58789,1.77051 l 0,4.32715 -1.26465,0 0,-7.65625 1.26465,0 0,1.18945 c 0.30078,-0.46028 0.65397,-0.80435 1.05957,-1.03223 0.41015,-0.22785 0.88183,-0.34178 1.41504,-0.34179 0.87955,10e-6 1.54491,0.27344 1.99609,0.82031 0.45117,0.54232 0.67675,1.34213 0.67676,2.39941"
137
+ style="font-size:14px"
138
+ id="path3829"
139
+ inkscape:connector-curvature="0" />
140
+ <path
141
+ d="m 314.87305,189.13125 c -10e-6,-0.91146 -0.18914,-1.61784 -0.56739,-2.11914 -0.3737,-0.5013 -0.90007,-0.75195 -1.5791,-0.75196 -0.67448,1e-5 -1.20085,0.25066 -1.5791,0.75196 -0.3737,0.5013 -0.56055,1.20768 -0.56055,2.11914 0,0.9069 0.18685,1.611 0.56055,2.1123 0.37825,0.5013 0.90462,0.75195 1.5791,0.75195 0.67903,0 1.2054,-0.25065 1.5791,-0.75195 0.37825,-0.5013 0.56738,-1.2054 0.56739,-2.1123 m 1.25781,2.96679 c -10e-6,1.30339 -0.2894,2.27181 -0.86816,2.90528 -0.57879,0.63801 -1.46518,0.95702 -2.65918,0.95703 -0.44207,-1e-5 -0.85906,-0.0342 -1.25098,-0.10254 -0.39193,-0.0638 -0.77246,-0.16407 -1.1416,-0.30078 l 0,-1.22364 c 0.36914,0.20052 0.73372,0.34864 1.09375,0.44434 0.36002,0.0957 0.72688,0.14355 1.10058,0.14356 0.82487,-1e-5 1.44238,-0.21648 1.85254,-0.64942 0.41015,-0.42839 0.61523,-1.0778 0.61524,-1.94824 l 0,-0.62207 c -0.25977,0.45117 -0.59246,0.78841 -0.99805,1.01172 -0.4056,0.2233 -0.89095,0.33496 -1.45605,0.33496 -0.93881,0 -1.69532,-0.35775 -2.26954,-1.07324 -0.57422,-0.7155 -0.86132,-1.66341 -0.86132,-2.84375 0,-1.18489 0.2871,-2.13509 0.86132,-2.85059 0.57422,-0.71549 1.33073,-1.07323 2.26954,-1.07324 0.5651,10e-6 1.05045,0.11166 1.45605,0.33496 0.40559,0.22331 0.73828,0.56055 0.99805,1.01172 l 0,-1.16211 1.25781,0 0,6.70605"
142
+ style="font-size:14px"
143
+ id="path3831"
144
+ inkscape:connector-curvature="0" />
145
+ </g>
146
+ </svg>
data/bin/console ADDED
@@ -0,0 +1,13 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "doublesing"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+ text = "test \\block{nesting \\now{woo}{arity}}"
9
+
10
+ # (If you use this, don't forget to add pry to your Gemfile!)
11
+ require "pry"
12
+ Pry.start
13
+
data/bin/setup ADDED
@@ -0,0 +1,7 @@
1
+ #!/bin/bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+
5
+ bundle install
6
+
7
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,29 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'doublesing/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "doublesing"
8
+ spec.version = Doublesing::VERSION
9
+ spec.authors = ["Anthony Super"]
10
+ spec.email = ["anthony@noided.media"]
11
+ spec.summary = %q{An extensible markup language}
12
+ spec.homepage = "http://www.github.com/AnthonySuper/Doublesing"
13
+ spec.license = "MIT"
14
+
15
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
16
+ spec.bindir = "exe"
17
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
18
+ spec.require_paths = ["lib"]
19
+
20
+ spec.add_development_dependency "bundler", ">= 1.7"
21
+ spec.add_development_dependency "rake", "~> 10.0"
22
+ spec.add_development_dependency "rspec"
23
+ spec.add_development_dependency "pry"
24
+ spec.add_development_dependency "simplecov"
25
+ spec.add_development_dependency "codeclimate-test-reporter"
26
+ spec.add_runtime_dependency "sanitize-url"
27
+ spec.add_runtime_dependency "sanitize"
28
+ spec.add_runtime_dependency "parslet"
29
+ end
@@ -0,0 +1,14 @@
1
+ module Doublesing
2
+ module Builtins
3
+ class Bold
4
+ def initialize(args)
5
+ @args = args
6
+ end
7
+
8
+ def to_s
9
+ "<b>#{@args.first}</b>"
10
+ end
11
+ end
12
+ end
13
+ end
14
+
@@ -0,0 +1,18 @@
1
+ module Doublesing
2
+ module Builtins
3
+ class Header
4
+ def initialize(a)
5
+ @level = a[0].to_i
6
+ @body = a[1].to_s
7
+ end
8
+ def to_s
9
+ if @level && @level > 0
10
+ "<h#{@level}>#{@body}</h#{@level}>"
11
+ else
12
+ "<h1>#{@body}</h1>"
13
+ end
14
+ end
15
+ end
16
+ end
17
+ end
18
+
@@ -0,0 +1,13 @@
1
+ module Doublesing
2
+ module Builtins
3
+ class Italic
4
+ def initialize(arg)
5
+ @arg = arg
6
+ end
7
+ def to_s
8
+ "<i>#{@arg.first.to_s}</i>"
9
+ end
10
+ end
11
+ end
12
+ end
13
+
@@ -0,0 +1,23 @@
1
+ require 'uri'
2
+ require 'sanitize-url'
3
+ include SanitizeUrl
4
+
5
+ module Doublesing
6
+ module Builtins
7
+ class Link
8
+ def initialize(args)
9
+ @url = args.first.to_s
10
+ @body = args.last.to_s
11
+ end
12
+
13
+ def to_s
14
+ if @url =~ URI::regexp && ! sanitize_url(@url).empty?
15
+ "<a href=\"#{@url}\">#{@body}</a>"
16
+ else
17
+ @body
18
+ end
19
+ end
20
+ end
21
+ end
22
+ end
23
+
@@ -0,0 +1,12 @@
1
+ Dir[File.dirname(__FILE__) + "/builtins/*.rb"].each{|file| require file}
2
+ module Doublesing
3
+ module Builtins
4
+ def self.handlers
5
+ {"bold" => Bold,
6
+ "italic" => Italic,
7
+ "link" => Link,
8
+ "header" => Header}
9
+
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,16 @@
1
+ require 'parslet'
2
+ module Doublesing
3
+ class Parser < Parslet::Parser
4
+ rule(:argument_begin){ str("{") }
5
+ rule(:argument_end){ str("\\}").absent? >> str("}")}
6
+ rule(:block_begin){ str("\\\\").absent? >> str("\\")}
7
+ rule(:block_id){ match["\\w"].repeat(1)}
8
+ rule(:block_header){ block_begin >> block_id.as(:id)}
9
+ rule(:text){ (block_header.absent? >> argument_end.absent? >> any).repeat(1).as(:text)}
10
+ rule(:block){ block_header >> (argument_begin >> body.as(:body) >> argument_end).repeat.as(:argument)}
11
+ rule(:expr) {text | block}
12
+ rule(:body) {expr.repeat(1)}
13
+ rule(:document){expr.repeat(1)}
14
+ root(:document)
15
+ end
16
+ end
@@ -0,0 +1,10 @@
1
+ require 'parslet'
2
+ module Doublesing
3
+ class Transformer < Parslet::Transform
4
+ rule(text: simple(:text)){text}
5
+ rule(body: sequence(:body)){body.join("")}
6
+ rule(id: simple(:id),
7
+ argument: sequence(:argument)){Doublesing.process(id, argument)}
8
+ end
9
+ end
10
+
@@ -0,0 +1,3 @@
1
+ module Doublesing
2
+ VERSION = "0.1.0"
3
+ end
data/lib/doublesing.rb ADDED
@@ -0,0 +1,35 @@
1
+ require "doublesing/version"
2
+ require "doublesing/parser"
3
+ require "doublesing/transformer"
4
+ require "doublesing/builtins"
5
+ require "sanitize"
6
+
7
+ require "pp"
8
+ module Doublesing
9
+ def self.parse(str)
10
+ sanitized = Sanitize.fragment(str)
11
+ tree = Parser.new.parse(sanitized)
12
+ res = Transformer.new.apply(tree)
13
+ res.join("")
14
+ end
15
+ ##
16
+ # Assign a handler for a custom block class.
17
+ # +name+: Name the block should respond to
18
+ # +klass+: class the block should be generated from
19
+ # Note:
20
+ def self.assign(name, klass)
21
+ @@handlers[name] = klass
22
+ end
23
+
24
+ def self.process(id, args)
25
+ if handler = @@handlers[id.to_s]
26
+ handler.new(args).to_s
27
+ else
28
+ ""
29
+ end
30
+ end
31
+ def self.setup!
32
+ @@handlers = {}
33
+ @@handlers.merge! Builtins.handlers
34
+ end
35
+ end
@@ -0,0 +1,38 @@
1
+ \subsection{Whitespace}
2
+ Whitespace is ignored in Doublesing, expect for one character: the blank newline.
3
+ A blank newline is a single line, by itself. As C printf escape sequences, it is:
4
+ \begin{verbatim}
5
+ \n\r\n\r
6
+ \end{verbatim}
7
+
8
+ This will cause a new \begin{verbatim}<p>\end{verbatim} tag to be inserted inside of direct-display blocks.
9
+
10
+ \subsection{Blocks}
11
+ A block is defined by an identifier and one or more arguments, which should be text surrounded by the characters "\{" and "\}".
12
+ A valid block identifier can be matched by the regex:
13
+ \begin{verbatim}
14
+ /[a-zA-Z0-9_].+/
15
+ \end{verbatim}
16
+
17
+ By convention, all the built-in block types use lowercase names, with words separated by underscores.
18
+ Vendors are encouraged (but not required) to use the same convention.
19
+
20
+ \subsection{Arguments}
21
+ Arguments to blocks are evaluated at the deepest level first, then expand outwards through the tree.
22
+
23
+ As an example:
24
+
25
+ \begin{verbatim}
26
+ \link{www.imagehex.com}{\bold{Free} advertising for the author!}
27
+ \end{verbatim}
28
+
29
+ Becomes:
30
+ \begin{verbatim}
31
+ \link{www.imagehex.com}{<b>free</b> advertising for the author!}
32
+ \end{verbatim}
33
+ Which then becomes:
34
+ \begin{verbatim}
35
+ <a href="wwww.imagehex.com"><b>free</b> advertising for the author!</a>
36
+ \end{verbatim}
37
+
38
+
@@ -0,0 +1,13 @@
1
+ \subsection{Bold}
2
+
3
+ The bold block simply defines bold text.
4
+ It is used as follows:
5
+
6
+ \begin{verbatim}
7
+ \bold{test}
8
+ \end{verbatim}
9
+
10
+ becomes
11
+ \begin{verbatim}
12
+ <b>test</b>
13
+ \end{verbatim}
@@ -0,0 +1,13 @@
1
+ \subsection{Italics}
2
+
3
+ The Italics block makes some text italic.
4
+ Thus:
5
+ \begin{verbatim}
6
+ \italic{this text will be italicized}
7
+ \end{verbatim}
8
+
9
+ Becomes:
10
+
11
+ \begin{verbatim}
12
+ <i>this text will be italicized</i>
13
+ \end{verbatim}
@@ -0,0 +1,22 @@
1
+ \subsection{Header}
2
+
3
+ The \begin{verbatim}header\end{verbatim} tag creates a new html heading.
4
+
5
+ It accepts two arguments:
6
+ \begin{enumerate}
7
+ \item the header depth
8
+ \item the header body
9
+ \end{enumerate}
10
+
11
+ If the header depth is not a valid integer, it will default to 1.
12
+
13
+ Thus, this:
14
+
15
+ \begin{verbatim}
16
+ \header{1}{this is a header}
17
+ \end{verbatim}
18
+
19
+ becomes:
20
+ \begin{verbatim}
21
+ <h1>this is a header</h1>
22
+ \end{verbatim}
data/tex/spec.tex ADDED
@@ -0,0 +1,18 @@
1
+ \documentclass{article}
2
+
3
+ \begin{document}
4
+ \title{The Doublesing Markup Language}
5
+ \author{Anthony Super}
6
+ \maketitle
7
+ \begin{abstract}
8
+ The Doublesing Markup Language is a \LaTeX-like language designed for wiki markup.
9
+ This document defines universal features, although websites are free to add their own extensions.
10
+ \end{abstract}
11
+ \section{General Rules}
12
+ \input{./tex/general/main}
13
+ \section{Inline Elements (Arity 1)}
14
+ \input{./tex/inline/bold}
15
+ \input{./tex/inline/italic}
16
+ \section{Inline Elements (Arity 2)}
17
+ \input{./tex/inline-2/header}
18
+ \end{document}
metadata ADDED
@@ -0,0 +1,198 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: doublesing
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Anthony Super
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2015-02-28 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '1.7'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '1.7'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: pry
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: simplecov
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: codeclimate-test-reporter
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: sanitize-url
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :runtime
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: sanitize
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :runtime
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
125
+ - !ruby/object:Gem::Dependency
126
+ name: parslet
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - ">="
130
+ - !ruby/object:Gem::Version
131
+ version: '0'
132
+ type: :runtime
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - ">="
137
+ - !ruby/object:Gem::Version
138
+ version: '0'
139
+ description:
140
+ email:
141
+ - anthony@noided.media
142
+ executables: []
143
+ extensions: []
144
+ extra_rdoc_files: []
145
+ files:
146
+ - ".gitignore"
147
+ - ".rspec"
148
+ - ".travis.yml"
149
+ - CODE_OF_CONDUCT.md
150
+ - Gemfile
151
+ - LICENSE.txt
152
+ - README.md
153
+ - Rakefile
154
+ - assets/logo-opt.svg
155
+ - assets/logo.svg
156
+ - bin/console
157
+ - bin/setup
158
+ - doublesing.gemspec
159
+ - lib/doublesing.rb
160
+ - lib/doublesing/builtins.rb
161
+ - lib/doublesing/builtins/bold.rb
162
+ - lib/doublesing/builtins/header.rb
163
+ - lib/doublesing/builtins/italic.rb
164
+ - lib/doublesing/builtins/link.rb
165
+ - lib/doublesing/parser.rb
166
+ - lib/doublesing/transformer.rb
167
+ - lib/doublesing/version.rb
168
+ - tex/general/main.tex
169
+ - tex/inline-2/header.tex
170
+ - tex/inline/bold.tex
171
+ - tex/inline/italic.tex
172
+ - tex/spec.tex
173
+ homepage: http://www.github.com/AnthonySuper/Doublesing
174
+ licenses:
175
+ - MIT
176
+ metadata: {}
177
+ post_install_message:
178
+ rdoc_options: []
179
+ require_paths:
180
+ - lib
181
+ required_ruby_version: !ruby/object:Gem::Requirement
182
+ requirements:
183
+ - - ">="
184
+ - !ruby/object:Gem::Version
185
+ version: '0'
186
+ required_rubygems_version: !ruby/object:Gem::Requirement
187
+ requirements:
188
+ - - ">="
189
+ - !ruby/object:Gem::Version
190
+ version: '0'
191
+ requirements: []
192
+ rubyforge_project:
193
+ rubygems_version: 2.2.2
194
+ signing_key:
195
+ specification_version: 4
196
+ summary: An extensible markup language
197
+ test_files: []
198
+ has_rdoc: