I'm using git bash on windows and was wondering how I can stop the terminal asking for more input following a pipe (typed by accident). I know it's unusual to type piped commands this way, but I'm trying to simulate certain actions a bash style terminal can do.
For example, my input looks like this:
zecuse MINGW64 ~/source/repos/Sim $ echo test | > echo here| (pipe typed by accident) > (enter key was pressed) > (the caret is sitting here waiting for another command)
The output for this chain of commands should only result in
here being typed to the terminal since I didn't redirect the first echo. However, I don't know what should be typed after the accidental pipe to stop accepting input and run the commands.
bash: syntax error near unexpected token ';'
ctrl+c= killing the command so nothing happens. I thought this might happen.
bash: syntax error: unexpected end of file
Is there a keyboard shortcut or an "empty" command that does nothing for this?
: suggestion from @Jesse_b's answer worked perfect and after looking up about I/O redirection I was able to get everything to appear in the terminal as I expected it. I'm making echo write to a string for some context about the project and am using git bash as a way to test what happens.
$ echo test >&0 | > echo here >&2| > :