> Do not use `cp` to back up SQLite databases. It is not transactionally safe.
Anyone know if comitting the sqlite db file to git is not safe either?
Anyone know if comitting the sqlite db file to git is not safe either?
If you cp a database mid transaction you will loose the transaction as it is processed in the separate journal or WAL file until commit. If you copy mid commit then you will have incomplete data in the main database file and possibly data corruption.