line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Command::Runner::Quote; |
2
|
13
|
|
|
13
|
|
93
|
use strict; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
402
|
|
3
|
13
|
|
|
13
|
|
66
|
use warnings; |
|
13
|
|
|
|
|
34
|
|
|
13
|
|
|
|
|
306
|
|
4
|
|
|
|
|
|
|
|
5
|
13
|
|
|
13
|
|
6325
|
use Win32::ShellQuote (); |
|
13
|
|
|
|
|
19983
|
|
|
13
|
|
|
|
|
287
|
|
6
|
13
|
|
|
13
|
|
5802
|
use String::ShellQuote (); |
|
13
|
|
|
|
|
11038
|
|
|
13
|
|
|
|
|
368
|
|
7
|
|
|
|
|
|
|
|
8
|
13
|
|
|
13
|
|
96
|
use Exporter 'import'; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
1669
|
|
9
|
|
|
|
|
|
|
our @EXPORT_OK = qw(quote quote_win32 quote_unix); |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub quote_win32 { |
12
|
0
|
|
|
0
|
0
|
0
|
my $str = shift; |
13
|
0
|
|
|
|
|
0
|
Win32::ShellQuote::quote_literal($str, 1); |
14
|
|
|
|
|
|
|
} |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
sub quote_unix { |
17
|
26
|
|
|
26
|
0
|
57
|
my $str = shift; |
18
|
26
|
|
|
|
|
115
|
String::ShellQuote::shell_quote_best_effort($str); |
19
|
|
|
|
|
|
|
} |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
if ($^O eq 'MSWin32') { |
22
|
|
|
|
|
|
|
*quote = \"e_win32; |
23
|
|
|
|
|
|
|
} else { |
24
|
|
|
|
|
|
|
*quote = \"e_unix; |
25
|
|
|
|
|
|
|
} |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
1; |