don't output env vars that are already set
[p5sagit/local-lib.git] / lib / local / lib.pm
index 9943542..40fcf68 100644 (file)
@@ -305,6 +305,10 @@ sub environment_vars_string_for {
         && ${$value->[0]} eq $name) {
       next;
     }
+    if (!ref $value
+        && $value eq $ENV{$name}) {
+      next;
+    }
     $out .= $self->$build_method($name, $value);
   }
   return $out;