summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2018-08-21 17:07:45 +0200
committerBram Moolenaar <Bram@vim.org>2018-08-21 17:07:45 +0200
commitfd6100b2aa6178b88cfadcdbc494966bf79a5488 (patch)
tree84eaf9a9ce4115b073c81c184d8d4694bfe0a1e5
parent0f6b4f06dece71487a6d8546c50de775d9c8c287 (diff)
downloadvim-git-fd6100b2aa6178b88cfadcdbc494966bf79a5488.tar.gz
patch 8.1.0308: a quick undo shows "1 seconds ago"v8.1.0308
Problem: A quick undo shows "1 seconds ago". (Tony Mechelynck) Solution: Add singular/plural message.
-rw-r--r--src/undo.c9
-rw-r--r--src/version.c2
2 files changed, 9 insertions, 2 deletions
diff --git a/src/undo.c b/src/undo.c
index 040ec5480..ebf18da49 100644
--- a/src/undo.c
+++ b/src/undo.c
@@ -3124,8 +3124,13 @@ u_add_time(char_u *buf, size_t buflen, time_t tt)
}
else
#endif
- vim_snprintf((char *)buf, buflen, _("%ld seconds ago"),
- (long)(vim_time() - tt));
+ {
+ long seconds = (long)(vim_time() - tt);
+
+ vim_snprintf((char *)buf, buflen,
+ NGETTEXT("%ld second ago", "%ld seconds ago", seconds),
+ seconds);
+ }
}
/*
diff --git a/src/version.c b/src/version.c
index bad2b3324..51ead8f5d 100644
--- a/src/version.c
+++ b/src/version.c
@@ -795,6 +795,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 308,
+/**/
307,
/**/
306,