This refactors the SQLite-specific bits into db_sqlite.go. A future patch will add PostgreSQL support.
This commit changes the Network schema to use user IDs instead of usernames. While at it, a new UNIQUE(user, name) constraint ensures there is no conflict with custom network names. Closes: https://todo.sr.ht/~emersion/soju/86 References: https://todo.sr.ht/~emersion/soju/29
Allows populating the soju database from a ZNC config file.