mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
vim-patch:8.1.0308: a quick undo shows "1 seconds ago"
Problem: A quick undo shows "1 seconds ago". (Tony Mechelynck)
Solution: Add singular/plural message.
fd6100b2aa
This commit is contained in:
parent
ca49ae9e36
commit
e2f845632d
@ -2587,9 +2587,13 @@ static void u_add_time(char_u *buf, size_t buflen, time_t tt)
|
||||
else
|
||||
/* longer ago */
|
||||
(void)strftime((char *)buf, buflen, "%Y/%m/%d %H:%M:%S", &curtime);
|
||||
} else
|
||||
vim_snprintf((char *)buf, buflen, _("%" PRId64 " seconds ago"),
|
||||
(int64_t)(time(NULL) - tt));
|
||||
} else {
|
||||
int64_t seconds = time(NULL) - tt;
|
||||
vim_snprintf((char *)buf, buflen,
|
||||
NGETTEXT("%" PRId64 " second ago",
|
||||
"%" PRId64 " seconds ago", (uint32_t)seconds),
|
||||
seconds);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user