-
Notifications
You must be signed in to change notification settings - Fork 39
50 lines (40 loc) · 1.13 KB
/
firebase-deploy.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
38
39
40
41
42
43
44
45
46
47
48
49
50
name: Firebase deploy
on:
push:
branches:
- main
permissions:
actions: read
contents: read
jobs:
deoploy:
name: Deploy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-node@v4
with:
node-version: 20
cache: "npm"
- run: npm ci --legacy-peer-deps
- uses: nrwl/nx-set-shas@v4
- run: npm run lint:all:fix
- name: Check for Lint Fixes
run: |
if [[ $(git status --porcelain) ]]; then
echo "Error: Linting caused changes in files. Please commit these changes."
git status --short # Show which files were changed
exit 1 # Exit with error code
else
echo "Linting completed with no changes."
fi
- run: npm run build:functions
# App Hosting is deployed with Google Cloud Build
- name: Deploy everything except for hosting
uses: w9jds/firebase-action@master
with:
args: deploy --except hosting
env:
GCP_SA_KEY: ${{ secrets.FIREBASE_DEPLOY_SA }}