File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ _comp_cmd_cryptsetup__device()
13
13
_comp_cmd_cryptsetup__action ()
14
14
{
15
15
local REPLY IFS=$' \t\n '
16
- _comp_dequote " $1 " || return 1
16
+ _comp_dequote " ${1-} " || return 1
17
17
local cmd=${REPLY:- cryptsetup}
18
18
local -a actions
19
19
_comp_split -l actions " $(
@@ -46,7 +46,7 @@ _comp_cmd_cryptsetup__action()
46
46
filtering_pattern=${filtering_pattern% $' \n ' }
47
47
48
48
local filtered_actions
49
- filtered_actions=$( strings " $path " | grep -Fx " $filtering_pattern " | sort -u) &&
49
+ filtered_actions=$( strings " $path " | command grep -Fx " $filtering_pattern " | sort -u) &&
50
50
[[ $filtered_actions ]] &&
51
51
_comp_split -l actions " $filtered_actions "
52
52
fi
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ def test_2(self, completion):
13
13
@pytest .mark .complete (
14
14
"cryptsetup luksE" ,
15
15
require_cmd = True ,
16
- skipif = '! strings "$(type -P cryptsetup)" | grep -qFx luksErase' ,
16
+ skipif = r '! { cryptsetup --help; man cryptsetup; } 2>/dev/null | command grep -qE "(^|[[:space:]]) luksErase([[:space:]]|\$)" ' ,
17
17
)
18
18
def test_github_issue758 (self , completion ):
19
19
assert completion == "rase"
You can’t perform that action at this time.
0 commit comments