I'm trying to execute commands in a heredoc block SSH session using something like this:
ssh -tt user@domain << 'END' > ./file.txt
some command
END
The command is executed and saved a portion of the output at file.txt. The problem is that the program prompt for an ENTER or space to continue showing the output (the entire output have thousands of lines)
How Can I send one or more ENTER after the first command? I tried using some command\n\n\n but doesn't works.