Split initialisation into init() and main() funcs
Split initialisation into init() and main() funcs

Move much of the application's initialisation logic into the `init()`
function, which is run immediately after variable declarations have
evaluated their initialisers [1].

[1]: https://golang.org/doc/effective_go.html#initialization

mattbostock/leavediary