wallyqs-org-ruby 0.6.1 → 0.8.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (122) hide show
  1. data/History.txt +41 -11
  2. data/README.rdoc +55 -50
  3. data/bin/org-ruby +11 -5
  4. data/lib/org-ruby.rb +20 -27
  5. data/lib/org-ruby/headline.rb +0 -10
  6. data/lib/org-ruby/html_output_buffer.rb +224 -143
  7. data/lib/org-ruby/html_symbol_replace.rb +359 -340
  8. data/lib/org-ruby/line.rb +91 -30
  9. data/lib/org-ruby/output_buffer.rb +147 -139
  10. data/lib/org-ruby/parser.rb +45 -111
  11. data/lib/org-ruby/regexp_helper.rb +52 -57
  12. data/lib/org-ruby/textile_output_buffer.rb +90 -37
  13. data/lib/org-ruby/textile_symbol_replace.rb +360 -341
  14. metadata +39 -200
  15. data/.bnsignore +0 -18
  16. data/.gitignore +0 -2
  17. data/Gemfile +0 -7
  18. data/Gemfile.lock +0 -36
  19. data/Rakefile +0 -33
  20. data/TAGS +0 -167
  21. data/announcement.txt +0 -24
  22. data/org-ruby.gemspec +0 -40
  23. data/spec/data/freeform-example.org +0 -113
  24. data/spec/data/freeform.org +0 -111
  25. data/spec/data/hyp-planning.org +0 -335
  26. data/spec/data/remember.org +0 -53
  27. data/spec/headline_spec.rb +0 -65
  28. data/spec/html_examples/advanced-code.html +0 -81
  29. data/spec/html_examples/advanced-code.org +0 -106
  30. data/spec/html_examples/advanced-lists.html +0 -31
  31. data/spec/html_examples/advanced-lists.org +0 -31
  32. data/spec/html_examples/block_code.html +0 -28
  33. data/spec/html_examples/block_code.org +0 -35
  34. data/spec/html_examples/blockcomment.html +0 -3
  35. data/spec/html_examples/blockcomment.org +0 -15
  36. data/spec/html_examples/blockquote.html +0 -7
  37. data/spec/html_examples/blockquote.org +0 -13
  38. data/spec/html_examples/center.html +0 -6
  39. data/spec/html_examples/center.org +0 -7
  40. data/spec/html_examples/code-comment.html +0 -18
  41. data/spec/html_examples/code-comment.org +0 -22
  42. data/spec/html_examples/code-syntax.html +0 -98
  43. data/spec/html_examples/code-syntax.org +0 -99
  44. data/spec/html_examples/comment-trees.html +0 -4
  45. data/spec/html_examples/comment-trees.org +0 -13
  46. data/spec/html_examples/custom-seq-todo.html +0 -15
  47. data/spec/html_examples/custom-seq-todo.org +0 -24
  48. data/spec/html_examples/custom-todo.html +0 -15
  49. data/spec/html_examples/custom-todo.org +0 -24
  50. data/spec/html_examples/custom-typ-todo.html +0 -15
  51. data/spec/html_examples/custom-typ-todo.org +0 -24
  52. data/spec/html_examples/deflist.html +0 -6
  53. data/spec/html_examples/deflist.org +0 -6
  54. data/spec/html_examples/entities.html +0 -4
  55. data/spec/html_examples/entities.org +0 -11
  56. data/spec/html_examples/escape-pre.html +0 -6
  57. data/spec/html_examples/escape-pre.org +0 -6
  58. data/spec/html_examples/export-exclude-only.html +0 -13
  59. data/spec/html_examples/export-exclude-only.org +0 -81
  60. data/spec/html_examples/export-keywords.html +0 -4
  61. data/spec/html_examples/export-keywords.org +0 -18
  62. data/spec/html_examples/export-tags.html +0 -8
  63. data/spec/html_examples/export-tags.org +0 -82
  64. data/spec/html_examples/export-title.html +0 -2
  65. data/spec/html_examples/export-title.org +0 -4
  66. data/spec/html_examples/footnotes.html +0 -10
  67. data/spec/html_examples/footnotes.org +0 -7
  68. data/spec/html_examples/html-literal.html +0 -2
  69. data/spec/html_examples/html-literal.org +0 -6
  70. data/spec/html_examples/inline-formatting.html +0 -20
  71. data/spec/html_examples/inline-formatting.org +0 -33
  72. data/spec/html_examples/inline-images.html +0 -10
  73. data/spec/html_examples/inline-images.org +0 -15
  74. data/spec/html_examples/link-features.html +0 -8
  75. data/spec/html_examples/link-features.org +0 -19
  76. data/spec/html_examples/lists.html +0 -23
  77. data/spec/html_examples/lists.org +0 -47
  78. data/spec/html_examples/metadata-comment.html +0 -27
  79. data/spec/html_examples/metadata-comment.org +0 -30
  80. data/spec/html_examples/only-list.html +0 -5
  81. data/spec/html_examples/only-list.org +0 -3
  82. data/spec/html_examples/only-table.html +0 -6
  83. data/spec/html_examples/only-table.org +0 -5
  84. data/spec/html_examples/skip-header.html +0 -3
  85. data/spec/html_examples/skip-header.org +0 -28
  86. data/spec/html_examples/skip-table.html +0 -4
  87. data/spec/html_examples/skip-table.org +0 -19
  88. data/spec/html_examples/subsupscript-nil.html +0 -3
  89. data/spec/html_examples/subsupscript-nil.org +0 -6
  90. data/spec/html_examples/subsupscript.html +0 -3
  91. data/spec/html_examples/subsupscript.org +0 -5
  92. data/spec/html_examples/tables.html +0 -35
  93. data/spec/html_examples/tables.org +0 -50
  94. data/spec/html_examples/text.html +0 -2
  95. data/spec/html_examples/text.org +0 -16
  96. data/spec/line_spec.rb +0 -155
  97. data/spec/output_buffer_spec.rb +0 -19
  98. data/spec/parser_spec.rb +0 -152
  99. data/spec/regexp_helper_spec.rb +0 -57
  100. data/spec/spec_helper.rb +0 -20
  101. data/spec/textile_examples/block_code.org +0 -35
  102. data/spec/textile_examples/block_code.textile +0 -29
  103. data/spec/textile_examples/blockquote.org +0 -13
  104. data/spec/textile_examples/blockquote.textile +0 -11
  105. data/spec/textile_examples/center.org +0 -7
  106. data/spec/textile_examples/center.textile +0 -6
  107. data/spec/textile_examples/footnotes.org +0 -7
  108. data/spec/textile_examples/footnotes.textile +0 -8
  109. data/spec/textile_examples/keywords.org +0 -13
  110. data/spec/textile_examples/keywords.textile +0 -11
  111. data/spec/textile_examples/links.org +0 -11
  112. data/spec/textile_examples/links.textile +0 -10
  113. data/spec/textile_examples/lists.org +0 -36
  114. data/spec/textile_examples/lists.textile +0 -20
  115. data/spec/textile_examples/single-space-plain-list.org +0 -13
  116. data/spec/textile_examples/single-space-plain-list.textile +0 -10
  117. data/spec/textile_examples/tables.org +0 -50
  118. data/spec/textile_examples/tables.textile +0 -40
  119. data/spec/textile_output_buffer_spec.rb +0 -21
  120. data/tasks/test_case.rake +0 -49
  121. data/test/test_orgmode_parser.rb +0 -0
  122. data/util/gen-special-replace.el +0 -37
@@ -1,53 +0,0 @@
1
- * New Ideas
2
- ** YAML header in Webby
3
-
4
- Make sure you don't have TABS here. Best practice: Configure your
5
- editor to use spaces instaed of tabs, and if you can see whitespace,
6
- even better.
7
-
8
- In emacs, set indent-tabs-mode to NIL.
9
- ** Ruby Gems behind Proxy
10
-
11
- Set the following environment variable:
12
-
13
- So, I added a User Variable for my account called http_proxy with
14
- the value of http://<proxyserveraddress>:8080, rebooted, ran plan
15
- old vanillia gem install rails –include-dependencies, and magically,
16
- it worked
17
- ** Hyper-V technical info
18
-
19
- http://technet.microsoft.com/en-us/dd565807.aspx
20
- ** VirtualBox
21
-
22
- Virtualization software from Sun. Looks like it might be more for
23
- dev/test. I'm surprised this hasn't popped at
24
- all. http://www.virtualbox.org/. Backed by Sun.
25
- ** Interesting LaTeX article
26
-
27
- http://nitens.org/taraborelli/latex -- on the virtues of LaTeX
28
- ** XEmacs / Emacs internals
29
-
30
- Looks like an interesting resource if I want to learn how Emacs works.
31
-
32
- http://www.xemacs.org/Documentation/21.5/html/internals_9.html#SEC19
33
- ** MikTeX
34
-
35
- Get it here: http://www.miktex.org/portable/
36
- ** Orgmode publishing tutorial
37
-
38
- [[http://orgmode.org/worg/org-tutorials/org-publish-html-tutorial.php][Publishing Org-mode files to HTML]]
39
- ** Git and Live Mesh
40
-
41
- This is really helpful:
42
- http://whereslou.com/2009/06/04/using-live-mesh-and-git-the-best-of-both-worlds
43
- ** VDI deployment stats
44
-
45
- Key takeaways:
46
- - 74% are using VDI in production or pilot ... but 45% of those using have less than 100 users
47
- - Upward of 55% of the DAC members [project] they will have up to 50% of their users using VDI in 3 years (~1/2 of those will have > 50%)
48
- - No real surprises on the reasons / benefits etc
49
- - Interestingly ... even if TS supported all client apps / supported user-install apps - 100% of the DAC preferred VDI over TS
50
- - Most companies said a portion of their users would have VDI as the primary replacement desktop (60% < 20% of users, 32% 21-50% of users)
51
- ** Hyper-V Scheduler Information
52
-
53
- http://msdn.microsoft.com/en-us/library/bb969782.aspx
@@ -1,65 +0,0 @@
1
-
2
- require File.join(File.dirname(__FILE__), %w[spec_helper])
3
-
4
- describe Orgmode::Headline do
5
-
6
- it "should recognize headlines that start with asterisks" do
7
- Orgmode::Headline.headline?("*** test\n").should_not be_nil
8
- end
9
-
10
- it "should reject headlines without headlines at the start" do
11
- Orgmode::Headline.headline?(" nope!").should be_nil
12
- Orgmode::Headline.headline?(" tricked you!!!***").should be_nil
13
- end
14
-
15
- it "should reject improper initialization" do
16
- lambda { Orgmode::Headline.new " tricked**" }.should raise_error
17
- end
18
-
19
- it "should properly determine headline level" do
20
- samples = ["* one", "** two", "*** three", "**** four"]
21
- expected = 1
22
- samples.each do |sample|
23
- h = Orgmode::Headline.new sample
24
- h.level.should eql(expected)
25
- expected += 1
26
- end
27
- end
28
-
29
- it "should properly determine headline level with offset" do
30
- h = Orgmode::Headline.new("* one", nil, 1)
31
- h.level.should eql(2)
32
- end
33
-
34
- it "should find simple headline text" do
35
- h = Orgmode::Headline.new "*** sample"
36
- h.headline_text.should eql("sample")
37
- end
38
-
39
- it "should understand tags" do
40
- h = Orgmode::Headline.new "*** sample :tag:tag2:\n"
41
- h.headline_text.should eql("sample")
42
- h.should have(2).tags
43
- h.tags[0].should eql("tag")
44
- h.tags[1].should eql("tag2")
45
- end
46
-
47
- it "should understand a single tag" do
48
- h = Orgmode::Headline.new "*** sample :tag:\n"
49
- h.headline_text.should eql("sample")
50
- h.should have(1).tags
51
- h.tags[0].should eql("tag")
52
- end
53
-
54
- it "should understand keywords" do
55
- h = Orgmode::Headline.new "*** TODO Feed cat :home:"
56
- h.headline_text.should eql("Feed cat")
57
- h.keyword.should eql("TODO")
58
- end
59
-
60
- it "should recognize headlines marked as COMMENT" do
61
- h = Orgmode::Headline.new "* COMMENT This headline is a comment"
62
- h.comment_headline?.should_not be_nil
63
- end
64
- end
65
-
@@ -1,81 +0,0 @@
1
- <p class="title">advanced-code.org</p>
2
- <p>Turns out there&#8217;s more way to do code than just BEGIN_EXAMPLE.</p>
3
- <h1><span class="heading-number heading-number-1">1 </span>Inline examples</h1>
4
- <p>This should work:</p>
5
- <pre class="example">
6
- fixed width? how does this work?
7
- ...........
8
- ............
9
- .
10
- . . . .
11
- . ..
12
- ....... .....
13
- . .
14
- ....
15
- </pre>
16
- <p>Two ASCII blobs.</p>
17
- <h1><span class="heading-number heading-number-1">2 </span>BEGIN_SRC</h1>
18
- <p>And this:</p>
19
- <pre class="src">
20
- <code class="ruby">
21
- <span style="color:#777"># Finds all emphasis matches in a string.</span>
22
- <span style="color:#777"># Supply a block that will get the marker and body as parameters.</span>
23
- <span style="color:#080;font-weight:bold">def</span> <span style="color:#06B;font-weight:bold">match_all</span>(str)
24
- str.scan(<span style="color:#33B">@org_emphasis_regexp</span>) <span style="color:#080;font-weight:bold">do</span> |match|
25
- <span style="color:#080;font-weight:bold">yield</span> <span style="color:#d70">$2</span>, <span style="color:#d70">$3</span>
26
- <span style="color:#080;font-weight:bold">end</span>
27
- <span style="color:#080;font-weight:bold">end</span>
28
- </code>
29
- </pre>
30
- <p>Now let&#8217;s test case-insensitive code blocks.</p>
31
- <pre class="src">
32
- <code class="ruby">
33
- <span style="color:#777"># Finds all emphasis matches in a string.</span>
34
- <span style="color:#777"># Supply a block that will get the marker and body as parameters.</span>
35
- <span style="color:#080;font-weight:bold">def</span> <span style="color:#06B;font-weight:bold">match_all</span>(str)
36
- str.scan(<span style="color:#33B">@org_emphasis_regexp</span>) <span style="color:#080;font-weight:bold">do</span> |match|
37
- <span style="color:#080;font-weight:bold">yield</span> <span style="color:#d70">$2</span>, <span style="color:#d70">$3</span>
38
- <span style="color:#080;font-weight:bold">end</span>
39
- <span style="color:#080;font-weight:bold">end</span>
40
- </code>
41
- </pre>
42
- <pre class="src">
43
- <code class="clojure">
44
- (<span style="color:#080;font-weight:bold">def</span> <span style="color:#06B;font-weight:bold">fib-seq</span>
45
- (<span style="color:#080;font-weight:bold">concat</span>
46
- [<span style="color:#00D">0</span> <span style="color:#00D">1</span>]
47
- ((<span style="color:#080;font-weight:bold">fn</span> rfib [a b]
48
- (lazy-cons (<span style="color:#080;font-weight:bold">+</span> a b) (rfib b (<span style="color:#080;font-weight:bold">+</span> a b)))) <span style="color:#00D">0</span> <span style="color:#00D">1</span>)))
49
-
50
- user&gt; (<span style="color:#080;font-weight:bold">take</span> <span style="color:#00D">20</span> fib-seq)
51
- (<span style="color:#00D">0</span> <span style="color:#00D">1</span> <span style="color:#00D">1</span> <span style="color:#00D">2</span> <span style="color:#00D">3</span> <span style="color:#00D">5</span> <span style="color:#00D">8</span> <span style="color:#00D">13</span> <span style="color:#00D">21</span> <span style="color:#00D">34</span> <span style="color:#00D">55</span> <span style="color:#00D">89</span> <span style="color:#00D">144</span> <span style="color:#00D">233</span> <span style="color:#00D">377</span> <span style="color:#00D">610</span> <span style="color:#00D">987</span> <span style="color:#00D">1597</span> <span style="color:#00D">2584</span> <span style="color:#00D">4181</span>)
52
- </code>
53
- </pre>
54
- <p>Even if no language is set, it is still wrapped in code tags but class is empty.</p>
55
- <pre class="src">
56
- <code class="">
57
- echo 'Defaults env_keeps="http_proxy https_proxy ftp_proxy"' | sudo tee -a /etc/sudoers
58
- </code>
59
- </pre>
60
- <h1><span class="heading-number heading-number-1">3 </span>It should be possible to write a colon at the beginning of an example</h1>
61
- <blockquote>
62
- <p>I really love to write about :symbols. They sure are the best things in the world!</p>
63
- </blockquote>
64
- <pre class="src">
65
- <code class="ruby">
66
- {
67
- <span style="color:#A60">:one</span> =&gt; <span style="color:#00D">1</span>,
68
- <span style="color:#A60">:two</span> =&gt; <span style="color:#00D">2</span>
69
- }
70
- </code>
71
- </pre>
72
- <pre class="src">
73
- <code class="clojure">
74
- (defproject helloworld <span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">&quot;</span><span style="color:#D20">0.1</span><span style="color:#710">&quot;</span></span>
75
- <span style="color:#A60">:dependencies</span> [[org.clojure/clojure
76
- <span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">&quot;</span><span style="color:#D20">1.1.0-master-SNAPSHOT</span><span style="color:#710">&quot;</span></span>]
77
- [org.clojure/clojure-contrib
78
- <span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">&quot;</span><span style="color:#D20">1.0-SNAPSHOT</span><span style="color:#710">&quot;</span></span>]]
79
- <span style="color:#A60">:main</span> helloworld)
80
- </code>
81
- </pre>
@@ -1,106 +0,0 @@
1
- #+TITLE: advanced-code.org
2
- #+AUTHOR: Brian Dewey
3
- #+EMAIL: bdewey@gmail.com
4
- #+DATE: 2009-12-30 Wed
5
- #+DESCRIPTION: More types of code support
6
- #+KEYWORDS:
7
- #+LANGUAGE: en
8
- #+OPTIONS: H:3 num:t toc:nil \n:nil @:t ::t |:t ^:t -:t f:t *:t <:t
9
- #+OPTIONS: TeX:t LaTeX:nil skip:nil d:nil todo:t pri:nil tags:not-in-toc
10
- #+INFOJS_OPT: view:nil toc:nil ltoc:t mouse:underline buttons:0 path:http://orgmode.org/org-info.js
11
- #+EXPORT_SELECT_TAGS: export
12
- #+EXPORT_EXCLUDE_TAGS: noexport
13
- #+LINK_UP:
14
- #+LINK_HOME:
15
-
16
- Turns out there's more way to do code than just BEGIN_EXAMPLE.
17
-
18
- * Inline examples
19
-
20
- This should work:
21
-
22
- : fixed width? how does this work?
23
- : ...........
24
- : ............
25
- : .
26
- : . . . .
27
- : . ..
28
- : ....... .....
29
- : . .
30
- : ....
31
-
32
- Two ASCII blobs.
33
-
34
- * BEGIN_SRC
35
- :PROPERTIES:
36
- :ARCHIVE_TIME: 2009-12-26 Sat 22:16
37
- :ARCHIVE_FILE: ~/brians-brain/content/projects/orgmode_parser.org
38
- :ARCHIVE_OLPATH: &lt;%= @page.title %&gt;/Future Development
39
- :ARCHIVE_CATEGORY: orgmode_parser
40
- :ARCHIVE_TODO: DONE
41
- :END:
42
-
43
- And this:
44
-
45
- #+BEGIN_SRC ruby
46
- # Finds all emphasis matches in a string.
47
- # Supply a block that will get the marker and body as parameters.
48
- def match_all(str)
49
- str.scan(@org_emphasis_regexp) do |match|
50
- yield $2, $3
51
- end
52
- end
53
- #+END_SRC
54
-
55
- Now let's test case-insensitive code blocks.
56
-
57
- #+begin_src ruby
58
- # Finds all emphasis matches in a string.
59
- # Supply a block that will get the marker and body as parameters.
60
- def match_all(str)
61
- str.scan(@org_emphasis_regexp) do |match|
62
- yield $2, $3
63
- end
64
- end
65
- #+end_src
66
-
67
- #+begin_src clojure
68
- (def fib-seq
69
- (concat
70
- [0 1]
71
- ((fn rfib [a b]
72
- (lazy-cons (+ a b) (rfib b (+ a b)))) 0 1)))
73
-
74
- user> (take 20 fib-seq)
75
- (0 1 1 2 3 5 8 13 21 34 55 89 144 233 377 610 987 1597 2584 4181)
76
- #+end_src
77
-
78
- Even if no language is set, it is still wrapped in code tags but class is empty.
79
-
80
- #+BEGIN_SRC
81
- echo 'Defaults env_keeps="http_proxy https_proxy ftp_proxy"' | sudo tee -a /etc/sudoers
82
- #+END_SRC
83
-
84
- * It should be possible to write a colon at the beginning of an example
85
-
86
- #+BEGIN_QUOTE
87
- I really love to write about
88
- :symbols. They sure are the
89
- best things in the world!
90
- #+END_QUOTE
91
-
92
- #+BEGIN_SRC ruby
93
- {
94
- :one => 1,
95
- :two => 2
96
- }
97
- #+END_SRC
98
-
99
- #+BEGIN_SRC clojure
100
- (defproject helloworld "0.1"
101
- :dependencies [[org.clojure/clojure
102
- "1.1.0-master-SNAPSHOT"]
103
- [org.clojure/clojure-contrib
104
- "1.0-SNAPSHOT"]]
105
- :main helloworld)
106
- #+END_SRC
@@ -1,31 +0,0 @@
1
- <p class="title">Advanced Lists</p>
2
- <p><code>org-ruby</code> supports the following list features of <code>org-mode</code>:</p>
3
- <h1>Nested lists</h1>
4
- <ul>
5
- <li>You can have nested lists</li>
6
- <li>This is first-level</li>
7
- <ul>
8
- <li>This is a nested item</li>
9
- <li>This is another nested item</li>
10
- </ul>
11
- <li>Back to the first level</li>
12
- <li>Another first level item</li>
13
- <ol>
14
- <li>This is a numbered list nested within the unordered list</li>
15
- <li>This is another numbered item</li>
16
- </ol>
17
- </ul>
18
- <p>Note the list ends just some more text. Make sure both list blocks are closed.</p>
19
- <h1>Multi-paragraph list items</h1>
20
- <p>This list will end with the end-of-file. Make sure all blocks are closed.</p>
21
- <ul>
22
- <li>This is a list item</li>
23
- <li>This list item has multiple paragraphs.</li>
24
- <p>This is paragraph two.</p>
25
- <p>And paragraph three.</p>
26
- <li>Back to a list item.</li>
27
- <ul>
28
- <li>Nested, just for grins!</li>
29
- <li>woo hoo!</li>
30
- </ul>
31
- </ul>
@@ -1,31 +0,0 @@
1
- Advanced Lists
2
-
3
- =org-ruby= supports the following list features of =org-mode=:
4
-
5
- * Nested lists
6
-
7
- - You can have nested lists
8
- - This is first-level
9
- - This is a nested item
10
- - This is another nested item
11
- - Back to the first level
12
- - Another first level item
13
- 1. This is a numbered list nested within the unordered list
14
- 2. This is another numbered item
15
-
16
- Note the list ends just some more text. Make sure both list blocks
17
- are closed.
18
-
19
- * Multi-paragraph list items
20
-
21
- This list will end with the end-of-file. Make sure all blocks are closed.
22
-
23
- - This is a list item
24
- - This list item has multiple paragraphs.
25
-
26
- This is paragraph two.
27
-
28
- And paragraph three.
29
- - Back to a list item.
30
- - Nested, just for grins!
31
- - woo hoo!
@@ -1,28 +0,0 @@
1
- <h1 class="title">Block Code</h1>
2
- <p>I need to get block code examples working. In <code>orgmode</code>, they look like this:</p>
3
- <pre class="example">
4
-
5
- def initialize(output)
6
- @output = output
7
- @buffer = ""
8
- @output_type = :start
9
- @list_indent_stack = []
10
- @paragraph_modifier = nil
11
-
12
- @logger = Logger.new(STDERR)
13
- @logger.level = Logger::WARN
14
- end
15
-
16
- </pre>
17
- <p>And now I should be back to normal text.</p>
18
- <p>Putting in another paragraph for good measure.</p>
19
- <p>Code should also get cancelled by a list, thus:</p>
20
- <pre class="example">
21
- This is my code!
22
-
23
- Another line!
24
- </pre>
25
- <ul>
26
- <li>My list should cancel this.</li>
27
- <li>Another list line.</li>
28
- </ul>
@@ -1,35 +0,0 @@
1
- * Block Code
2
-
3
- I need to get block code examples working. In =orgmode=, they look
4
- like this:
5
-
6
- #+BEGIN_EXAMPLE
7
-
8
- def initialize(output)
9
- @output = output
10
- @buffer = ""
11
- @output_type = :start
12
- @list_indent_stack = []
13
- @paragraph_modifier = nil
14
-
15
- @logger = Logger.new(STDERR)
16
- @logger.level = Logger::WARN
17
- end
18
-
19
- #+END_EXAMPLE
20
-
21
- And now I should be back to normal text.
22
-
23
- Putting in another paragraph for good measure.
24
-
25
-
26
- Code should also get cancelled by a list, thus:
27
-
28
- #+BEGIN_EXAMPLE
29
- This is my code!
30
-
31
- Another line!
32
- #+END_EXAMPLE
33
-
34
- - My list should cancel this.
35
- - Another list line.
@@ -1,3 +0,0 @@
1
- <p class="title">BLOCKCOMMENT</p>
2
- <p>Testing that the next part is ignored</p>
3
- <p>And now back to normal!</p>
@@ -1,15 +0,0 @@
1
- BLOCKCOMMENT
2
-
3
- Testing that the next part is ignored
4
-
5
- #+BEGIN_COMMENT
6
-
7
- /Foo/
8
-
9
- #+BEGIN_SRC c++
10
- int main() { }
11
- #+END_SRC
12
-
13
- #+END_COMMENT
14
-
15
- And now back to normal!