From 1ee7cfa40ded6f993ff425b9e69007741ce82b5b Mon Sep 17 00:00:00 2001 From: Carlo Strub Date: Fri, 2 Feb 2018 22:58:50 +0100 Subject: [PATCH] add some comments --- sisyphus/sisyphus.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sisyphus/sisyphus.go b/sisyphus/sisyphus.go index 853d511..0cd25f3 100644 --- a/sisyphus/sisyphus.go +++ b/sisyphus/sisyphus.go @@ -254,6 +254,7 @@ COPYRIGHT: app.Run(os.Args) } +// learn invokes the learning process for a slice of maildirs func learn(maildirs []sisyphus.Maildir, dbs map[sisyphus.Maildir]*bolt.DB) { mails, err := sisyphus.LoadMails(maildirs) if err != nil { @@ -279,6 +280,7 @@ func learn(maildirs []sisyphus.Maildir, dbs map[sisyphus.Maildir]*bolt.DB) { return } +// backup creates a backup copy of the existing database func backup(maildirs []sisyphus.Maildir, dbs map[sisyphus.Maildir]*bolt.DB) { for _, d := range maildirs { db := dbs[d]