Tuesday, June 25, 2019

Transfer file through ssh connection using cat pipe

cat z.cpp | ssh user@hostname 'cat > /remote_folder/copy_of_z.cpp'

ssh user@hostname 'cat /remote_folder/copy_of_z.cpp' > z.cpp

No comments:

Blog Archive