diff options
author | Colin Guthrie <colin@mageia.org> | 2014-11-25 09:15:50 +0000 |
---|---|---|
committer | Colin Guthrie <colin@mageia.org> | 2014-11-25 10:31:47 +0000 |
commit | 55c1077bc19f5cf5b59ab74d1b6f9daa2d1fbed0 (patch) | |
tree | 16194f4e17404ff50e8c46919e28816f784f1ef2 /lib | |
parent | c0627ebbb288b3a448350f7b66f54f85b3e19961 (diff) | |
download | mgaadvisories-55c1077bc19f5cf5b59ab74d1b6f9daa2d1fbed0.tar mgaadvisories-55c1077bc19f5cf5b59ab74d1b6f9daa2d1fbed0.tar.gz mgaadvisories-55c1077bc19f5cf5b59ab74d1b6f9daa2d1fbed0.tar.bz2 mgaadvisories-55c1077bc19f5cf5b59ab74d1b6f9daa2d1fbed0.tar.xz mgaadvisories-55c1077bc19f5cf5b59ab74d1b6f9daa2d1fbed0.zip |
Ensure we're in the advisory dir before running svn commands.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/MGA/Advisories.pm | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/MGA/Advisories.pm b/lib/MGA/Advisories.pm index d29d706..2d84aac 100644 --- a/lib/MGA/Advisories.pm +++ b/lib/MGA/Advisories.pm @@ -197,7 +197,8 @@ sub next_id { sub assign_id { my ($advname) = @_; - my $advfile = "$config->{advisories_dir}/$advname.adv"; + chdir($config->{advisories_dir}); + my $advfile = "$advname.adv"; $advfile =~ s/\.adv\.adv$/.adv/; if ( ! -f $advfile ) { @@ -412,7 +413,7 @@ sub assign_id { } } $message .= ': '.join(', ', @pkgs); - $exitstatus = system(('svn', 'commit', '-q', '-m', $message, $advfile)); + $exitstatus = system('svn', 'commit', '-q', '-m', $message, $advfile); if (0 == $exitstatus) { print "✔\n"; } else { @@ -421,6 +422,7 @@ sub assign_id { } sub assign_ids { + chdir($config->{advisories_dir}); # Ensure users local repo is up to date my $exitstatus = system("svn up"); if ( 0 != $exitstatus ) { |