[DRE-commits] [ruby-org] 181/303: Asterisk can also be used for bullet lists (Fixes #29)
Jérémy Bobbio
lunar at alioth.debian.org
Fri Aug 9 17:33:53 UTC 2013
This is an automated email from the git hooks/post-receive script.
lunar pushed a commit to branch master
in repository ruby-org.
commit 958262e18cd443f049ee60ddae7007045040efa5
Author: Waldemar Quevedo <waldemar.quevedo at gmail.com>
Date: Sun Aug 26 16:03:23 2012 +0900
Asterisk can also be used for bullet lists (Fixes #29)
---
lib/org-ruby/line.rb | 4 ++--
spec/html_examples/advanced-lists.html | 31 +++++++++++++++++++++++++++++++
spec/html_examples/advanced-lists.org | 15 +++++++++++++++
spec/html_examples/deflist.html | 6 ++++++
spec/html_examples/deflist.org | 6 ++++++
5 files changed, 60 insertions(+), 2 deletions(-)
diff --git a/lib/org-ruby/line.rb b/lib/org-ruby/line.rb
index d771568..564666a 100644
--- a/lib/org-ruby/line.rb
+++ b/lib/org-ruby/line.rb
@@ -78,7 +78,7 @@ module Orgmode
ordered_list? or unordered_list? or definition_list?
end
- UnorderedListRegexp = /^\s*(-|\+)\s+/
+ UnorderedListRegexp = /^\s*(-|\+|\s+[*])\s+/
def unordered_list?
check_assignment_or_regexp(:unordered_list, UnorderedListRegexp)
@@ -88,7 +88,7 @@ module Orgmode
@line.sub(UnorderedListRegexp, "")
end
- DefinitionListRegexp = /^\s*(-|\+)\s*(.*?)::/
+ DefinitionListRegexp = /^\s*(-|\+|\s+[*])\s*(.*?)::/
def definition_list?
check_assignment_or_regexp(:definition_list, DefinitionListRegexp)
diff --git a/spec/html_examples/advanced-lists.html b/spec/html_examples/advanced-lists.html
index 15b0c34..26d033e 100644
--- a/spec/html_examples/advanced-lists.html
+++ b/spec/html_examples/advanced-lists.html
@@ -42,3 +42,34 @@
</ul>
</li>
</ul>
+<h1>Hyphen, Plus and Asterisk can be used to create lists</h1>
+<ul>
+ <li>One
+ <ul>
+ <li>uno
+ <ul>
+ <li>ichi
+ </li>
+ </ul>
+ </li>
+ <li>uno
+ </li>
+ </ul>
+ </li>
+ <li>Two
+ <ul>
+ <li>dos
+ <ul>
+ <li>ni
+ </li>
+ <li>ni
+ </li>
+ </ul>
+ </li>
+ </ul>
+ </li>
+ <li>Three
+ </li>
+ <li>Four
+ </li>
+</ul>
diff --git a/spec/html_examples/advanced-lists.org b/spec/html_examples/advanced-lists.org
index 0bbea79..f03ead6 100644
--- a/spec/html_examples/advanced-lists.org
+++ b/spec/html_examples/advanced-lists.org
@@ -29,3 +29,18 @@ Advanced Lists
- Back to a list item.
- Nested, just for grins!
- woo hoo!
+
+* Hyphen, Plus and Asterisk can be used to create lists
+
+- One
+ * uno
+ + ichi
+ * uno
+- Two
+ + dos
+ * ni
+ * ni
+- Three
+- Four
+
+
diff --git a/spec/html_examples/deflist.html b/spec/html_examples/deflist.html
index fed5872..c68df35 100644
--- a/spec/html_examples/deflist.html
+++ b/spec/html_examples/deflist.html
@@ -4,3 +4,9 @@
<dt>b</dt><dd>world</dd>
</dl>
<p>Text</p>
+<h1>Asterisk can be used for lists</h1>
+<dl>
+ <dt>One</dt><dd>The first number.</dd>
+ <dt>Two</dt><dd>The second number.</dd>
+ <dt>Three</dt><dd>The second number.</dd>
+</dl>
diff --git a/spec/html_examples/deflist.org b/spec/html_examples/deflist.org
index 1b40a1f..5ca4113 100644
--- a/spec/html_examples/deflist.org
+++ b/spec/html_examples/deflist.org
@@ -4,3 +4,9 @@
- b :: world
Text
+
+* Asterisk can be used for lists
+
+ * One :: The first number.
+ * Two :: The second number.
+ * Three :: The second number.
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/ruby-org.git
More information about the Pkg-ruby-extras-commits
mailing list