nopraw
David Trail 13 years ago
parent 637a14aba3
commit 4336be4429

3
.gitignore vendored

@ -1,3 +1,4 @@
*.json data.json
user.json
*.swp *.swp
*~ *~

@ -5,10 +5,13 @@ from json import loads, dumps
from urllib2 import urlopen, HTTPError from urllib2 import urlopen, HTTPError
from time import sleep from time import sleep
if len(sys.argv) != 2: user = None
raise Exception("You must specifiy a user") if len(sys.argv) == 2:
user = sys.argv[1]
user = sys.argv[1] else:
f = open('user.json', 'r')
user = loads(f.read())['user']
f.close()
sub_section = 'comments' sub_section = 'comments'
after = '' after = ''

@ -0,0 +1 @@
shreddit

@ -1,19 +1,9 @@
#!/bin/sh #!/bin/sh
USER=$1
if [ $2 ]; then
DAYS=$2
else
DAYS=7
fi
echo "Deleting everything before $DAYS days ago for user $USER"
echo "Running grab.py to get your history..." echo "Running grab.py to get your history..."
python2 grab.py $USER || exit 1 python2 grab.py $USER || exit 1
echo "Running kill.py to annihilate your history..." echo "Running kill.py to annihilate your history..."
python2 kill.py $DAYS || exit 1 python2 kill.py $DAYS || exit 2
echo "Everything seemed to run successfully." echo "Everything seemed to execute successfully."

@ -1 +1 @@
{"passwd": "", "user": ""} {"passwd": "", "user": "", "days": "7"}

Loading…
Cancel
Save