You are not logged in.
Pages: 1
When you do "pacman -Rs" for some software, it leaves some configuration files and other stuffs related to that software. If I'm not going to use that software in future, it becomes piling garbage and it will be difficult to locate and delete huge amount of garbage. Is there a way to find and get rid of this garbage?
Offline
When you do "pacman -Rs" for some software, it leaves some configuration files and other stuffs related to that software. If I'm not going to use that software in future, it becomes piling garbage and it will be difficult to locate and delete huge amount of garbage. Is there a way to find and get rid of this garbage?
pacman -Rsn <file>
the n is --nosave which removes those file also.
For futher pacman informations:
man pacman full all its features and how to use them.
Offline
thanks a lot twiistedkaos for that. but how about deleting the old garbage.
Offline
Just do as root
find /etc/ -name "*.pac*" -print0 | xargs -r0 rm
Offline
what?! Dude, acquaint yourself with the find man page:
find /etc -name "*.pac*" -exec rm {} ;
That'll just delete it, if you want to confirm each deletion you can use:
find /etc -name "*.pac*" -ok rm {} ;
And, yes, the backsplash and semi-colon are essential.
Offline
I hate find syntax. I'd have done:
rm $(find /etc -name "*.pac*")
or
rm -i $(find /etc -name "*.pac*")
to confirm.
To each his own, of course, I just find this way more readable and left to righty.
Dusty
Offline
To each his own of course...but could I get away with arguing that piping and nesting is a recipe for trouble where root and rm are involved? OT I know
Offline
-print FTW. I have seen more posts about "I ran this find command as root and now half of /etc is gone - PLZ HELP!!!" than I care to think about. I also agree with dusty - the syntax for find is anything but intuitive.
Unthinking respect for authority is the greatest enemy of truth.
-Albert Einstein
Offline
mv or cp somewhere rather than rm [check them first]?
/me goes to clear out /etc
Mr Green
Offline
You got it all wrong.
# find /boot /etc -name '*.pacsave' -print0 | xargs -0 rm -f
P.S.: -exec sucks, it has security and performance issues (and looks weird).
;]
1000
Offline
Since this is deleting files, we can use:
find /boot /etc -name '*.pacsave' -delete
Offline
Pages: 1