aboutsummaryrefslogtreecommitdiffstats
path: root/bin/rmcache
blob: acba953bd198afccef9f921d8461fda152b99317 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/bash

USERDIR=$1

echo "rmcache cleaning up: $USERDIR"

caches=".cache/chromium"
caches+=" .cache/thumbnails"
## take care of the whitespace!
caches+=" .config/chromium/Default/*Index*"
caches+=" .thumbnails"
caches+=" .opera/cache4"
caches+=" .opera/cache"
caches+=" .java/deployment/cache"
caches+=" .local/share/Trash"
caches+=" .gnome2/epiphany/mozilla/epiphany/Cache"
caches+=" .adobe/Acrobat/*/Cache"
caches+=" .adobe/Acrobat/*/Temp"
caches+=" .macromedia/Flash_Player/*"
caches+=" .adobe/Flash_Player/AssetCache"
caches+=" .java/deployment/cache"

pushd $USERDIR > /dev/null

for cache in $caches
do
  echo "removing $cache"
  rm -Rf "$cache"
  [ $? -eq 0 ] || exit 1
done

popd > /dev/null