-
-
Notifications
You must be signed in to change notification settings - Fork 728
37 lines (36 loc) · 1.11 KB
/
ci.yml
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
name: CI
on:
pull_request_target:
types: [labeled]
jobs:
build:
name: Build and preview site
runs-on: ubuntu-latest
if: contains(github.event.pull_request.labels.*.name, 'preview')
steps:
- uses: actions/checkout@v1
with:
ref: "refs/pull/${{ github.event.number }}/merge" # THIS IS INSECURE
- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: '3.X'
- name: Install dependencies
run: |
pip install --upgrade pip
pip install --upgrade setuptools wheel
pip install -r requirements.txt
lektor plugins reinstall
- name: Clean
run : |
lektor clean -O output --yes
- name: Build site
run: |
lektor build --prune -O output
# Generated from 'firebase init hosting'
- name: Deploy preview
uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: '${{ secrets.GITHUB_TOKEN }}'
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_BEEWARE_ORG }}'
projectId: beeware-org