Skip to content

Instantly share code, notes, and snippets.

@kaikousa
Created September 16, 2014 14:18
Show Gist options
  • Save kaikousa/bf5ead17f93e6dbc52a9 to your computer and use it in GitHub Desktop.
Save kaikousa/bf5ead17f93e6dbc52a9 to your computer and use it in GitHub Desktop.
Rsync selected files to a remote folder over SSH
#!/bin/sh
# Copy index.html and dist-folder to a remote folder. Exclude everything else
rsync -auv -e ssh --progress . --include=dist/*** --include=index.html --exclude=* user@example.com:/home/user/public_html/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment