-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (50 loc) · 1.55 KB
/
Copy pathmain.yml
File metadata and controls
61 lines (50 loc) · 1.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: CI
on:
push:
branches: [master]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: cachix/install-nix-action@v31
- uses: cachix/cachix-action@v16
with:
name: cv-maxdaten-io
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
- name: Install devenv.sh
run: nix profile add nixpkgs#devenv
- name: Install Playwright system dependencies
run: npx playwright install-deps chromium
- name: Install shot-scraper and Playwright
run: |
pip install shot-scraper
shot-scraper install
- name: Build CV core (optimize images, pages)
run: devenv shell just build-core
- name: Generate OG image
run: shot-scraper shot src/templates/og-card.html -w 1200 -h 630 -o build/img/og-card.png
- name: Generate screenshots
run: |
sed "s|APP_PATH|$(pwd)|g" screenshots.yml > /tmp/screenshots-resolved.yml
shot-scraper multi /tmp/screenshots-resolved.yml --retina
- name: Upload pages
uses: actions/upload-artifact@v6.0.0
with:
name: pages
path: build
deploy:
runs-on: ubuntu-latest
needs: [build]
steps:
- name: Download artifact
uses: actions/download-artifact@v7.0.0
with:
name: pages
path: build
- name: GitHub Pages
uses: crazy-max/ghaction-github-pages@v4.2.0
with:
build_dir: build
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}