5.5. Enabling the command-line assistant to capture your terminal activity
You can use the command-line assistant powered by RHEL Lightspeed to reference commands that you previously ran.
警告
If you add terminal context in a request and there are no previously captured commands, the command will fail. You can only add context from the terminal while the capture mode is enabled.
Prerequisites
- You have installed the command-line assistant powered by RHEL Lightspeed. See the Installing the command-line assistant powered by RHEL Lightspeed documentation.
Procedure
Enable the terminal capture for your current terminal session:
$ c shell --enable-capture- Run at least one command before you reference previous commands.
Reference the output of a previously run command. For example, to reference the previous command, run:
$ c -w 1 "what_is_this"To reference the second to previous command, run:
$ c -w 2 "what_is_this"
- To stop terminal capture, press the Ctrl + D keys on your keyboard.: