Skip to content

Pre Deploy

Pre Deploy #243

Workflow file for this run

# Simple workflow for deploying static content to GitHub Pages
name: Pre Deploy
on:
# Runs on pushes targeting the default branch
push:
branches: ["main"]
schedule:
- cron: "0 8 * * *"
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions: write-all
jobs:
# Single deploy job since we're just deploying
pre-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
# Environment
- name: Setup Py 3.10
uses: actions/setup-python@v4
with:
python-version: "3.10"
- name: Set Up Node.js 16
uses: actions/setup-node@v3
with:
node-version: 16
- name: Install Prettier
run: npm i -g prettier
# Pre deploy
- name: Run pre-deploy.sh
run: sh scripts/pre-deploy.sh
- name: Format with Prettier
run: prettier -c -w .
- name: Commit changes
run: |
git config user.name github-actions[bot]
git config user.email github-actions[bot]@users.noreply.github.com
git commit -m "pre deploy" -a || exit 0
git push