mirror of
https://github.com/SquidDev-CC/CC-Tweaked
synced 2024-12-15 04:30:29 +00:00
b91809bfc7
Also fix make-doc.sh uploading the wrong file.
20 lines
558 B
Bash
Executable File
20 lines
558 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set -eu
|
|
|
|
DEST="${GITHUB_REF#refs/*/}"
|
|
echo "Uploading docs to https://tweaked.cc/$DEST"
|
|
|
|
# Setup ssh key
|
|
mkdir -p "$HOME/.ssh/"
|
|
echo "$SSH_KEY" > "$HOME/.ssh/key"
|
|
chmod 600 "$HOME/.ssh/key"
|
|
|
|
# And upload
|
|
rsync -avc -e "ssh -i $HOME/.ssh/key -o StrictHostKeyChecking=no -p $SSH_PORT" \
|
|
"$GITHUB_WORKSPACE/build/docs/site/" \
|
|
"$SSH_USER@$SSH_HOST:/$DEST"
|
|
rsync -avc -e "ssh -i $HOME/.ssh/key -o StrictHostKeyChecking=no -p $SSH_PORT" \
|
|
"$GITHUB_WORKSPACE/build/docs/javadoc/" \
|
|
"$SSH_USER@$SSH_HOST:/$DEST/javadoc"
|