mirror of
https://github.com/zyedidia/micro.git
synced 2026-03-30 06:37:14 +09:00
Improve backup system
This commit introduces several improvements to the backup system. * Backups are made every 8 seconds for buffers that have been modified since the last backup. * The `permbackup` option allows users to specify that backups should be kept permanently. * `The backupdir` option allows users to store backups in a custom directory. Fixes #1641 Fixes #1536 Ref #1539 (removes possibility of race condition for backups)
This commit is contained in:
@@ -274,7 +274,7 @@ func main() {
|
||||
fmt.Println("Micro encountered an error:", err)
|
||||
// backup all open buffers
|
||||
for _, b := range buffer.OpenBuffers {
|
||||
b.Backup(false)
|
||||
b.Backup()
|
||||
}
|
||||
// Print the stack trace too
|
||||
fmt.Print(errors.Wrap(err, 2).ErrorStack())
|
||||
|
||||
Reference in New Issue
Block a user