| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
sqlite3 requires the directory where the database resides to be
writeable by the user. This presents a problem on multiuser UNIX systems
where they may want to limit areas where users have write access.
This rewrite totally scraps the sqlite3 database in favor of a pretty
simple json file consisting of an array of posts. flock(2) locking is
used to synchronize access to the file and make sure two clients aren't
trying to write to it at once. The locking is fairly granular right now,
but later I may change it to using a single lock for the duration of
execution since race conditions are *possible*, if unlikely for the
purposes of clinte's intended use.
|
|
|
|
|
|
|
|
| |
Using a helper function to handle fatal errors
error::helper()
Displays the simplified message if an error condition
occurs. Displays both the simplified and the raw error
message if -v verbose logging is enabled.
|
| |
|
|
|
|
| |
assuming
|
|
|
|
|
|
|
|
|
|
| |
Rather than using a new logfile for each invocation, a single logfile
called `/tmp/clinte_$USER.log` will be used, with later invocations
appending to the previous messages.
Also removed some unnecessary `use` statements relating to the `log`
crate and its macros. Leaving the macro calls namespaced to `log::`
makes it clearer what the behavior is.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|