# this is the main cleanup function to cleanup the application once shutdonw def myCar_exit(config): import configparser with open('data/etc/myCar.conf', 'w') as configfile: config.write(configfile) print('system cleanup done')