{tmp} contains expanded path of $TMP
This commit is contained in:
parent
25e64774bb
commit
a16f3889f6
@ -104,9 +104,10 @@ class Slate():
|
||||
def expand_vars(self, string, delta_desc='BASE', **kwargs):
|
||||
if isinstance(string, str):
|
||||
rand = int(random.random()*99999999)
|
||||
tmp = os.path.expandvars('$TMP')
|
||||
if string == '{rand}':
|
||||
return rand
|
||||
return string.format(delta_desc=delta_desc, **kwargs, rand=rand)
|
||||
return string.format(delta_desc=delta_desc, **kwargs, rand=rand, tmp=tmp)
|
||||
return string
|
||||
|
||||
def apply_nested(self, d, f):
|
||||
|
Loading…
Reference in New Issue
Block a user