Skip to content

Commit

Permalink
Correct log message when account locked
Browse files Browse the repository at this point in the history
  • Loading branch information
pepa65 committed Dec 3, 2023
1 parent 78f3e75 commit 1fe8597
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
[![GitHub](https://img.shields.io/github/license/pepa65/m2m.svg)](LICENSE)
# m2m - Move from POP3 to Maildir

* **v1.12.2**
* **v1.13.0**
* License: GPLv3+
* Just pull mails from POP3 servers (TLS can be disabled) and put them in local Maildirs.
* Proxies and Onion entry servers are supported.
Expand Down Expand Up @@ -41,7 +41,7 @@

## Help
```
m2m v1.12.2 - Move from POP3 to Maildir
m2m v1.13.0 - Move from POP3 to Maildir
* Downloading emails from POP3 servers and moving them into Maildir folders.
* Repo: github.com/pepa65/m2m
* Usage: m2m [ -h|--help | -q|--quiet ]
Expand Down
8 changes: 6 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"gopkg.in/yaml.v2"
)

const version = "1.12.2"
const version = "1.13.0"

type Config struct {
Username string
Expand Down Expand Up @@ -130,7 +130,10 @@ func main() { // I:accounts O:self,home IO:wg
mails := false
logline := time.Now().Format("2006-01-02_15:04:05 ")
for _, file := range files {
if n := accounts[file]; n != "" {
n := accounts[file]
if n == "." {
logline += file + ": locked"
} else if n != "" {
logline += file + ": " + n + " "
if n != "0" {
mails = true
Expand Down Expand Up @@ -158,6 +161,7 @@ func check(account string, m2mdir string, quiet bool) { // I:home O:accounts IO:
file, err := os.Open(lockfile)
if err == nil { // Account locked: skip
file.Close()
accounts[account] = "."
return
}

Expand Down

0 comments on commit 1fe8597

Please sign in to comment.