Skip to content

Commit

Permalink
Update push-event.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Aditya-Sihmar authored Jan 11, 2021
1 parent 4a5e9c7 commit 234d38a
Showing 1 changed file with 8 additions and 57 deletions.
65 changes: 8 additions & 57 deletions .github/workflows/push-event.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ jobs:
node-version: "12.x"

# Install all dependencies
- run: cd frontend
- run: npm install
- run: pwd
# This triggers `gatsby build` script in "package.json"
Expand All @@ -42,7 +41,7 @@ jobs:
github-token: ${{ secrets.GITHUB_TOKEN }}
netlify-auth-token: ${{ secrets.NETLIFY_AUTH_TOKEN }}
netlify-site-id: ${{ secrets.NETLIFY_SITE_ID }}
build-dir: 'frontend/build'
build-dir: './build'
draft: true
comment-on-pull-request: true

Expand All @@ -64,44 +63,18 @@ jobs:
node-version: "12.x"

# Install all dependencies
- run: cd ./frontend && npm install
- run: cd ./frontend && pwd
- run: npm install
- run: pwd
# This triggers `gatsby build` script in "package.json"
# - run: cd ./frontend && npm install --save
- run: cd ./frontend && npm run build
- run: npm run build

- name: Deploy draft to Netlify on push
uses: South-Paw/[email protected]
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
netlify-auth-token: ${{ secrets.NETLIFY_AUTH_TOKEN }}
netlify-site-id: ${{ secrets.NETLIFY_SITE_ID }}
build-dir: '.frontend/build'
draft: true
comment-on-commit: true

# - name: Checkout repository
# uses: actions/checkout@v1

# # Build steps for gatsby build
# - name: Setup Node
# uses: actions/setup-node@v1
# with:
# node-version: "12.x"

# Install all dependencies
#- run: cd frontend
- run: npm install
- run: pwd
# This triggers `gatsby build` script in "package.json"
- run: npm start

- name: Deploy draft to Netlify on push
uses: South-Paw/[email protected]
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
netlify-auth-token: ${{ secrets.NETLIFY_AUTH_TOKEN_1 }}
netlify-site-id: ${{ secrets.NETLIFY_SITE_ID_1 }}
build-dir: './build'
draft: true
comment-on-commit: true
Expand All @@ -118,29 +91,6 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v1

# Build steps for gatsby build
- name: Setup Node
uses: actions/setup-node@v1
with:
node-version: "12.x"

# Install all dependencies
- run: cd ./frontend && npm install
- run: cd ./frontend && pwd
# This triggers `gatsby build` script in "package.json"
- run: cd ./frontend && npm run build

- name: Deploy production to Netlify
uses: South-Paw/[email protected]
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
netlify-auth-token: ${{ secrets.NETLIFY_AUTH_TOKEN }}
netlify-site-id: ${{ secrets.NETLIFY_SITE_ID }}
build-dir: '.frontend/build'

- name: Checkout repository
uses: actions/checkout@v1

# Build steps for gatsby build
- name: Setup Node
uses: actions/setup-node@v1
Expand All @@ -151,12 +101,13 @@ jobs:
- run: npm install
- run: pwd
# This triggers `gatsby build` script in "package.json"
- run: npm start
- run: npm run build

- name: Deploy production to Netlify
uses: South-Paw/[email protected]
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
netlify-auth-token: ${{ secrets.NETLIFY_AUTH_TOKEN_1 }}
netlify-site-id: ${{ secrets.NETLIFY_SITE_ID_1 }}
netlify-auth-token: ${{ secrets.NETLIFY_AUTH_TOKEN }}
netlify-site-id: ${{ secrets.NETLIFY_SITE_ID }}
build-dir: './build'

0 comments on commit 234d38a

Please sign in to comment.