Skip to content

Commit

Permalink
Update node.js.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
deepsingh132 authored Oct 10, 2024
1 parent ccc99e9 commit 6781068
Showing 1 changed file with 10 additions and 14 deletions.
24 changes: 10 additions & 14 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs

name: Node.js CI

on:
Expand All @@ -18,7 +15,6 @@ jobs:
strategy:
matrix:
node-version: [18.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v4
Expand All @@ -27,21 +23,21 @@ jobs:
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: display env variables
- env:
NEXT_PUBLIC_CONVEX_URL: ${{ vars.NEXT_PUBLIC_CONVEX_URL }}
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY: ${{ vars.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY }}
CONVEX_DEPLOYMENT: ${{ secrets.CONVEX_DEPLOYMENT }}
- name: Display Environment Variables
run: |
echo "Convex var: $NEXT_PUBLIC_CONVEX_URL"
echo "Clerk var: $NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY"
echo "Covex deployment: $CONVEX_DEPLOYMENT"
- name: create env file
echo "Convex deployment: $CONVEX_DEPLOYMENT"
env:
NEXT_PUBLIC_CONVEX_URL: ${{ vars.NEXT_PUBLIC_CONVEX_URL }}
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY: ${{ vars.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY }}
CONVEX_DEPLOYMENT: ${{ secrets.CONVEX_DEPLOYMENT }}
- name: Create .env file
run: |
touch .env
echo NEXT_PUBLIC_CONVEX_URL="https://youthful-seahorse-517.convex.cloud" >> .env
echo NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=pk_test_YWxsb3dpbmctcXVldHphbC04MS5jbGVyay5hY2NvdW50cy5kZXYk >> .env
echo CONVEX_DEPLOYMENT=dev:youthful-seahorse-517 >> .env
echo NEXT_PUBLIC_CONVEX_URL=${{ vars.NEXT_PUBLIC_CONVEX_URL }} >> .env
echo NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=${{ vars.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY }} >> .env
echo CONVEX_DEPLOYMENT=${{ secrets.CONVEX_DEPLOYMENT }} >> .env
- run: npm ci
- run: npm run build --if-present
- run: npm test --if-present

0 comments on commit 6781068

Please sign in to comment.