Skip to content

Commit 5670fed

Browse files
Merge pull request #6 from imprakharshukla/dev
updated netlify deployment
2 parents 5bb5144 + 2014ac8 commit 5670fed

File tree

3 files changed

+49
-2
lines changed

3 files changed

+49
-2
lines changed

.github/workflows/chrome-e2e.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ on:
33
push:
44
branches:
55
- dev
6-
- master
76

87
jobs:
98
test:
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Dev Deploy
2+
on:
3+
push:
4+
branches:
5+
- dev
6+
pull_request:
7+
branches:
8+
- master
9+
jobs:
10+
deploy:
11+
runs-on: ubuntu-latest
12+
name: Build
13+
steps:
14+
- name: Checking out code ⚡
15+
uses: actions/checkout@v2
16+
17+
- name: Setting up NodeJS 📐
18+
uses: actions/setup-node@v1
19+
with:
20+
node-version: '14.x'
21+
22+
- name: Caching Dependencies 💾
23+
uses: actions/cache@v1
24+
with:
25+
path: ~/.npm
26+
key: ${{ runner.os }}-node-${{ hashFiles('**/yarn-lock.json') }}
27+
restore-keys: |
28+
${{ runner.os }}-node-
29+
30+
- name: Building 🏗
31+
run: |
32+
npm install -g yarn
33+
yarn install --frozen-lockfile
34+
yarn install
35+
yarn run generate
36+
37+
- name: Deploy to Netlify ✅
38+
uses: nwtgck/[email protected]
39+
with:
40+
publish-dir: './dist'
41+
production-branch: master
42+
github-token: ${{ secrets.GITHUB_TOKEN }}
43+
deploy-message: "Deploy from GitHub Actions"
44+
production-deploy: false
45+
env:
46+
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
47+
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}

.github/workflows/netlify-deploy.yaml renamed to .github/workflows/netlify-prod-deploy.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Deploy
1+
name: Production Deploy
22
on:
33
push:
44
branches:
@@ -38,6 +38,7 @@ jobs:
3838
production-branch: master
3939
github-token: ${{ secrets.GITHUB_TOKEN }}
4040
deploy-message: "Deploy from GitHub Actions"
41+
production-deploy: true
4142
env:
4243
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
4344
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}

0 commit comments

Comments
 (0)