From man bash
,
history -p arg [arg ...]
...
-p
Perform history substitution on the following args and display the result on the standard output.
What does 'history substitution' mean here? Can you provide an example of its use?
Thanks.
I understand command line history substitution, and already tried things like this:
history -p "!23:1"
But this is not dependent on -p, as xx "!23:1"
does the same thing.
set +H; echo !23; history -p !23
-- re-enable history expansion withset -H