diff options
author | ridiculousfish <corydoras@ridiculousfish.com> | 2014-01-25 15:22:28 -0800 |
---|---|---|
committer | ridiculousfish <corydoras@ridiculousfish.com> | 2014-01-25 15:22:28 -0800 |
commit | 2139334c36a0f169a129ae9dfb0be5bd3e07854b (patch) | |
tree | c975266560eef6bf2c1602aba4bef770563d584d /share/functions/down-or-search.fish | |
parent | 67bb12e569d110b4b32122c6e562c3988382e8c8 (diff) |
Fix for issue where wc on OS X would produce leading spaces, causing
down-or-search to fail to match the case statement and therefore do the wrong thing.
Diffstat (limited to 'share/functions/down-or-search.fish')
-rw-r--r-- | share/functions/down-or-search.fish | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/share/functions/down-or-search.fish b/share/functions/down-or-search.fish index 3f775bfb..8bacfb4c 100644 --- a/share/functions/down-or-search.fish +++ b/share/functions/down-or-search.fish @@ -9,7 +9,7 @@ function down-or-search -d "Depending on cursor position and current mode, eithe # If we are on the bottom line, start search mode, # otherwise move down set lineno (commandline -L) - set line_count (commandline|wc -l) + set line_count (commandline | wc -l | tr -d ' ') switch $lineno case $line_count |