line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
# |
2
|
|
|
|
|
|
|
# $Id$ |
3
|
|
|
|
|
|
|
# |
4
|
|
|
|
|
|
|
# devel::subversion Brik |
5
|
|
|
|
|
|
|
# |
6
|
|
|
|
|
|
|
package Metabrik::Devel::Subversion; |
7
|
1
|
|
|
1
|
|
727
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
29
|
|
8
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
28
|
|
9
|
|
|
|
|
|
|
|
10
|
1
|
|
|
1
|
|
6
|
use base qw(Metabrik::Shell::Command Metabrik::System::Package); |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
330
|
|
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
sub brik_properties { |
13
|
|
|
|
|
|
|
return { |
14
|
0
|
|
|
0
|
1
|
|
revision => '$Revision$', |
15
|
|
|
|
|
|
|
tags => [ qw(unstable svn) ], |
16
|
|
|
|
|
|
|
author => 'GomoR ', |
17
|
|
|
|
|
|
|
license => 'http://opensource.org/licenses/BSD-3-Clause', |
18
|
|
|
|
|
|
|
attributes => { |
19
|
|
|
|
|
|
|
datadir => [ qw(datadir) ], |
20
|
|
|
|
|
|
|
}, |
21
|
|
|
|
|
|
|
commands => { |
22
|
|
|
|
|
|
|
install => [ ], # Inherited |
23
|
|
|
|
|
|
|
checkout => [ qw(repository directory|OPTIONAL) ], |
24
|
|
|
|
|
|
|
clone => [ qw(repository directory|OPTIONAL) ], |
25
|
|
|
|
|
|
|
}, |
26
|
|
|
|
|
|
|
require_binaries => { |
27
|
|
|
|
|
|
|
'svn' => [ ], |
28
|
|
|
|
|
|
|
}, |
29
|
|
|
|
|
|
|
need_packages => { |
30
|
|
|
|
|
|
|
ubuntu => [ qw(subversion) ], |
31
|
|
|
|
|
|
|
debian => [ qw(subversion) ], |
32
|
|
|
|
|
|
|
kali => [ qw(subversion) ], |
33
|
|
|
|
|
|
|
}, |
34
|
|
|
|
|
|
|
}; |
35
|
|
|
|
|
|
|
} |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
sub checkout { |
38
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
39
|
0
|
|
|
|
|
|
my ($repository, $directory) = @_; |
40
|
|
|
|
|
|
|
|
41
|
0
|
|
0
|
|
|
|
$directory ||= ''; |
42
|
0
|
0
|
|
|
|
|
$self->brik_help_run_undef_arg('checkout', $repository) or return; |
43
|
|
|
|
|
|
|
|
44
|
0
|
|
|
|
|
|
my $cmd = "svn co $repository $directory"; |
45
|
0
|
0
|
|
|
|
|
$self->execute($cmd) or return; |
46
|
|
|
|
|
|
|
|
47
|
0
|
|
|
|
|
|
return $directory; |
48
|
|
|
|
|
|
|
} |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
# alias to checkout |
51
|
|
|
|
|
|
|
sub clone { |
52
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
53
|
|
|
|
|
|
|
|
54
|
0
|
|
|
|
|
|
return $self->checkout(@_); |
55
|
|
|
|
|
|
|
} |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
1; |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
__END__ |