summaryrefslogtreecommitdiff
path: root/helpers/lh_cleanapt
blob: ec28865cf81343f8f11652dd264b9aeedd0acd4d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh

# lh_cleanapt

# Clean apt packages cache
rm -rf "${LIVE_CHROOT}"/var/cache/apt
mkdir -p "${LIVE_CHROOT}"/var/cache/apt/archives/partial

# Clean apt list cache
rm -rf "${LIVE_CHROOT}"/var/lib/apt/lists/*
mkdir -p "${LIVE_CHROOT}"/var/lib/apt/lists/partial

# Remove old files
rm -f "${LIVE_CHROOT}"/var/lib/dpkg/available-old
rm -f "${LIVE_CHROOT}"/var/lib/dpkg/diversions-old
rm -f "${LIVE_CHROOT}"/var/lib/dpkg/statoverride-old
rm -f "${LIVE_CHROOT}"/var/lib/dpkg/status-old