Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/instance.py
diff options
context:
space:
mode:
authorerikb <erikb@574bc980-5f2d-0410-acbc-c8f9f0eb14e0>2007-10-31 20:45:09 (GMT)
committer erikb <erikb@574bc980-5f2d-0410-acbc-c8f9f0eb14e0>2007-10-31 20:45:09 (GMT)
commit9f4da5c1e2995bee9a6fb538e34c637ebdb73081 (patch)
tree49dc2be32eb5605527635f820f7abba2b0b98efa /instance.py
parent9783a88ae07b9f2b6a754d1f595fbc6a149227e0 (diff)
taking it xo
git-svn-id: http://mediamods.com/public-svn/camera-activity/Record.activity@792 574bc980-5f2d-0410-acbc-c8f9f0eb14e0
Diffstat (limited to 'instance.py')
-rw-r--r--instance.py11
1 files changed, 9 insertions, 2 deletions
diff --git a/instance.py b/instance.py
index 1fd55f6..9e238b2 100644
--- a/instance.py
+++ b/instance.py
@@ -20,7 +20,14 @@ class Instance:
instanceId = None
tmpPath = None
- def __init__( self, ca ):
+ def __init__(self, ca):
self.__class__.instanceId = ca._activity_id
tmpPath = os.path.join( ca.get_activity_root(), "tmp" )
- self.__class__.tmpPath = os.path.join( tmpPath, str(self.__class__.instanceId)) \ No newline at end of file
+ self.__class__.tmpPath = os.path.join( tmpPath, str(self.__class__.instanceId))
+ recreateTmp()
+
+
+def recreateTmp():
+ if (os.path.exists(Instance.tmpPath)):
+ shutil.rmtree(Instance.tmpPath)
+ os.makedirs(Instance.tmpPath) \ No newline at end of file