chiark / gitweb /
Configuration: Break out access_cfg_cfgs
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 26 Jul 2015 18:49:19 +0000 (19:49 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 26 Jul 2015 18:55:31 +0000 (19:55 +0100)
dgit

diff --git a/dgit b/dgit
index de14f92bb7d7394f474b262ec470b19bb99bf7e7..4c6cc9c29124f9a145ad9b63a540cad68beca0ed 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -645,7 +645,7 @@ sub access_distros () {
     @l;
 }
 
     @l;
 }
 
-sub access_cfg (@) {
+sub access_cfg_cfgs (@) {
     my (@keys) = @_;
     my @cfgs;
     # The nesting of these loops determines the search order.  We put
     my (@keys) = @_;
     my @cfgs;
     # The nesting of these loops determines the search order.  We put
@@ -672,6 +672,12 @@ sub access_cfg (@) {
     }
     push @cfgs, map { "dgit.default.$_" } @realkeys;
     push @cfgs, @rundef;
     }
     push @cfgs, map { "dgit.default.$_" } @realkeys;
     push @cfgs, @rundef;
+    return @cfgs;
+}
+
+sub access_cfg (@) {
+    my (@keys) = @_;
+    my (@cfgs) = access_cfg_cfgs(@keys);
     my $value = cfg(@cfgs);
     return $value;
 }
     my $value = cfg(@cfgs);
     return $value;
 }