aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMattias Andrée <maandree@operamail.com>2014-10-12 05:35:14 +0200
committerMattias Andrée <maandree@operamail.com>2014-10-12 05:35:14 +0200
commitde23af9a8c9b9f8713e13f88a0a25cfd6614998b (patch)
tree9151d95f39ccfd0e5fd2f281d14aa048a02a6f12 /src
parentdist (diff)
downloadslack-de23af9a8c9b9f8713e13f88a0a25cfd6614998b.tar.gz
slack-de23af9a8c9b9f8713e13f88a0a25cfd6614998b.tar.bz2
slack-de23af9a8c9b9f8713e13f88a0a25cfd6614998b.tar.xz
m fix doc + add info manual and completion2
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to 'src')
-rw-r--r--src/completion11
-rw-r--r--src/slack.c4
2 files changed, 13 insertions, 2 deletions
diff --git a/src/completion b/src/completion
new file mode 100644
index 0000000..45637e5
--- /dev/null
+++ b/src/completion
@@ -0,0 +1,11 @@
+(slack
+ (default (arg VERB_INTERVAL_OR_COMMAND) (files -r) (suggest cmd)
+ (desc 'Specify which command to run'))
+
+ (unargumented (options --fatal)
+ (complete --fatal)
+ (desc 'Fail if the timer slack cannot be set'))
+
+ (suggestion cmd (verbatim get GET reset INTERVAL COMMAND))
+)
+
diff --git a/src/slack.c b/src/slack.c
index 7e829fc..1895e50 100644
--- a/src/slack.c
+++ b/src/slack.c
@@ -31,11 +31,11 @@
static void usage(void)
{
- printf("USAGE: slack (get | GET | (reset | <interval> <options...> [--fatal] [--] <command...>))\n");
+ printf("USAGE: slack (get | GET | ((reset | <interval>) [--fatal] [--] <command...>))\n");
printf("\n");
printf("The <interval> must be a positive number optionally with a suffix:\n");
printf(" ns n nanoseconds (default)\n");
- printf(" µs µ ns n microseconds\n");
+ printf(" µs µ us u microseconds\n");
printf(" ms m milliseconds\n");
printf(" s seconds\n");
printf("\n");