* make -clear-cache delete all APPDATA temp folders
This commit is contained in:
parent
e1c8e8d17b
commit
385373daef
|
@ -97,10 +97,10 @@ public class Main {
|
||||||
if (args.clearCache()) {
|
if (args.clearCache()) {
|
||||||
// clear preferences and cache
|
// clear preferences and cache
|
||||||
System.out.println("Clear cache and temporary files");
|
System.out.println("Clear cache and temporary files");
|
||||||
for (File cache : getApplicationFolder().listFiles(FOLDERS)) {
|
for (File folder : getApplicationFolder().getAbsoluteFile().listFiles(FOLDERS)) {
|
||||||
if (matches("cache|temp|grape", cache.getName())) {
|
if (matches("cache|temp|grape|logs", folder.getName())) {
|
||||||
for (File it : cache.listFiles()) {
|
if (delete(folder)) {
|
||||||
delete(it);
|
System.out.println("* Delete " + folder);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue