]> git.armaanb.net Git - lightcards.git/blobdiff - lightcards/progress.py
Implement color customization config option
[lightcards.git] / lightcards / progress.py
index 3be0247e42170c3243cf03814dc09b51b0ab38bc..97fcf0c9ce68068db1f5f9914dbe49eb42f5e6e7 100644 (file)
@@ -4,8 +4,8 @@
 import hashlib
 import os
 import pickle
-import shutil
 
+# TODO: Check for $XDG_CACHE_HOME
 dired = f"{os.path.expanduser('~')}/.cache/lightcards/"
 
 
@@ -39,6 +39,6 @@ def dive(stra):
 
 def purge(stra):
     """Delete pickle file"""
-    file = f"{dired}/{name_gen(stra)}/"
+    file = f"{dired}/{name_gen(stra)}.p"
     if os.path.exists(file):
-        shutil.rmtree(file)
+        os.remove(file)