From c90279b67723597667eb274acc8ef267f0b0f9f4 Mon Sep 17 00:00:00 2001 From: skywind3000 Date: Sat, 31 Oct 2020 18:59:03 +0800 Subject: [PATCH] expose '--add' in cmd.exe --- z.cmd | 6 ++++++ z.lua | 7 ++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/z.cmd b/z.cmd index 54046e6..b917f5f 100644 --- a/z.cmd +++ b/z.cmd @@ -54,6 +54,12 @@ if /i "%1"=="-x" ( goto parse ) +if /i "%1"=="--add" ( + set "RunMode=--add" + shift /1 + goto parse +) + if "%1"=="-i" ( set "InterMode=-i" shift /1 diff --git a/z.lua b/z.lua index 1d56fa5..dc3a75a 100755 --- a/z.lua +++ b/z.lua @@ -4,7 +4,7 @@ -- z.lua - a cd command that learns, by skywind 2018, 2019, 2020 -- Licensed under MIT license. -- --- Version 1.8.7, Last Modified: 2020/06/29 18:04 +-- Version 1.8.8, Last Modified: 2020/10/31 18:58 -- -- * 10x faster than fasd and autojump, 3x faster than z.sh -- * available for posix shells: bash, zsh, sh, ash, dash, busybox @@ -2502,6 +2502,11 @@ if /i "%1"=="-x" ( shift /1 goto parse ) +if /i "%1"=="--add" ( + set "RunMode=--add" + shift /1 + goto parse +) if "%1"=="-i" ( set "InterMode=-i" shift /1