Hello, I found out that if I make a mistake in a branch or commit expression in the feeds.conf file the updating procedure fails silently. This patch fixes this behavior and returns error code 1 if something went wrong.
Best Regards, Martin Strba??ka Signed-off-by: Martin Strbacka <martin.strba...@nic.cz> --- scripts/feeds | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/scripts/feeds b/scripts/feeds index 89cb5a2..ece9bb0 100755 --- a/scripts/feeds +++ b/scripts/feeds @@ -687,6 +687,7 @@ sub update { my %opts; my $feed_name; my $perform_update=1; + my $failed=0; $ENV{SCAN_COOKIE} = $$; $ENV{OPENWRT_VERBOSE} = 's'; @@ -711,8 +712,10 @@ sub update { if ( ($#ARGV == -1) or $opts{a}) { foreach my $feed (@feeds) { my ($type, $name, $src) = @$feed; - next unless update_feed($type, $name, $src, $perform_update) == 1; - last; + if(update_feed($type, $name, $src, $perform_update) == 1) { + $failed=1; + last; + } } } else { while ($feed_name = shift @ARGV) { @@ -721,14 +724,13 @@ sub update { if($feed_name ne $name) { next; } - update_feed($type, $name, $src, $perform_update); + update_feed($type, $name, $src, $perform_update) == 0 or $failed=1; } } } refresh_config(); - - return 0; + return $failed; } sub feed_config() { -- 1.9.1
_______________________________________________ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel