Skip to content

Commit

Permalink
Update nextjs.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
NayamAmarshe authored Jan 25, 2024
1 parent 2166254 commit 344a65f
Showing 1 changed file with 2 additions and 11 deletions.
13 changes: 2 additions & 11 deletions .github/workflows/nextjs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,27 +33,18 @@ jobs:
uses: actions/checkout@v3
with:
name: pashword/pashword
path: main
- name: Detect package manager
id: detect-package-manager
run: |
if [ -f "${{ github.workspace }}/yarn.lock" ]; then
echo "manager=yarn" >> $GITHUB_OUTPUT
echo "command=install" >> $GITHUB_OUTPUT
echo "runner=yarn" >> $GITHUB_OUTPUT
exit 0
elif [ -f "${{ github.workspace }}/package.json" ]; then
echo "manager=npm" >> $GITHUB_OUTPUT
echo "command=ci" >> $GITHUB_OUTPUT
echo "runner=npx --no-install" >> $GITHUB_OUTPUT
exit 0
else
echo "Unable to determine package manager"
exit 1
fi
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"
cache: ${{ steps.detect-package-manager.outputs.manager }}
- name: Setup Pages
uses: actions/configure-pages@v3
Expand Down

0 comments on commit 344a65f

Please sign in to comment.