Skip to content

Merge pull request #5 from MHaggis/main #1

Merge pull request #5 from MHaggis/main

Merge pull request #5 from MHaggis/main #1

Workflow file for this run

name: Generate Site
on:
push:
branches:
- master
- main
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Generate MD
run: python bin/generate_md.py
- name: Commit and push if it changed
run: |
git diff
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git commit -m "Generate markdown files" -a || echo "No changes to commit"
git push
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Deploy to GitHub Pages
run: |
cd HackerArt-io
mkdocs gh-deploy --force