Created
January 12, 2019 14:36
-
-
Save nicman23/756ddc8543ce04be41ea1900f786fc59 to your computer and use it in GitHub Desktop.
paccheck checking only the existance and size of the the reported files, going to the next package on first error.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/bash | |
pacman -Qsq | while read line; | |
do echo \> checking $line; pacman -Qlq $line | grep -vP '^/etc' | grep -vP '/$' | | |
while read line2 | |
do if [[ ! -e "$line2" ]] && [[ ! -s "$line2" ]] | |
then echo $line $line2 | tee -a corrupt; break | |
fi | |
done | |
done | |
echo Now run 'xargs pacman -S <<< "$(cut -d "\' \'" -f 1 corrupt)"' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment