This was a pretty serious, almost-catastrophic[1] incident. I lost 160+ columns the first time I ran with a commandline arg (after a long time).
The root cause: I've been conflating globals Directory and Settings_file in my mind, and as a result I forgot about the existence of Settings_file altogether. Settings_file is the root variable. Everything else is dependent on it getting initialized right.
Process improvements:
[1] Not actually catastrophic because I didn't lose any actual notes.
WUJMPZPGPNVLBHEBVYTLSYWFOPEYVQJOPK45RFD576HTLG3NFCTAC VJKBAJWASCQWI6JDVJJHL4WL2IDZF4RUT33GNILSRSPA3A6E2MBAC DLFRVE5OBLCKIOBKNSCGF6AL6M35MZ24T2JE5UL66CLHCI6DN77QC Q3HD3NQ6VOHEXHBSMQ5QDLKUH4OU2OJDMR3UXVOTB65IUUFJ2FCAC JMUE7GSN6QDQZ6NDRB55MRJMKJN6LBD6MVQPKROYPDOIXM7I3XNQC KKMFQDR43ZWVCDRHQLWWX3FCWCFA3ZSXYOBRJNPHUQZR2XPKWULAC KE5FEMVJYSNYWUEDPM74EVUOFBHZDE3TGCVL6PXF2ALDZZ7XD2NQC EMG7SDLWWVH66BJT6XUPLPVSICCM2BC5QD7LOTLLZCQ4XMFYRUDQC CQYKYJJU3NMY2CNXF7VZWSDYU3SWPFWA3ZHDW24Q4S6QEK5Y2TSAC OTIBCAUJ3KDQJLVDN3A536DLZGNRYMGJLORZVR3WLCGXGO6UGO6AC J3ER7DFO2TXYUMJAXZUFEHQNLFDNIXSYDTE7HEFGQ2RYB3A6RFPAC WLTFFU3YN5FKUMZEHLMTO4DJYJ6H73TVSTVUZRZBIZERXKZXCZCAC 3QNOKBFMKBGXBVJIRHR2444JRRMBTABHE4674NR3DT67RRM2X6GAC Cursor_pane.col = settings.cursor_colCursor_pane.row = settings.cursor_rowDisplay_settings.x = settings.surface_xDisplay_settings.y = settings.surface_y
Cursor_pane.col = Settings.cursor_colCursor_pane.row = Settings.cursor_rowDisplay_settings.x = Settings.surface_xDisplay_settings.y = Settings.surface_y
function App.load()if love.filesystem.getInfo('config') thenSettings = json.decode(love.filesystem.read('config'))Current_app = Settings.current_app
function App.load(arg)-- the bootstrap for everything elseSettings_file = 'config'assert(#arg <= 1)if #arg == 1 thenSettings_file = 'config.'..arg[1]endif love.filesystem.getInfo(Settings_file) thenSettings = json.decode(love.filesystem.read(Settings_file))elseSettings = {current_app='run'}