[pacman-dev] Recreate empty missing filesystem directories

Dan McGee dpmcgee at gmail.com
Tue Nov 15 13:29:08 EST 2011


This is fixed in pacman 4.0, but thought people might find this super
simple script helpful. A lot of people will find `/etc/cron.hourly/`
missing due to the removal of the adjtime cronjob; but at least on my
system there were a few more missing directories found.


$ sudo /tmp/find-missing-dirs.sh
Password:
/usr/share/icons/hicolor/16x16/devices/
/usr/share/icons/hicolor/22x22/devices/
/usr/share/icons/hicolor/32x32/devices/

$ sudo /tmp/find-missing-dirs.sh | xargs sudo mkdir

$ sudo /tmp/find-missing-dirs.sh


-Dan

$ cat /tmp/find-missing-dirs.sh
#!/bin/bash

IFS=$'\n'
for path in $(pacman -Qql | grep '/$' | sort | uniq); do
	if [[ ! -d $path ]]; then
		echo $path
	fi
done


More information about the pacman-dev mailing list