File tree Expand file tree Collapse file tree 2 files changed +27
-27
lines changed Expand file tree Collapse file tree 2 files changed +27
-27
lines changed Original file line number Diff line number Diff line change @@ -32,13 +32,13 @@ def hidden?
32
32
33
33
def heading
34
34
regex = case @format
35
- when :mdown , :md
36
- /^#\s *(.*?)(\s *#+|$)/
37
- when :haml
38
- /^\s *%h1\s +(.*)/
39
- when :textile
40
- /^\s *h1\. \s +(.*)/
41
- end
35
+ when :mdown , :md
36
+ /^#\s *(.*?)(\s *#+|$)/
37
+ when :haml
38
+ /^\s *%h1\s +(.*)/
39
+ when :textile
40
+ /^\s *h1\. \s +(.*)/
41
+ end
42
42
markup =~ regex
43
43
Regexp . last_match ( 1 ) or raise HeadingNotSet , "#{ abspath } needs a heading"
44
44
end
@@ -83,12 +83,12 @@ def summary
83
83
84
84
def body_markup
85
85
case @format
86
- when :mdown , :md
87
- markup . sub ( /^#[^#].*$\r ?\n (\r ?\n )?/ , '' )
88
- when :haml
89
- markup . sub ( /^\s *%h1\s +.*$\r ?\n (\r ?\n )?/ , '' )
90
- when :textile
91
- markup . sub ( /^\s *h1\. \s +.*$\r ?\n (\r ?\n )?/ , '' )
86
+ when :mdown , :md
87
+ markup . sub ( /^#[^#].*$\r ?\n (\r ?\n )?/ , '' )
88
+ when :haml
89
+ markup . sub ( /^\s *%h1\s +.*$\r ?\n (\r ?\n )?/ , '' )
90
+ when :textile
91
+ markup . sub ( /^\s *h1\. \s +.*$\r ?\n (\r ?\n )?/ , '' )
92
92
end
93
93
end
94
94
Original file line number Diff line number Diff line change @@ -132,20 +132,20 @@ OPTIONS (defaults shown in brackets)
132
132
opt , arg = parser . get
133
133
break if not opt
134
134
case opt
135
- when '-a'
136
- @adapter = arg
137
- when '--domain'
138
- @domain = arg
139
- when '--clobber'
140
- @clobber = true
141
- when '-d'
142
- @database = arg
143
- when '-h'
144
- @host = arg
145
- when '-p'
146
- @password = arg
147
- when '-u'
148
- @username = arg
135
+ when '-a'
136
+ @adapter = arg
137
+ when '--domain'
138
+ @domain = arg
139
+ when '--clobber'
140
+ @clobber = true
141
+ when '-d'
142
+ @database = arg
143
+ when '-h'
144
+ @host = arg
145
+ when '-p'
146
+ @password = arg
147
+ when '-u'
148
+ @username = arg
149
149
end
150
150
end
151
151
@adapter ||= 'mysql'
You can’t perform that action at this time.
0 commit comments