Purgeconfig – A safer way to reset configuration files
To solve these problems, lkjoel made a script called purgeconfig that will artificially reset the configuration files (manually removing the configuration files, marking the packages as purged, then reinstalling the packages).
WARNING: Do NOT run Apt/Aptitude/DPKG/Synaptic/Software Center while running purgeconfig.
Install Purgeconfig on ubuntu
Download and install the script with this command:
chmod +x purgeconfig.sh
sudo cp purgeconfig.sh /usr/bin/purgeconfig
sudo purgeconfig package1 package2 package3 etc...
You can specify the architecture:
sudo purgeconfig package1:i386 etc...
It seems like a nice utility…
I wonder why apt doesn’t have such an option..
But what about the config files stored in the home
of each user? would those be restored as well???
You are awesome! I wasted hours trying to do a clean install of cups before I found this script. I actually tried to purge it first, but the package ubuntu-desktop depends on it!
It blows my mind that neither apt* nor dpkg can cleanly install a package that is already installed (e.g. a “repair” operation).
It would be nice if there were an alternate DL link. I am not into signing up for M$ Azure cloud.
I’ll try and find it elsewhere.
NM I used the wget and all is fine! LOL