Skip to content

workflow: delete files not in the build #52

workflow: delete files not in the build

workflow: delete files not in the build #52

Workflow file for this run

name: Publish Site
on:
push:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install SSH Key
uses: shimataro/ssh-key-action@v2
with:
key: ${{ secrets.SSH_KEY }}
known_hosts: 'placeholder'
- name: Adding Known Hosts
run: ssh-keyscan -H ${{ secrets.SSH_HOST }} >> ~/.ssh/known_hosts
- name: Setup Build Env
run: |
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash
. ~/.nvm/nvm.sh
nvm install 18.14.2
nvm use 18.14.2
- name: Install dependencies
run: npm install
- name: Build site
run: npm run-script build
env:
VECTO_PUBLIC_TOKEN: ${{ secrets.VECTO_PUBLIC_TOKEN }}
VECTO_USER_TOKEN: ${{ secrets.VECTO_USER_TOKEN }}
VECTOR_SPACE_ID: ${{ secrets.VECTOR_SPACE_ID }}
- name: Copying to xircuits.io
run: rsync -r -v --delete build/* ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }}:/var/www/xircuits.io/