mirror of
https://github.com/CopterExpress/clever-show.git
synced 2026-05-30 00:39:32 +00:00
New script to automatically update default configspec
This commit is contained in:
9
update_configspec.py
Normal file
9
update_configspec.py
Normal file
@@ -0,0 +1,9 @@
|
||||
import config
|
||||
from Server.copter_table_models import CopterDataModel
|
||||
|
||||
cfg_server = config.ConfigObj('SERVER/config/spec/configspec_server.ini')
|
||||
default = {key: 'boolean(default=True)' for key in CopterDataModel.columns}
|
||||
cfg_server['TABLE']['PRESETS']['DEFAULT'] = default
|
||||
|
||||
cfg_server.write()
|
||||
print('Server configspec updated')
|
||||
Reference in New Issue
Block a user