Instead of exporting an arbitrary list of quilt internal variables,
which helper scripts may or may not use, let each command explicitly
export variables as needed before calling an helper script. This is
both clearer and more efficient.

In practice, only dependency-graph needs to access internal
variables at the moment, and it only uses $QUILT_PC.
---
 quilt/graph.in            |    1 +
 quilt/scripts/patchfns.in |    1 -
 2 files changed, 1 insertion(+), 1 deletion(-)

--- a/quilt/graph.in
+++ b/quilt/graph.in
@@ -126,6 +126,7 @@ options=
 pipe=
 [ -n "$opt_format" ] && pipe="| dot -T$opt_format"
 
+export QUILT_PC
 applied_patches \
 | eval $QUILT_DIR/scripts/dependency-graph $options - $pipe
 ### Local Variables:
--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -15,7 +15,6 @@ export TEXTDOMAINDIR=@LOCALEDIR@
 ORIGINAL_LANG=$LANG
 export LANG=POSIX
 
-export QUILT_PATCHES QUILT_PC SUBDIR SERIES DB
 DB_VERSION=2
 
 : ${QUILT_PC:=.pc}


-- 
Jean Delvare
SUSE L3 Support

_______________________________________________
Quilt-dev mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/quilt-dev

Reply via email to