此内容没有您所选择的语言版本。
Chapter 2. Configuring the CLI
2.1. Enabling tab completion 复制链接链接已复制到粘贴板!
复制链接链接已复制到粘贴板!
After you install the oc CLI tool, you can enable tab completion to automatically complete oc commands or suggest options when you press Tab.
Prerequisites
-
You must have the
ocCLI tool installed.
Procedure
The following procedure enables tab completion for Bash.
Save the Bash completion code to a file.
$ oc completion bash > oc_bash_completionCopy the file to
/etc/bash_completion.d/.$ sudo cp oc_bash_completion /etc/bash_completion.d/You can also save the file to a local directory and source it from your
.bashrcfile instead.
Tab completion is enabled when you open a new terminal.