line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Pod::Simple::Wiki::Mediawiki; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
############################################################################### |
4
|
|
|
|
|
|
|
# |
5
|
|
|
|
|
|
|
# Pod::Simple::Wiki::Mediawiki - A class for creating Pod to MediaWiki filters. |
6
|
|
|
|
|
|
|
# |
7
|
|
|
|
|
|
|
# |
8
|
|
|
|
|
|
|
# Copyright 2003-2012, John McNamara, jmcnamara@cpan.org |
9
|
|
|
|
|
|
|
# |
10
|
|
|
|
|
|
|
# Documentation after __END__ |
11
|
|
|
|
|
|
|
# |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
# perltidy with the following options: -mbl=2 -pt=0 -nola |
14
|
|
|
|
|
|
|
|
15
|
9
|
|
|
9
|
|
46
|
use Pod::Simple::Wiki; |
|
9
|
|
|
|
|
16
|
|
|
9
|
|
|
|
|
270
|
|
16
|
9
|
|
|
9
|
|
45
|
use strict; |
|
9
|
|
|
|
|
16
|
|
|
9
|
|
|
|
|
216
|
|
17
|
9
|
|
|
9
|
|
41
|
use vars qw(@ISA $VERSION); |
|
9
|
|
|
|
|
14
|
|
|
9
|
|
|
|
|
13090
|
|
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
@ISA = qw(Pod::Simple::Wiki); |
21
|
|
|
|
|
|
|
$VERSION = '0.20'; |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
############################################################################### |
25
|
|
|
|
|
|
|
# |
26
|
|
|
|
|
|
|
# The tag to wiki mappings. |
27
|
|
|
|
|
|
|
# |
28
|
|
|
|
|
|
|
my $tags = { |
29
|
|
|
|
|
|
|
'' => "'''", |
30
|
|
|
|
|
|
|
'' => "'''", |
31
|
|
|
|
|
|
|
'' => "''", |
32
|
|
|
|
|
|
|
'' => "''", |
33
|
|
|
|
|
|
|
'' => '', |
34
|
|
|
|
|
|
|
'' => '', |
35
|
|
|
|
|
|
|
'' => "\n", |
36
|
|
|
|
|
|
|
'' => "\n\n", |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
'' => '==', |
39
|
|
|
|
|
|
|
'' => "==\n", |
40
|
|
|
|
|
|
|
'' => '===', |
41
|
|
|
|
|
|
|
'' => "===\n", |
42
|
|
|
|
|
|
|
'' => '====', |
43
|
|
|
|
|
|
|
'' => "====\n", |
44
|
|
|
|
|
|
|
'' => '=====', |
45
|
|
|
|
|
|
|
'' => "=====\n", |
46
|
|
|
|
|
|
|
}; |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
############################################################################### |
50
|
|
|
|
|
|
|
# |
51
|
|
|
|
|
|
|
# The default module options |
52
|
|
|
|
|
|
|
# |
53
|
|
|
|
|
|
|
my $default_opts = { |
54
|
|
|
|
|
|
|
transformer_lists => 0, |
55
|
|
|
|
|
|
|
link_prefix => 0, |
56
|
|
|
|
|
|
|
sentence_case_headers => 0, |
57
|
|
|
|
|
|
|
remove_name_section => 0, |
58
|
|
|
|
|
|
|
}; |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
############################################################################### |
62
|
|
|
|
|
|
|
# |
63
|
|
|
|
|
|
|
# new() |
64
|
|
|
|
|
|
|
# |
65
|
|
|
|
|
|
|
# Simple constructor inheriting from Pod::Simple::Wiki. |
66
|
|
|
|
|
|
|
# |
67
|
|
|
|
|
|
|
sub new { |
68
|
|
|
|
|
|
|
|
69
|
38
|
|
|
38
|
1
|
64
|
my $class = shift; |
70
|
38
|
|
|
|
|
67
|
my $opts = {}; |
71
|
|
|
|
|
|
|
|
72
|
38
|
100
|
|
|
|
105
|
if ( ref $_[-1] eq 'HASH' ) { |
73
|
7
|
|
|
|
|
12
|
$opts = pop @_; |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
# Merge custom tags with the default tags, if passed. |
76
|
|
|
|
|
|
|
$opts->{tags} = { |
77
|
|
|
|
|
|
|
%$tags, |
78
|
|
|
|
|
|
|
%{ |
79
|
7
|
|
|
|
|
36
|
exists $opts->{custom_tags} |
80
|
|
|
|
|
|
|
? delete $opts->{custom_tags} |
81
|
|
|
|
|
|
|
: {} |
82
|
7
|
100
|
|
|
|
73
|
} |
83
|
|
|
|
|
|
|
}; |
84
|
|
|
|
|
|
|
} |
85
|
|
|
|
|
|
|
else { |
86
|
31
|
|
|
|
|
69
|
$opts->{tags} = $tags; |
87
|
|
|
|
|
|
|
} |
88
|
|
|
|
|
|
|
|
89
|
38
|
|
|
|
|
185
|
$opts = { %$default_opts, %$opts }; |
90
|
|
|
|
|
|
|
|
91
|
38
|
|
|
|
|
233
|
my $self = Pod::Simple::Wiki->new( 'wiki', @_ ); |
92
|
38
|
|
|
|
|
157
|
$self->{_tags} = $opts->{tags}; |
93
|
38
|
|
|
|
|
68
|
$self->{_transformer_lists} = $opts->{transformer_lists}; |
94
|
38
|
|
|
|
|
113
|
$self->{_link_prefix} = $opts->{link_prefix}; |
95
|
38
|
|
|
|
|
58
|
$self->{_sentence_case_headers} = $opts->{sentence_case_headers}; |
96
|
38
|
|
|
|
|
63
|
$self->{_remove_name_section} = $opts->{remove_name_section}; |
97
|
|
|
|
|
|
|
|
98
|
38
|
|
|
|
|
61
|
bless $self, $class; |
99
|
|
|
|
|
|
|
|
100
|
38
|
|
|
|
|
166
|
$self->accept_targets( 'mediawiki' ); |
101
|
38
|
|
|
|
|
681
|
$self->nbsp_for_S( 1 ); |
102
|
|
|
|
|
|
|
|
103
|
38
|
|
|
|
|
346
|
return $self; |
104
|
|
|
|
|
|
|
} |
105
|
|
|
|
|
|
|
|
106
|
|
|
|
|
|
|
|
107
|
|
|
|
|
|
|
############################################################################### |
108
|
|
|
|
|
|
|
# |
109
|
|
|
|
|
|
|
# _append() |
110
|
|
|
|
|
|
|
# |
111
|
|
|
|
|
|
|
# Appends some text to the buffered Wiki text. |
112
|
|
|
|
|
|
|
# |
113
|
|
|
|
|
|
|
sub _append { |
114
|
|
|
|
|
|
|
|
115
|
190
|
|
|
190
|
|
241
|
my $self = shift; |
116
|
|
|
|
|
|
|
|
117
|
190
|
100
|
|
|
|
423
|
if ( $self->{_indent_text} ) { |
118
|
17
|
|
|
|
|
26
|
$self->{_wiki_text} .= $self->{_indent_text}; |
119
|
17
|
|
|
|
|
27
|
$self->{_indent_text} = ''; |
120
|
|
|
|
|
|
|
} |
121
|
|
|
|
|
|
|
|
122
|
190
|
|
|
|
|
599
|
$self->{_wiki_text} .= $_[0]; |
123
|
|
|
|
|
|
|
} |
124
|
|
|
|
|
|
|
|
125
|
|
|
|
|
|
|
|
126
|
|
|
|
|
|
|
############################################################################### |
127
|
|
|
|
|
|
|
# |
128
|
|
|
|
|
|
|
# _indent_item() |
129
|
|
|
|
|
|
|
# |
130
|
|
|
|
|
|
|
# Indents an "over-item" to the correct level. |
131
|
|
|
|
|
|
|
# |
132
|
|
|
|
|
|
|
sub _indent_item { |
133
|
|
|
|
|
|
|
|
134
|
51
|
|
|
51
|
|
64
|
my $self = shift; |
135
|
51
|
|
|
|
|
78
|
my $item_type = $_[0]; |
136
|
51
|
|
|
|
|
72
|
my $item_param = $_[1]; |
137
|
51
|
|
|
|
|
73
|
my $indent_level = $self->{_item_indent}; |
138
|
|
|
|
|
|
|
|
139
|
51
|
100
|
|
|
|
155
|
if ( $item_type eq 'bullet' ) { |
|
|
100
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
140
|
16
|
|
|
|
|
52
|
$self->_append( '*' x $indent_level . ' ' ); |
141
|
|
|
|
|
|
|
} |
142
|
|
|
|
|
|
|
elsif ( $item_type eq 'number' ) { |
143
|
16
|
|
|
|
|
51
|
$self->_append( '#' x $indent_level . ' ' ); |
144
|
|
|
|
|
|
|
} |
145
|
|
|
|
|
|
|
elsif ( $item_type eq 'text' ) { |
146
|
19
|
|
|
|
|
62
|
$self->_append( ':' x ( $indent_level - 1 ) . '; ' ); |
147
|
|
|
|
|
|
|
} |
148
|
|
|
|
|
|
|
} |
149
|
|
|
|
|
|
|
|
150
|
|
|
|
|
|
|
|
151
|
|
|
|
|
|
|
############################################################################### |
152
|
|
|
|
|
|
|
# |
153
|
|
|
|
|
|
|
# Functions to deal with links. |
154
|
|
|
|
|
|
|
|
155
|
|
|
|
|
|
|
sub _start_L { |
156
|
|
|
|
|
|
|
|
157
|
8
|
|
|
8
|
|
13
|
my ( $self, $attr ) = @_; |
158
|
|
|
|
|
|
|
|
159
|
8
|
50
|
|
|
|
31
|
if ( !$self->_skip_headings ) { |
160
|
8
|
|
|
|
|
22
|
$self->_append( '' ); # In case we have _indent_text pending |
161
|
|
|
|
|
|
|
# Flush the text buffer, so it will contain only the link text |
162
|
8
|
|
|
|
|
28
|
$self->_output; |
163
|
8
|
|
|
|
|
28
|
$self->{_link_attr} = $attr; # Save for later |
164
|
|
|
|
|
|
|
} |
165
|
|
|
|
|
|
|
} |
166
|
|
|
|
|
|
|
|
167
|
|
|
|
|
|
|
sub _end_L { |
168
|
|
|
|
|
|
|
|
169
|
8
|
|
|
8
|
|
11
|
my $self = $_[0]; |
170
|
|
|
|
|
|
|
|
171
|
8
|
|
|
|
|
14
|
my $attr = delete $self->{_link_attr}; |
172
|
|
|
|
|
|
|
|
173
|
8
|
50
|
33
|
|
|
55
|
if ( $attr and my $method = $self->can( '_format_link' ) ) { |
174
|
8
|
|
|
|
|
20
|
$self->{_wiki_text} = $method->( $self, $self->{_wiki_text}, $attr ); |
175
|
|
|
|
|
|
|
} |
176
|
|
|
|
|
|
|
} |
177
|
|
|
|
|
|
|
|
178
|
|
|
|
|
|
|
|
179
|
|
|
|
|
|
|
############################################################################### |
180
|
|
|
|
|
|
|
# |
181
|
|
|
|
|
|
|
# _format_link |
182
|
|
|
|
|
|
|
|
183
|
|
|
|
|
|
|
sub _format_link { |
184
|
|
|
|
|
|
|
|
185
|
8
|
|
|
8
|
|
17
|
my ( $self, $text, $attr ) = @_; |
186
|
|
|
|
|
|
|
|
187
|
8
|
100
|
|
|
|
21
|
if ( $attr->{type} eq 'url' ) { |
188
|
3
|
|
|
|
|
6
|
my $link = $attr->{to}; |
189
|
|
|
|
|
|
|
|
190
|
3
|
100
|
|
|
|
10
|
return $link if $attr->{'content-implicit'}; |
191
|
2
|
|
|
|
|
7
|
return "[$link $text]"; |
192
|
|
|
|
|
|
|
} |
193
|
|
|
|
|
|
|
|
194
|
|
|
|
|
|
|
# Manpage: |
195
|
5
|
50
|
|
|
|
15
|
if ( $attr->{type} eq 'man' ) { |
196
|
|
|
|
|
|
|
|
197
|
|
|
|
|
|
|
# FIXME link to http://www.linuxmanpages.com? |
198
|
0
|
0
|
|
|
|
0
|
return "$text" if $attr->{'content-implicit'}; |
199
|
0
|
|
|
|
|
0
|
return "$text ($attr->{to})"; |
200
|
|
|
|
|
|
|
} |
201
|
|
|
|
|
|
|
|
202
|
5
|
50
|
|
|
|
13
|
die "Unknown link type $attr->{type}" unless $attr->{type} eq 'pod'; |
203
|
|
|
|
|
|
|
|
204
|
|
|
|
|
|
|
# Handle a link within this page: |
205
|
5
|
100
|
|
|
|
16
|
return "[[#$attr->{section}|$text]]" unless defined $attr->{to}; |
206
|
|
|
|
|
|
|
|
207
|
|
|
|
|
|
|
# Handle a link to a specific section in another page: |
208
|
4
|
100
|
|
|
|
13
|
if ( defined $attr->{section} ) { |
209
|
|
|
|
|
|
|
return $self->{_link_prefix} |
210
|
2
|
100
|
|
|
|
12
|
? "[$self->{_link_prefix}$attr->{to}#$attr->{section} $text]" |
211
|
|
|
|
|
|
|
: "[[$attr->{to}#$attr->{section}|$text]]"; |
212
|
|
|
|
|
|
|
} |
213
|
|
|
|
|
|
|
|
214
|
2
|
50
|
|
|
|
5
|
if ( $attr->{'content-implicit'} ) { |
215
|
|
|
|
|
|
|
return $self->{_link_prefix} |
216
|
2
|
100
|
|
|
|
15
|
? "[$self->{_link_prefix}$attr->{to} $attr->{to}]" |
217
|
|
|
|
|
|
|
: "[[$attr->{to}]]"; |
218
|
|
|
|
|
|
|
} |
219
|
|
|
|
|
|
|
|
220
|
0
|
|
|
|
|
0
|
return "[[$attr->{to}|$text]]"; |
221
|
|
|
|
|
|
|
} |
222
|
|
|
|
|
|
|
|
223
|
|
|
|
|
|
|
|
224
|
|
|
|
|
|
|
############################################################################### |
225
|
|
|
|
|
|
|
# |
226
|
|
|
|
|
|
|
# _handle_text() |
227
|
|
|
|
|
|
|
# |
228
|
|
|
|
|
|
|
# Perform any necessary transforms on the text. This is mainly used to escape |
229
|
|
|
|
|
|
|
# inadvertent CamelCase words. |
230
|
|
|
|
|
|
|
# |
231
|
|
|
|
|
|
|
sub _handle_text { |
232
|
|
|
|
|
|
|
|
233
|
97
|
|
|
97
|
|
728
|
my $self = shift; |
234
|
97
|
|
|
|
|
138
|
my $text = $_[0]; |
235
|
|
|
|
|
|
|
|
236
|
97
|
100
|
|
|
|
224
|
if ( $self->{_sentence_case_headers} ) { |
237
|
2
|
50
|
|
|
|
6
|
if ( $self->{_in_head1} ) { |
238
|
2
|
|
|
|
|
5
|
$text = ucfirst( lc( $text ) ); |
239
|
|
|
|
|
|
|
} |
240
|
|
|
|
|
|
|
} |
241
|
|
|
|
|
|
|
|
242
|
97
|
50
|
|
|
|
217
|
if ( !$self->{_in_Data} ) { |
243
|
|
|
|
|
|
|
|
244
|
|
|
|
|
|
|
# Escape colons in definition lists: |
245
|
97
|
100
|
|
|
|
209
|
if ( $self->{_in_item_text} ) { |
246
|
19
|
|
|
|
|
37
|
$text =~ s/:/:/g; # A colon would end the item |
247
|
|
|
|
|
|
|
} |
248
|
|
|
|
|
|
|
|
249
|
|
|
|
|
|
|
# Escape empty lines in verbatim sections: |
250
|
97
|
100
|
|
|
|
202
|
if ( $self->{_in_Verbatim} ) { |
251
|
1
|
|
|
|
|
2
|
$text =~ s/^$/ /mg; # An empty line would split the section |
252
|
|
|
|
|
|
|
} |
253
|
|
|
|
|
|
|
|
254
|
97
|
|
|
|
|
142
|
$text =~ s/\xA0/ /g; # Convert non-breaking spaces to entities |
255
|
|
|
|
|
|
|
|
256
|
97
|
|
|
|
|
137
|
$text =~ s/''/''/g; # It's not a formatting code |
257
|
|
|
|
|
|
|
|
258
|
97
|
|
|
|
|
141
|
$text =~ s/\xA9/©/g; # Convert copyright symbols to entities |
259
|
|
|
|
|
|
|
} |
260
|
|
|
|
|
|
|
|
261
|
97
|
|
|
|
|
189
|
$self->_append( $text ); |
262
|
|
|
|
|
|
|
} |
263
|
|
|
|
|
|
|
|
264
|
|
|
|
|
|
|
|
265
|
|
|
|
|
|
|
############################################################################### |
266
|
|
|
|
|
|
|
# |
267
|
|
|
|
|
|
|
# Functions to deal with =over ... =back regions for |
268
|
|
|
|
|
|
|
# |
269
|
|
|
|
|
|
|
# Bulleted lists |
270
|
|
|
|
|
|
|
# Numbered lists |
271
|
|
|
|
|
|
|
# Text lists |
272
|
|
|
|
|
|
|
# Block lists |
273
|
|
|
|
|
|
|
# |
274
|
|
|
|
19
|
|
|
sub _end_item_text { } # _start_Para will insert the : |
275
|
|
|
|
|
|
|
|
276
|
|
|
|
|
|
|
|
277
|
|
|
|
|
|
|
############################################################################### |
278
|
|
|
|
|
|
|
# |
279
|
|
|
|
|
|
|
# _start_Para() |
280
|
|
|
|
|
|
|
# |
281
|
|
|
|
|
|
|
# Special handling for paragraphs that are part of an "over" block. |
282
|
|
|
|
|
|
|
# |
283
|
|
|
|
|
|
|
sub _start_Para { |
284
|
|
|
|
|
|
|
|
285
|
34
|
|
|
34
|
|
47
|
my $self = shift; |
286
|
34
|
|
|
|
|
53
|
my $indent_level = $self->{_item_indent}; |
287
|
|
|
|
|
|
|
|
288
|
34
|
100
|
|
|
|
85
|
if ( $self->{_in_over_block} ) { |
289
|
1
|
|
|
|
|
3
|
$self->{_indent_text} = ( ':' x $indent_level ); |
290
|
|
|
|
|
|
|
} |
291
|
|
|
|
|
|
|
|
292
|
34
|
100
|
|
|
|
79
|
if ( $self->{_in_over_text} ) { |
293
|
16
|
|
|
|
|
36
|
$self->{_indent_text} = "\n" . ( ':' x $indent_level ); |
294
|
|
|
|
|
|
|
} |
295
|
|
|
|
|
|
|
|
296
|
34
|
100
|
|
|
|
125
|
if ( $self->{_transformer_lists} ) { |
297
|
2
|
50
|
33
|
|
|
7
|
if ( $self->{_in_over_bullet} || $self->{_in_over_number} ) { |
298
|
2
|
50
|
|
|
|
5
|
if ( $self->{output_string} ) { |
299
|
2
|
|
|
|
|
2
|
chomp( ${ $self->{output_string} } ); |
|
2
|
|
|
|
|
6
|
|
300
|
|
|
|
|
|
|
} |
301
|
2
|
|
|
|
|
6
|
$self->{_indent_text} = " "; |
302
|
|
|
|
|
|
|
} |
303
|
|
|
|
|
|
|
} |
304
|
|
|
|
|
|
|
} |
305
|
|
|
|
|
|
|
|
306
|
|
|
|
|
|
|
|
307
|
|
|
|
|
|
|
############################################################################### |
308
|
|
|
|
|
|
|
# |
309
|
|
|
|
|
|
|
# _end_Para() |
310
|
|
|
|
|
|
|
# |
311
|
|
|
|
|
|
|
# Special handling for paragraphs that are part of an "over_text" block. |
312
|
|
|
|
|
|
|
# |
313
|
|
|
|
|
|
|
sub _end_Para { |
314
|
|
|
|
|
|
|
|
315
|
34
|
|
|
34
|
|
45
|
my $self = shift; |
316
|
|
|
|
|
|
|
|
317
|
|
|
|
|
|
|
# Only add a newline if the paragraph isn't part of a text |
318
|
34
|
100
|
0
|
|
|
115
|
if ( $self->{_in_over_text} ) { |
|
|
50
|
33
|
|
|
|
|
319
|
|
|
|
|
|
|
|
320
|
|
|
|
|
|
|
# Do nothing in this format. |
321
|
|
|
|
|
|
|
} |
322
|
|
|
|
|
|
|
elsif ( $self->{_transformer_lists} |
323
|
|
|
|
|
|
|
&& ( $self->{_in_over_bullet} || $self->{_in_over_number} ) ) |
324
|
|
|
|
|
|
|
{ |
325
|
|
|
|
|
|
|
|
326
|
0
|
|
|
|
|
0
|
$self->_output( "\n" ); |
327
|
|
|
|
|
|
|
} |
328
|
|
|
|
|
|
|
else { |
329
|
18
|
|
|
|
|
52
|
$self->_output( "\n" ); |
330
|
|
|
|
|
|
|
} |
331
|
|
|
|
|
|
|
|
332
|
34
|
100
|
66
|
|
|
142
|
if ( !$self->{_transformer_lists} |
333
|
|
|
|
|
|
|
|| ( !$self->{_in_over_bullet} && !$self->{_in_over_number} ) ) |
334
|
|
|
|
|
|
|
{ |
335
|
|
|
|
|
|
|
|
336
|
32
|
|
|
|
|
81
|
$self->_output( "\n" ); |
337
|
|
|
|
|
|
|
} |
338
|
|
|
|
|
|
|
} |
339
|
|
|
|
|
|
|
|
340
|
|
|
|
|
|
|
|
341
|
|
|
|
|
|
|
###################################################################### |
342
|
|
|
|
|
|
|
# |
343
|
|
|
|
|
|
|
# _end_Data |
344
|
|
|
|
|
|
|
# |
345
|
|
|
|
|
|
|
# Special handling for data paragraphs |
346
|
|
|
|
|
|
|
|
347
|
0
|
|
|
0
|
|
0
|
sub _end_Data { $_[0]->_output( "\n\n" ) } |
348
|
|
|
|
|
|
|
|
349
|
|
|
|
|
|
|
|
350
|
|
|
|
|
|
|
############################################################################### |
351
|
|
|
|
|
|
|
# |
352
|
|
|
|
|
|
|
# parse_string_document() |
353
|
|
|
|
|
|
|
# |
354
|
|
|
|
|
|
|
# Optional overriding of Pod::Simple method to remove the "NAME" section |
355
|
|
|
|
|
|
|
# |
356
|
|
|
|
|
|
|
sub parse_string_document { |
357
|
|
|
|
|
|
|
|
358
|
38
|
|
|
38
|
1
|
27979
|
my $self = shift; |
359
|
|
|
|
|
|
|
|
360
|
38
|
|
|
|
|
205
|
$self = $self->SUPER::parse_string_document( @_ ); |
361
|
|
|
|
|
|
|
|
362
|
38
|
100
|
|
|
|
466
|
if ( $self->{_remove_name_section} ) { |
363
|
9
|
|
|
9
|
|
55
|
no warnings 'uninitialized'; |
|
9
|
|
|
|
|
17
|
|
|
9
|
|
|
|
|
1489
|
|
364
|
1
|
|
|
|
|
2
|
${ $self->{output_string} } =~ |
|
1
|
|
|
|
|
9
|
|
365
|
1
|
50
|
|
|
|
7
|
s/^==\s*NAME\s*==\n(?:[\w:]+)(?: - (.*))*/$1||''/iesg; |
366
|
|
|
|
|
|
|
} |
367
|
|
|
|
|
|
|
|
368
|
38
|
|
|
|
|
79
|
return $self; |
369
|
|
|
|
|
|
|
} |
370
|
|
|
|
|
|
|
|
371
|
|
|
|
|
|
|
1; |
372
|
|
|
|
|
|
|
|
373
|
|
|
|
|
|
|
|
374
|
|
|
|
|
|
|
__END__ |