Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH 5/5: _strftime: Add completion for zsh/datetime's strftime builtin
- X-seq: zsh-workers 36119
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: PATCH 5/5: _strftime: Add completion for zsh/datetime's strftime builtin
- Date: Wed, 12 Aug 2015 05:05:03 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id:in-reply-to:references; bh=aa6lpxAPJZBuRyhO2jw4Ig9JdorYuQ44wksII2DwWow=; b=SsBmGgv0/AeHZ1n06iVDunz+kgsjVE7JiZ2zrUtnFXtbs6hTvHIS48Nk5xUMa04HQM /JgoE7fjl0MuTVInKYiO42pAr8kBsT/yQoT8o7GsYE/eLLvPrDBKujf8DD4Zds9bQ/7z j8NMtx04eaS03w+/K2/109dbuvz0ZkslrY5GhlKuQmRppj6YweJstAbsKD3uxCavSvqb BXf7Gj1Up4oxAbMzK2I+o8oXjBKM5oPA3Tk14Oxq5H9lQLJzayvamYwe1Ri5+OMLjTQY alcBwVRXIFgyICOJ9l9R2CmJywOKDOaITFkR4MJzzXDQ61ejyZalqijN2MKhLCX0pc20 4dZQ==
- In-reply-to: <1439348703-8268-1-git-send-email-mikachu@gmail.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <1439348703-8268-1-git-send-email-mikachu@gmail.com>
---
Completion/Zsh/Command/_strftime | 12 ++++++++++++
1 file changed, 12 insertions(+)
create mode 100644 Completion/Zsh/Command/_strftime
diff --git a/Completion/Zsh/Command/_strftime b/Completion/Zsh/Command/_strftime
new file mode 100644
index 0000000..0be7b07
--- /dev/null
+++ b/Completion/Zsh/Command/_strftime
@@ -0,0 +1,12 @@
+#compdef strftime
+
+local ret=1 expl
+
+_arguments -S -A '-*' -s \
+ '-q[run quietly]' \
+ '-r[reverse lookup using strptime]' \
+ '-s+[assign result to parameter]:param:_parameters' \
+ '1:format: _date_formats' \
+ '2:epoch time (or date string with -r)' && ret=0
+
+return ret
--
2.4.0
Messages sorted by:
Reverse Date,
Date,
Thread,
Author