This might be helpful for some folks - I've only had to use it once because I always back up configs before I edit them but if you've ever got a broken package and want to reset the package to its default config it's easy to do with a oneliner - as root: Not necessary to reset a single package but since I don't particularly want to look up this command in the middle of breakage I made a bash function out of it and stuck it in ~/.profile. Looks like this:
Code:
apt-get -o Dpkg::Options::='--force-confnew' install --reinstall <package-name>
Code:
reconfig() { if [[ -z "$1" ]]; then echo "Usage: reconfig <package-name>" return 1 fi sudo apt-get -o Dpkg::Options::='--force-confnew' install --reinstall "$1"}
Statistics: Posted by wizard10000 — 2025-01-06 11:12 — Replies 0 — Views 32