aerofs tools
This commit is contained in:
23
aerofs/aerofs-clean
Executable file
23
aerofs/aerofs-clean
Executable file
@@ -0,0 +1,23 @@
|
||||
#!/bin/bash
|
||||
|
||||
|
||||
MyRoot=$( sqlite3 $HOME/.aerofs/conf "SELECT v FROM c WHERE k = 'root';" )
|
||||
MyDir=$( dirname "$MyRoot" )
|
||||
AEROAUX=($MyDir/.aerofs.aux*)
|
||||
|
||||
|
||||
if [ -z "$1" ]
|
||||
then echo partial/revisions/conflicts: '(-f to delete.)'
|
||||
du -h -d 1 "$AEROAUX/"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
while getopts "f" OPTS;
|
||||
do case ${OPTS} in
|
||||
f)
|
||||
find "$AEROAUX/r" -mindepth 1 -depth -exec rm -Rf \{\} \;
|
||||
find "$AEROAUX/p" -mindepth 1 -depth -exec rm -Rf \{\} \;
|
||||
du -h -d 1 "$AEROAUX/"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
Reference in New Issue
Block a user