aboutsummaryrefslogtreecommitdiffstats
path: root/chapter6/cleanup.sh
diff options
context:
space:
mode:
authorWilliam Harrington <kb0iic@berzerkula.org>2021-04-05 20:28:05 -0500
committerWilliam Harrington <kb0iic@berzerkula.org>2021-04-05 20:28:05 -0500
commit56dbd9d14e01fc4e4d4987a047f952ffa57f7777 (patch)
treec948160876b538781d5b1e6cbe7ba04a797268ef /chapter6/cleanup.sh
parent0aa6a71f970f258691719ca986b84104d042d82c (diff)
Make tar command verbose and log to backup and cleanup logs.
Diffstat (limited to 'chapter6/cleanup.sh')
-rw-r--r--chapter6/cleanup.sh23
1 files changed, 13 insertions, 10 deletions
diff --git a/chapter6/cleanup.sh b/chapter6/cleanup.sh
index 2db4067..f0b9ce3 100644
--- a/chapter6/cleanup.sh
+++ b/chapter6/cleanup.sh
@@ -6,18 +6,21 @@ else
printf "%b" "${GRN}Cleaning up ${YLW}${LFS}${RST}... "
- find "${LFS}"/usr/lib -name \*.la -delete >/dev/null 2>&1
- find "${LFS}"/usr/libexec -name \*.la -delete >/dev/null 2>&1
+ {
+ find "${LFS}"/usr/lib -name \*.la -delete
+ find "${LFS}"/usr/libexec -name \*.la -delete
- rm -rf "${LFS}"/usr/share/doc >/dev/null 2>&1
- rm -rf "${LFS}"/usr/share/info >/dev/null 2>&1
- rm -rf "${LFS}"/usr/share/man >/dev/null 2>&1
+ rm -rfv "${LFS}"/usr/share/doc
+ rm -rfv "${LFS}"/usr/share/info
+ rm -rfv "${LFS}"/usr/share/man
- strip --strip-debug "${LFS}"/usr/lib/* >/dev/null 2>&1
- strip --strip-unneeded "${LFS}"/usr/bin/* >/dev/null 2>&1
- strip --strip-unneeded "${LFS}"/usr/sbin/* >/dev/null 2>&1
- strip --strip-unneeded "${LFS}"/tools/bin/* >/dev/null 2>&1
+ strip --strip-debug "${LFS}"/usr/lib/*
+ strip --strip-unneeded "${LFS}"/usr/bin/*
+ strip --strip-unneeded "${LFS}"/usr/sbin/*
+ strip --strip-unneeded "${LFS}"/tools/bin/*
+
+} >"${LFS}"/sources/log/chapter6/cleanup.log 2>&1
printf "%b" "${IGRN}OK${RST}\n"
- touch "${LFS}"/sources/chapter6/cleanup >/dev/null 2>&1
+ touch "${LFS}"/sources/chapter6/cleanup
fi