Created
April 5, 2020 05:42
-
-
Save takakd/23c1cf2dc643bd223bb751fe42429cfc to your computer and use it in GitHub Desktop.
scp command.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# Required: macOS 10.14.5 | |
# copy local to remote | |
$ scp -i ~/.ssh/id_rsa -r /home/localuser/local_dir sshuser@<ip>:/home/remoteuser/dir_placed_local_dir/ | |
# copy remote to local | |
$ scp -i ~/.ssh/id_rsa -r sshuser@<ip>:/home/remoteuser/remote_dir /home/localuser/dir_placed_remote_dir/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment