diff options
author | Rafael Garcia-Suarez <rgarciasuarez@mandriva.org> | 2005-11-17 10:11:58 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@mandriva.org> | 2005-11-17 10:11:58 +0000 |
commit | a808b6fddad0ac1df34a0ac7198644ee5ab98de1 (patch) | |
tree | 21cafb58821bfe321928646c940761336434085b | |
parent | 476e99a5bf82b9aab2dcf276829faee13e93b97b (diff) | |
download | urpmi-a808b6fddad0ac1df34a0ac7198644ee5ab98de1.tar urpmi-a808b6fddad0ac1df34a0ac7198644ee5ab98de1.tar.gz urpmi-a808b6fddad0ac1df34a0ac7198644ee5ab98de1.tar.bz2 urpmi-a808b6fddad0ac1df34a0ac7198644ee5ab98de1.tar.xz urpmi-a808b6fddad0ac1df34a0ac7198644ee5ab98de1.zip |
Add VERSION in parallel modules
-rw-r--r-- | urpm/parallel_ka_run.pm | 17 | ||||
-rw-r--r-- | urpm/parallel_ssh.pm | 6 |
2 files changed, 13 insertions, 10 deletions
diff --git a/urpm/parallel_ka_run.pm b/urpm/parallel_ka_run.pm index 6e073134..17e47800 100644 --- a/urpm/parallel_ka_run.pm +++ b/urpm/parallel_ka_run.pm @@ -2,6 +2,7 @@ package urpm::parallel_ka_run; use strict; +(our $VERSION) = q$Id$ =~ /(\d+\.\d+)/; our $mput_command = 'mput'; our $rshp_command = 'rshp'; @@ -233,15 +234,15 @@ sub parallel_install { } } -#- allow bootstrap from urpmi code directly (namespace is urpm). +#- allow to bootstrap from urpmi code directly (namespace is urpm). + package urpm; + sub handle_parallel_options { my ($urpm, $options) = @_; my ($media, $ka_run_options) = $options =~ /ka-run(?:\(([^\)]*)\))?:(.*)/; - if ($ka_run_options) { my ($flush_nodes, %nodes); - foreach (split ' ', $ka_run_options) { if ($_ eq '-m') { $flush_nodes = 1; @@ -250,14 +251,12 @@ sub handle_parallel_options { undef $flush_nodes; } } - return bless { - media => $media, - options => $ka_run_options, - nodes => \%nodes, - }, "urpm::parallel_ka_run"; + media => $media, + options => $ka_run_options, + nodes => \%nodes, + }, "urpm::parallel_ka_run"; } - return undef; } diff --git a/urpm/parallel_ssh.pm b/urpm/parallel_ssh.pm index b95cc3ec..088804c6 100644 --- a/urpm/parallel_ssh.pm +++ b/urpm/parallel_ssh.pm @@ -3,6 +3,8 @@ package urpm::parallel_ssh; use strict; use Time::HiRes qw(gettimeofday); +(our $VERSION) = q$Id$ =~ /(\d+\.\d+)/; + sub _localhost { $_[0] eq 'localhost' } sub _nolock { &_localhost ? '--nolock ' : '' } sub _ssh { &_localhost ? '' : "ssh $_[0] " } @@ -278,8 +280,10 @@ sub parallel_install { } } -#- allow bootstrap from urpmi code directly (namespace is urpm). +#- allow to bootstrap from urpmi code directly (namespace is urpm). + package urpm; + sub handle_parallel_options { my (undef, $options) = @_; my ($id, @nodes) = split /:/, $options; |