From 86dc1fa2a8dfd3a417c9083bd7c69799b71515e9 Mon Sep 17 00:00:00 2001 From: John Date: Tue, 22 Sep 2026 20:51:17 +0530 Subject: [PATCH] Configure automatic deployment path --- .github/workflows/build.yml | 32 ++++++++++++++++++++++++++------ 1 file changed, 26 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6b2916c..b5973b8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,4 @@ -name: Node.js CI +name: Node.js CI/CD on: push: @@ -15,20 +15,40 @@ jobs: - name: Check Git shell: powershell - run: git --version + run: | + git --version - name: Check Node.js shell: powershell - run: node --version + run: | + node --version - name: Check npm shell: powershell - run: npm --version + run: | + npm --version - name: Install dependencies shell: powershell - run: npm ci + run: | + npm ci - name: Check application shell: powershell - run: node --check app.js + run: | + node --check app.js + + - name: Deploy application + shell: powershell + run: | + $deployPath = "D:\apps\my_temp\my-node-app" + + if (!(Test-Path $deployPath)) { + New-Item -ItemType Directory -Path $deployPath -Force + } + + Write-Host "Deploying to $deployPath" + + Copy-Item -Path ".\*" -Destination $deployPath -Recurse -Force + + Write-Host "Deployment completed successfully."