mirror of
https://github.com/asciinema/asciinema.git
synced 2025-12-15 19:28:00 +01:00
Remove uploaded files
This commit is contained in:
@@ -19,6 +19,7 @@ import glob
|
||||
import bz2
|
||||
import ConfigParser
|
||||
import uuid
|
||||
import shutil
|
||||
|
||||
SCRIPT_NAME = os.path.basename(sys.argv[0])
|
||||
BASE_DIR = os.path.expanduser("~/.ascii.io")
|
||||
@@ -296,12 +297,17 @@ class Uploader(object):
|
||||
# print >> sys.stderr, stderr
|
||||
# sys.stderr.write(stderr)
|
||||
os.write(2, stderr)
|
||||
else:
|
||||
self._remove_files()
|
||||
|
||||
if stdout:
|
||||
return stdout
|
||||
else:
|
||||
return None
|
||||
|
||||
def _remove_files(self):
|
||||
shutil.rmtree(self.path)
|
||||
|
||||
|
||||
def check_pending():
|
||||
num = len(pending_list())
|
||||
|
||||
Reference in New Issue
Block a user