WIP: configuration file support

WIP for #140.