aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Pipkin <j@dawnrazor.net>2012-10-03 03:55:38 -0500
committerJacob Pipkin <j@dawnrazor.net>2012-10-03 03:55:38 -0500
commit0af02e57b6fbfd559a48ba0061245e6148d12814 (patch)
treea7decf3a0d34d6219c8a3251301329a66037f4d4
parent1354c09e1b93567ef309ffe0f966cd0de00cf95f (diff)
downloadsbotools2-0af02e57b6fbfd559a48ba0061245e6148d12814.tar.xz
when circular reqs are found, advise the user of the situation and ask whether or not proceed, default no
-rwxr-xr-xsboupgrade7
1 files changed, 6 insertions, 1 deletions
diff --git a/sboupgrade b/sboupgrade
index 544ae92..406ac4a 100755
--- a/sboupgrade
+++ b/sboupgrade
@@ -133,7 +133,12 @@ sub get_requires ($$) {
FIRST: for my $req (@$requires) {
my $req_req = get_from_info (LOCATION => get_sbo_location $req,
GET => 'REQUIRES');
- return if $sbo ~~ @$req_req;
+ if ($sbo ~~ @$req_req) {
+ say "I am seeing circular requirements between $sbo and $req.";
+ say "Therefore, I am not going to handle requirements for $sbo.";
+ print 'Do you still wish to proceed? [n] ';
+ <STDIN> ~ /^[Yy\n]/ ? return : exit 0;
+ }
}
return $requires;
}