Merge pull request #106 from lukasan/patch-2 #194
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
on: | |
push: | |
branches: | |
- "**" | |
- '!dev' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
name: Publish Website | |
steps: | |
- uses: actions/checkout@master | |
# Get branch | |
- name: Get Branch | |
shell: bash | |
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})" | |
id: extract_branch | |
# FTP Copy | |
- name: FTP Deploy | |
uses: SamKirkland/[email protected] | |
env: | |
FTP_SERVER: ${{ secrets.FTP_SERVER }} | |
FTP_USERNAME: ${{ secrets.FTP_USERNAME }} | |
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }} | |
REMOTE_DIR: site/wwwroot/docs/${{ steps.extract_branch.outputs.branch }} | |
ARGS: --delete | |
# --delete arg will delete files on the server if you've deleted them in | |
# Trigger Server Refresh | |
- name: Trigger Refresh | |
uses: fjogeleit/http-request-action@master | |
with: | |
url: 'https://piranhacms.org/api/reload/${{ steps.extract_branch.outputs.branch }}' | |
method: 'GET' |