adhocteam / pushup

Pushup is for making modern, page-oriented web apps in Go
https://pushup.adhoc.dev
MIT License
844 stars 30 forks source link

Split main.go #96

Closed paulsmith closed 1 year ago

paulsmith commented 1 year ago

This change splits main.go into 7 separate .go source files, grouping related functionality into each file:

This is merely a cut-paste affair, no lines of code were modified. Everything stays in package main as before.

I've put almost everything into main.go as I've gone and have been quite comfortable with it. Even at 4,500 lines it's really easy to manage and for a prototype/experimental project it's appropriate to not waste cognitive overhead on where things are.

That said I'm starting to see future developments for Pushup that would be easier to work on if the source were a little bit more factored out, and if we had more internal APIs between major components. So this change is mainly an incremental step toward putting things into their own packages next (internal only to start).

main_test.go is similarly factored apart.