in bash I have got something like this:
$ <cmd> <arg1> input_file_123.txt > ouput_file_123.txt
I want to reuse input_file_123.txt
to name the output file but replace let's say "input" with "output".
I found this: How can I recall the argument of the previous bash command?,
tried this:
$ <cmd> <arg1> input_file_123.txt > !$:s/input/output
but it says "substitution failed".
I would need it to be a one-liner I can use within a jupyter notebook.
Thx for your help!