Fix for writing new user config file

A few small fixes:

- creates `config` if config file does not exist
- calls `save_config` instead of `write_config`
- correctly saves config