diff options
Diffstat (limited to 'initcpio')
-rw-r--r-- | initcpio/hook/paccache | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/initcpio/hook/paccache b/initcpio/hook/paccache index bd961ee..6e09419 100644 --- a/initcpio/hook/paccache +++ b/initcpio/hook/paccache @@ -3,9 +3,11 @@ run_latehook() { local newroot="/new_root/" - if ! grep -q '^pacserve hosts' ${newroot}/etc/pacredir.conf -a [[ -n "${pacserve}" ]]; then - msg ":: Adding pacserve host '${pacserve}' to pacredir.conf..." - echo "pacserve hosts = ${pacserve}" >> ${newroot}/etc/pacredir.conf + if ! grep -q '^pacserve hosts' ${newroot}/etc/pacredir.conf; then + if [[ -n "${pacserve}" ]]; then + msg ":: Adding pacserve host '${pacserve}' to pacredir.conf..." + echo "pacserve hosts = ${pacserve}" >> ${newroot}/etc/pacredir.conf + fi fi if ! grep -q '^pacdbserve hosts' ${newroot}/etc/pacredir.conf; then |