diff options
author | romkatv <roman.perepelitsa@gmail.com> | 2019-11-05 15:09:51 +0300 |
---|---|---|
committer | romkatv <roman.perepelitsa@gmail.com> | 2019-11-05 15:09:51 +0300 |
commit | 8231995ed55640d994eeb97f79b1dae363fedda1 (patch) | |
tree | 5c18bed97482e65679e15f4a61b8ccb537949c45 /gitstatus | |
parent | d4265ab2794145d6550ab6c877f3aef5319bbf58 (diff) | |
parent | 4586e8d54c40fb6bd688128101ea5c853e34773b (diff) |
Merge branch 'master' into dynamic
Diffstat (limited to 'gitstatus')
-rwxr-xr-x | gitstatus/bin/gitstatusd-android-aarch64 | bin | 1076696 -> 1084840 bytes | |||
-rwxr-xr-x | gitstatus/bin/gitstatusd-cygwin_nt-10.0-x86_64 | bin | 2167296 -> 2176512 bytes | |||
-rwxr-xr-x | gitstatus/bin/gitstatusd-darwin-x86_64 | bin | 2095092 -> 2091052 bytes | |||
-rwxr-xr-x | gitstatus/bin/gitstatusd-freebsd-amd64 | bin | 3268488 -> 3272552 bytes | |||
-rwxr-xr-x | gitstatus/bin/gitstatusd-linux-aarch64 | bin | 2286400 -> 2278160 bytes | |||
-rwxr-xr-x | gitstatus/bin/gitstatusd-linux-armv7l | bin | 1877556 -> 1885724 bytes | |||
-rwxr-xr-x | gitstatus/bin/gitstatusd-linux-x86_64 | bin | 2340104 -> 2335976 bytes | |||
-rwxr-xr-x | gitstatus/bin/gitstatusd-linux-x86_64-static | bin | 2065632 -> 2065600 bytes | |||
-rwxr-xr-x | gitstatus/bin/gitstatusd-msys_nt-10.0-x86_64 | bin | 0 -> 2004992 bytes | |||
-rw-r--r-- | gitstatus/gitstatus.plugin.zsh | 30 |
10 files changed, 23 insertions, 7 deletions
diff --git a/gitstatus/bin/gitstatusd-android-aarch64 b/gitstatus/bin/gitstatusd-android-aarch64 Binary files differindex e9b22e72..cdea703e 100755 --- a/gitstatus/bin/gitstatusd-android-aarch64 +++ b/gitstatus/bin/gitstatusd-android-aarch64 diff --git a/gitstatus/bin/gitstatusd-cygwin_nt-10.0-x86_64 b/gitstatus/bin/gitstatusd-cygwin_nt-10.0-x86_64 Binary files differindex a1baa948..0568ca78 100755 --- a/gitstatus/bin/gitstatusd-cygwin_nt-10.0-x86_64 +++ b/gitstatus/bin/gitstatusd-cygwin_nt-10.0-x86_64 diff --git a/gitstatus/bin/gitstatusd-darwin-x86_64 b/gitstatus/bin/gitstatusd-darwin-x86_64 Binary files differindex dab60fc7..17b0ddcf 100755 --- a/gitstatus/bin/gitstatusd-darwin-x86_64 +++ b/gitstatus/bin/gitstatusd-darwin-x86_64 diff --git a/gitstatus/bin/gitstatusd-freebsd-amd64 b/gitstatus/bin/gitstatusd-freebsd-amd64 Binary files differindex de7e0f24..f164a48e 100755 --- a/gitstatus/bin/gitstatusd-freebsd-amd64 +++ b/gitstatus/bin/gitstatusd-freebsd-amd64 diff --git a/gitstatus/bin/gitstatusd-linux-aarch64 b/gitstatus/bin/gitstatusd-linux-aarch64 Binary files differindex b99ecfee..af762125 100755 --- a/gitstatus/bin/gitstatusd-linux-aarch64 +++ b/gitstatus/bin/gitstatusd-linux-aarch64 diff --git a/gitstatus/bin/gitstatusd-linux-armv7l b/gitstatus/bin/gitstatusd-linux-armv7l Binary files differindex 3d301aa9..bef8cc66 100755 --- a/gitstatus/bin/gitstatusd-linux-armv7l +++ b/gitstatus/bin/gitstatusd-linux-armv7l diff --git a/gitstatus/bin/gitstatusd-linux-x86_64 b/gitstatus/bin/gitstatusd-linux-x86_64 Binary files differindex 5538aa05..8f10274d 100755 --- a/gitstatus/bin/gitstatusd-linux-x86_64 +++ b/gitstatus/bin/gitstatusd-linux-x86_64 diff --git a/gitstatus/bin/gitstatusd-linux-x86_64-static b/gitstatus/bin/gitstatusd-linux-x86_64-static Binary files differindex b561edd9..46466532 100755 --- a/gitstatus/bin/gitstatusd-linux-x86_64-static +++ b/gitstatus/bin/gitstatusd-linux-x86_64-static diff --git a/gitstatus/bin/gitstatusd-msys_nt-10.0-x86_64 b/gitstatus/bin/gitstatusd-msys_nt-10.0-x86_64 Binary files differnew file mode 100755 index 00000000..f74138e3 --- /dev/null +++ b/gitstatus/bin/gitstatusd-msys_nt-10.0-x86_64 diff --git a/gitstatus/gitstatus.plugin.zsh b/gitstatus/gitstatus.plugin.zsh index d64421db..e8e8d624 100644 --- a/gitstatus/gitstatus.plugin.zsh +++ b/gitstatus/gitstatus.plugin.zsh @@ -273,10 +273,19 @@ function _gitstatus_process_response() { # -d INT Report at most this many untracked files; negative value means infinity. # Defaults to 1. # -# -m INT If a repo has more files in its index than this, override -u and -d (but not -s) -# with zeros. Negative value means infinity. Defaults to -1. +# -m INT Report -1 unstaged, untracked and conflicted if there are more than this many +# files in the index. Negative value means infinity. Defaults to -1. # # -e Count files within untracked directories like `git status --untracked-files`. +# +# -U Unless this option is specified, report zero untracked files for repositories +# with status.showUntrackedFiles = false. +# +# -W Unless this option is specified, report zero untracked files for repositories +# with bash.showUntrackedFiles = false. +# +# -D Unless this option is specified, report zero staged, unstaged and conflicted +# changes for repositories with bash.showDirtyState = false. function gitstatus_start() { emulate -L zsh setopt err_return no_unset no_bg_nice @@ -289,9 +298,9 @@ function gitstatus_start() { local -i max_num_untracked=1 local -i dirty_max_index_size=-1 local -i async - local recurse_untracked_dirs + local -a extra_flags=() while true; do - getopts "t:s:u:c:d:m:ea" opt || break + getopts "t:s:u:c:d:m:eaUWD" opt || break case $opt in a) async=1;; t) timeout=$OPTARG;; @@ -300,8 +309,14 @@ function gitstatus_start() { c) max_num_conflicted=$OPTARG;; d) max_num_untracked=$OPTARG;; m) dirty_max_index_size=$OPTARG;; - e) recurse_untracked_dirs='--recurse-untracked-dirs';; - +e) recurse_untracked_dirs=;; + e) extra_flags+='--recurse-untracked-dirs';; + +e) extra_flags=(${(@)extra_flags:#--recurse-untracked-dirs});; + U) extra_flags+='--ignore-status-show-untracked-files';; + +U) extra_flags=(${(@)extra_flags:#--ignore-status-show-untracked-files});; + W) extra_flags+='--ignore-bash-show-untracked-files';; + +W) extra_flags=(${(@)extra_flags:#--ignore-bash-show-untracked-files});; + D) extra_flags+='--ignore-bash-show-dirty-state';; + +D) extra_flags=(${(@)extra_flags:#--ignore-bash-show-dirty-state});; ?) return 1;; esac done @@ -346,6 +361,7 @@ function gitstatus_start() { [[ -n $daemon ]] || { os="$(uname -s)" && [[ -n $os ]] [[ $os != Linux || "$(uname -o)" != Android ]] || os=Android + [[ $os != (MINGW64_NT-10.0|MSYS_NT-10.0-*) ]] || os=MSYS_NT-10.0 local arch && arch="$(uname -m)" && [[ -n $arch ]] daemon=$_gitstatus_plugin_dir/bin/gitstatusd-${os:l}-${arch:l} } @@ -380,7 +396,7 @@ function gitstatus_start() { --max-num-untracked=${(q)max_num_untracked} --dirty-max-index-size=${(q)dirty_max_index_size} --log-level=${(q)log_level:-INFO} - $recurse_untracked_dirs) + $extra_flags) local cmd=" exec >&4 |