Skip to content

Commit f3af62b

Browse files
Tao ChenAlexei Starovoitov
authored andcommitted
bpftool: Add bash completion for token argument
This commit updates the bash completion script with the new token argument. $ bpftool token help list show Reviewed-by: Quentin Monnet <[email protected]> Signed-off-by: Tao Chen <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Alexei Starovoitov <[email protected]>
1 parent b7f6400 commit f3af62b

File tree

1 file changed

+11
-0
lines changed
  • tools/bpf/bpftool/bash-completion

1 file changed

+11
-0
lines changed

tools/bpf/bpftool/bash-completion/bpftool

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1215,6 +1215,17 @@ _bpftool()
12151215
;;
12161216
esac
12171217
;;
1218+
token)
1219+
case $command in
1220+
show|list)
1221+
return 0
1222+
;;
1223+
*)
1224+
[[ $prev == $object ]] && \
1225+
COMPREPLY=( $( compgen -W 'help show list' -- "$cur" ) )
1226+
;;
1227+
esac
1228+
;;
12181229
esac
12191230
} &&
12201231
complete -F _bpftool bpftool

0 commit comments

Comments
 (0)