-
Notifications
You must be signed in to change notification settings - Fork 1
55 lines (46 loc) · 1.27 KB
/
generate-llms.yml
File metadata and controls
55 lines (46 loc) · 1.27 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
name: Generate LLMs files
on:
workflow_dispatch:
inputs:
environment:
description: 'Environment'
required: true
default: 'dev'
type: choice
options:
- dev
- prod
permissions:
contents: write
jobs:
generate:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: yarn
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Copy env file
run: |
if [ "${{ inputs.environment }}" = "prod" ]; then
echo "${{ secrets.ENV_PROD }}" | base64 -d > .env
else
echo "${{ secrets.ENV_DEV }}" | base64 -d > .env
fi
rm -f .env.local
- name: Generate llms-full-pages
run: yarn generate:llms:pages
- name: Commit and push generated files
run: |
git config user.name "github-actions"
git config user.email "github-actions@github.com"
git add public/uxcore_/
if ! git diff --cached --quiet; then
git commit -m "chore: regenerate llms pages"
git push
fi