Commit 35b598ac38a3f8c378d48aaabfb266377ce1bbf3
Do not insert trailing space in shell completion
It makes it more inconvenient to type multiple key-value pairs in
succession.
Author: xaizek
Author date (UTC): 2018-10-31 18:12
Committer name: xaizek
Committer date (UTC): 2018-10-31 18:12
Parent(s): 36446323a283f5aaa313a85bf2073df0e923f67a
Signing key: 99DC5E4DB05F6BE2
Tree: ff2ba621558ce1c466650d90b1b4e2807215c804
File scripts/bash-completion changed (mode: 100755 -> 100644) (index 534cf16..1f8606f) |
... |
... |
function _dit() |
10 |
10 |
local cur="${args[-1]}" |
local cur="${args[-1]}" |
11 |
11 |
cur="${cur:0:-10}" |
cur="${cur:0:-10}" |
12 |
12 |
|
|
|
13 |
|
# do not innsert trailing space |
|
14 |
|
compopt -o nospace |
|
15 |
|
|
13 |
16 |
if [ "${COMP_LINE:$(( $COMP_POINT - 1 ))}" = '=' ]; then |
if [ "${COMP_LINE:$(( $COMP_POINT - 1 ))}" = '=' ]; then |
14 |
17 |
# try to fix issues related to use of = as a word separator (this is |
# try to fix issues related to use of = as a word separator (this is |
15 |
18 |
# a readline setting, which we can't control per command completion) |
# a readline setting, which we can't control per command completion) |