Commit 1392ba2e authored by Benjamin Blanc's avatar Benjamin Blanc

Add createFile function to SlapOScontroler.py

parent 4ec66892
......@@ -47,6 +47,15 @@ def createFolders(folder):
if not(os.path.exists(folder)):
os.makedirs(folder)
def createFile(path, mode, content):
f = open(path, mode)
if os.path.exists(path):
f.write(content)
f.close()
else:
# error
pass
class SlapOSControler(object):
def __init__(self, working_directory, config, log):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment