On previous version, glob pattern will be expanded to actual file
names when writing setting to etc/apt/apt.conf.d/no-cache.
This patch fixes to quote to work cache clean command properly.
| ... | ... |
@@ -144,9 +144,9 @@ if [ -z "$strictDebootstrap" ]; then |
| 144 | 144 |
echo 'force-unsafe-io' | sudo tee etc/dpkg/dpkg.cfg.d/02apt-speedup > /dev/null |
| 145 | 145 |
# we want to effectively run "apt-get clean" after every install to keep images small (see output of "apt-get clean -s" for context) |
| 146 | 146 |
{
|
| 147 |
- aptGetClean='rm -f /var/cache/apt/archives/*.deb /var/cache/apt/archives/partial/*.deb /var/cache/apt/*.bin || true' |
|
| 148 |
- echo 'DPkg::Post-Invoke { "'$aptGetClean'"; };'
|
|
| 149 |
- echo 'APT::Update::Post-Invoke { "'$aptGetClean'"; };'
|
|
| 147 |
+ aptGetClean='"rm -f /var/cache/apt/archives/*.deb /var/cache/apt/archives/partial/*.deb /var/cache/apt/*.bin || true";' |
|
| 148 |
+ echo "DPkg::Post-Invoke { ${aptGetClean} };"
|
|
| 149 |
+ echo "APT::Update::Post-Invoke { ${aptGetClean} };"
|
|
| 150 | 150 |
echo 'Dir::Cache::pkgcache ""; Dir::Cache::srcpkgcache "";' |
| 151 | 151 |
} | sudo tee etc/apt/apt.conf.d/no-cache > /dev/null |
| 152 | 152 |
# and remove the translations, too |