We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6abf489 commit a57dbe5Copy full SHA for a57dbe5
templates/update_had_no_effect.sh.epp
@@ -3,10 +3,15 @@
3
Integer $timeout = 30,
4
Integer $tries = 1,
5
| -%>
6
-eval "$(apt-config shell DIR Dir::Cache || echo "DIR='var/cache/apt'")"
+
7
+DIR='var/cache/apt'
8
+EVAL="$(mktemp)"
9
+apt-config shell DIR Dir::Cache > "$EVAL" && . "$EVAL"
10
cd "/$DIR" || exit 0
11
OLD="$(mktemp -p "/$DIR")"
-eval "$(apt-config shell CUR Dir::Cache::pkgcache || echo "CUR='pkgcache.bin'")"
12
+CUR=pkgcache.bin
13
+apt-config shell CUR DIR::Cache::pkgcache >"$EVAL" && . "$EVAL"
14
+rm -f "$EVAL"
15
ln -f "$CUR" "$OLD"
16
TRIES=<%= $tries %>
17
while true; do
0 commit comments