def create(): global COLUMNS file_path = "{0}{1}".format(Config.csv_file_directory, Config.csv_file_name) if os.path.exists(file_path): os.remove(file_path) COLUMNS = column_file_loader.load() COLUMNS += '\n' write_columns() parse_counts()
def update(column): global columns if not columns: columns = column_file_loader.load() if column not in columns: columns = "{0},{1}".format(columns, column) filePath = "{0}{1}".format(Config.temp_file_directory, Config.temp_column_file_name) f = open(filePath,'w') f.write(columns) f.close()
def update(column): global columns if not columns: columns = column_file_loader.load() if column not in columns: columns = "{0},{1}".format(columns, column) filePath = "{0}{1}".format(Config.temp_file_directory, Config.temp_column_file_name) f = open(filePath, 'w') f.write(columns) f.close()