moonfire-nvr/server/src/cmds
Scott Lamb 97bfe0afc3 fix nvr init error message on mkdir failure
Before it would produce this incorrect message that told you to run
the command you just ran:

```
$ nvr init --db-dir=/nonexistent/db
E20211021 09:08:23.798 main moonfire_nvr] Exiting due to error: db dir /nonexistent/db not found; try running moonfire-nvr init
caused by: ENOENT: No such file or directory
```

Now the same command produces the following:

```
$ nvr init --db-dir=/nonexistent/db
E20211021 09:09:11.056 main moonfire_nvr] Exiting due to error: unable to create db dir /nonexistent/db
caused by: ENOENT: No such file or directory
```

Add tests just for good measure.
2021-10-21 09:44:27 -07:00
..
config shutdown better 2021-09-23 16:33:29 -07:00
upgrade shutdown better 2021-09-23 16:33:29 -07:00
check.rs shutdown better 2021-09-23 16:33:29 -07:00
init.rs shutdown better 2021-09-23 16:33:29 -07:00
login.rs shutdown better 2021-09-23 16:33:29 -07:00
mod.rs fix nvr init error message on mkdir failure 2021-10-21 09:44:27 -07:00
run.rs trim whitespace from /etc/timezone 2021-09-24 10:49:04 -07:00
sql.rs shutdown better 2021-09-23 16:33:29 -07:00
ts.rs shutdown better 2021-09-23 16:33:29 -07:00