Skip to content

2024 Edition

2024 Edition #273

Workflow file for this run

name: Build
on:
push:
branches: [master]
pull_request:
branches: [master]
#schedule:
# Update automatically on weekdays during work hours
#- cron: '0 10,13,16 * * 1-5'
# ... and every night
#- cron: '0 0 * * *'
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: pip
- uses: pre-commit/[email protected]
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.12"
- uses: astral-sh/setup-uv@v3
with:
version: "0.4.x"
enable-cache: true
cache-dependency-glob: "**/requirements*.txt"
- name: Install dependencies
run: uv pip install -r requirements.txt
- name: Build
run: make -j3
- uses: actions/setup-node@v4
with:
node-version: "20"
cache: yarn
cache-dependency-path: analysaattori/yarn.lock
- run: yarn
working-directory: analysaattori
- run: yarn build -- --base=/palkkakysely/analysaattori/
working-directory: analysaattori
env:
GENERATE_SOURCEMAP: "false"
- run: cp -a analysaattori/dist ./out/analysaattori
- run: ls -laR out
- run: touch out/.nojekyll
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
branch: gh-pages
folder: out
clean: false
if: ${{ github.event_name == 'push' }}
env:
GIT_AUTHOR_EMAIL: "[email protected]"
GIT_AUTHOR_NAME: "Koodiklinikka Robot"
GIT_COMMITTER_EMAIL: "[email protected]"
GIT_COMMITTER_NAME: "Koodiklinikka Robot"