I have an ssh connection and I have to send some local files and output to the ssh server.
I know I can do this using the following command
tar zcf - stuff | ssh user@server 'tar zxf -'
I would like to set it up in sequence using the && operator. I already have a connection and I don't want to relogin for every pipe, since I'll be using only one at a time.
Just to clarify I'm not just moving tarballs over the network but also input from devices collected from time to time as the pipeline opens. Just to stop people from saying: "why don't you use this program to move your file over the internet" or "you could also use a usb drive to transfer those files"