Skip to content

Commit

Permalink
tmplr: fix current directory assumption
Browse files Browse the repository at this point in the history
  • Loading branch information
benknoble committed Jul 13, 2019
1 parent cb96f39 commit 165bb05
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tmplr/temple.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,8 @@ def write(self, filename=None, stdout=False):
return None
else:
fullpath = self.filename(filename)
dirname = path.dirname(fullpath)
# treat no directory as ./
dirname = path.dirname(fullpath) or path.curdir
if path.exists(fullpath):
# silent
return fullpath
Expand Down

0 comments on commit 165bb05

Please sign in to comment.