Skip to content

Commit c8602db

Browse files
committed
Fix output directory creation
1 parent a31774c commit c8602db

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

compile.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Requires commonmark (pip install CommonMark)
22

3-
from os import listdir
3+
from os import listdir, mkdir
44
from os.path import isfile, isdir, join
55
import commonmark
66
import shutil
@@ -54,6 +54,9 @@ def compileFile(inputFilename, outputFilename, up):
5454

5555

5656
def compileDir(inputDir, outputDir, up):
57+
if not isdir(outputDir):
58+
mkdir(outputDir)
59+
5760
for f in listdir(inputDir):
5861
input = join(inputDir, f)
5962
output = join(outputDir, f)

0 commit comments

Comments
 (0)