From dde0da241476b13b828c2209b5ced98cb713c316 Mon Sep 17 00:00:00 2001 From: Dwitesh Shetty Date: Sat, 28 Oct 2023 00:53:20 +0530 Subject: [PATCH] ci cd yaml added --- .github/workflows/{main.yml => cd.yml} | 15 +++++++++++---- .github/workflows/{pull_request.yml => ci.yml} | 0 2 files changed, 11 insertions(+), 4 deletions(-) rename .github/workflows/{main.yml => cd.yml} (79%) rename .github/workflows/{pull_request.yml => ci.yml} (100%) diff --git a/.github/workflows/main.yml b/.github/workflows/cd.yml similarity index 79% rename from .github/workflows/main.yml rename to .github/workflows/cd.yml index 873fbcf..b074acb 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/cd.yml @@ -33,14 +33,21 @@ jobs: # Runs a set of commands using the runners shell - name: Install dependencies run: | - npm install + npm ci echo Dependencies installed successfully! + - name: Load environment variables + uses: xom9ikk/dotenv@v2.2.0 + with: + path: ./ + mode: development + load-mode: strict + - name: Create new build env: - REACT_APP_HOST_URL: ${{ secrets.REACT_APP_HOST_URL }} - REACT_APP_WEBSITE_TITLE: ${{ secrets.REACT_APP_WEBSITE_TITLE }} - REACT_APP_WEBSITE_DESCRIPTION: ${{ secrets.REACT_APP_WEBSITE_DESCRIPTION }} + REACT_APP_HOST_URL: ${{ env.REACT_APP_HOST_URL }} + REACT_APP_WEBSITE_TITLE: ${{ env.REACT_APP_WEBSITE_TITLE }} + REACT_APP_WEBSITE_DESCRIPTION: ${{ env.REACT_APP_WEBSITE_DESCRIPTION }} run: | npm run build echo Build created successfully! diff --git a/.github/workflows/pull_request.yml b/.github/workflows/ci.yml similarity index 100% rename from .github/workflows/pull_request.yml rename to .github/workflows/ci.yml