You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

13 lines
243 B

#!/bin/bash
set -e -u
remote="$1"
url="$2"
echo "[deploy] updating post-receive hook"; {
ssh_host=$(echo $url | cut -d'/' -f3)
ssh_path=$(echo $url | cut -d'/' -f4-)
scp hooks/post-receive ${ssh_host}:${ssh_path}/hooks/post-receive
}