File tree 2 files changed +27
-3
lines changed
2 files changed +27
-3
lines changed Original file line number Diff line number Diff line change @@ -66,11 +66,12 @@ _ssh_keygen()
66
66
no-x11-forwarding permit-agent-forwarding
67
67
permit-port-forwarding permit-pty permit-user-rc
68
68
permit-X11-forwarding no-touch-required source-address=
69
+ verify-required
69
70
70
71
lines= start-line= checkpoint= memory= start= generator=
71
72
72
- application challenge= device resident user
73
- write-attestation-path
73
+ application= challenge= device= no-touch-required resident
74
+ user= write-attestation=
74
75
' -- " $cur " ) )
75
76
[[ ${COMPREPLY-} == * [:= ] ]] && compopt -o nospace
76
77
__ltrim_colon_completions " $cur "
@@ -80,10 +81,17 @@ _ssh_keygen()
80
81
compopt -o filenames
81
82
COMPREPLY=($( compgen -c -- " ${cur#* =} " ) )
82
83
;;
83
- checkpoint=* | challenge=* )
84
+ checkpoint=* | challenge=* | write-attestation= * )
84
85
cur=${cur#* =}
85
86
_filedir
86
87
;;
88
+ application=* ([^:=]))
89
+ COMPREPLY=($( compgen -W " ssh:" -- " ${cur#* =} " ) )
90
+ compopt -o nospace
91
+ ;;
92
+ user=* )
93
+ COMPREPLY=($( compgen -u -- " ${cur#* =} " ) )
94
+ ;;
87
95
esac
88
96
fi
89
97
return
Original file line number Diff line number Diff line change @@ -69,3 +69,19 @@ def test_O_force_command(self, completion):
69
69
@pytest .mark .complete ("ssh-keygen -O unknown=" )
70
70
def test_O_unknown (self , completion ):
71
71
assert not completion
72
+
73
+ @pytest .mark .complete ("ssh-keygen -O application=" )
74
+ def test_O_application (self , completion ):
75
+ assert completion == "ssh:"
76
+
77
+ @pytest .mark .complete ("ssh-keygen -O application=s" )
78
+ def test_O_application_s (self , completion ):
79
+ assert completion == "sh:"
80
+
81
+ @pytest .mark .complete ("ssh-keygen -O application=ssh:" )
82
+ def test_O_application_ssh_colon (self , completion ):
83
+ assert not completion
84
+
85
+ @pytest .mark .complete ("ssh-keygen -O application=nonexistent" )
86
+ def test_O_application_nonexistent (self , completion ):
87
+ assert not completion
You can’t perform that action at this time.
0 commit comments