Using config files as an interface for non programmers
I sometimes write small utilities for colleagues with limited programming experience. I have come to realise that if the user can't interface in a 'non-programming' way then the code will just not get used. I've looked into tkinter
and PyInstaller
but there's issues with permissions and significant overhead for what is generally a relatively small bit of code.
Config files using yaml and the corresponding python library provides a way of providing easy interfacing. I used this on a recent project which plotted data on top of engineering drawings. The user can export the drawings using the CAD software's print dialog and then copy those settings into a config file:
imgcfg:
widthpix: 3000.0 #pixels
heightpix: 2000.0 #pixels
resolution: 300 #pixels/in
border: 3 #pixels
scale: 8 #sclaing factor
This is short, human readable and easily editable. Will see if this leads to better engagement.