def write_file(filename, content=None, mode="w"):
    if not os.path.exists(filename):
        file_path = os.path.splitdrive(filename)[-1]
        folders = os.path.split(file_path)[0]
        mkdir(folders)
    with open(filename, mode) as myfile:
        myfile.write(str(content))
Sends an e-mail to the user whose flowspace is approved or rejected telling him/her
dataset/ETHPy150Open facebook/IT-CPE/code/lib/modules/fs_tools.py/write_file--crossover with--dataset/ETHPy150Open fp7-ofelia/ocf/optin_manager/src/python/openflow/optin_manager/admin_manager/helper.py/send_approve_or_reject_email