2
0
mirror of https://github.com/ComradCollective/Comrad synced 2024-11-17 21:25:37 +00:00
Comrad/bin/comrad-reset

18 lines
352 B
Plaintext
Raw Normal View History

2020-09-29 18:20:51 +00:00
#!/bin/bash
2020-09-17 05:01:59 +00:00
2020-09-29 18:20:51 +00:00
# funcs (mac doesnt have realpath)
realpath() {
[[ $1 = /* ]] && echo "$1" || echo "$PWD/${1#./}"
}
pathdata="`realpath ~/comrad/data`"
echo "Removing $pathdata. You will permanently lose your users and contacts. Proceed? "
2020-09-17 05:01:59 +00:00
2020-09-17 05:03:47 +00:00
read -p "[y/N] " y_n
2020-09-17 05:01:59 +00:00
echo $y_n
if [ ! "$y_n" = "y" ]; then
echo "Cancelling"
else
2020-09-29 18:20:51 +00:00
rm -r $pathdata
2020-09-17 05:01:59 +00:00
fi