Skip to content

Commit 1b82b7d

Browse files
Copilotmmcky
andcommitted
Update collab.yml workflow to use netlify-cli for consistency
Co-authored-by: mmcky <[email protected]>
1 parent 9e45559 commit 1b82b7d

File tree

1 file changed

+16
-6
lines changed

1 file changed

+16
-6
lines changed

.github/workflows/collab.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,13 +46,23 @@ jobs:
4646
with:
4747
name: execution-reports
4848
path: _build/html/reports
49+
- name: Install Node.js and Netlify CLI
50+
shell: bash -l {0}
51+
run: |
52+
curl -fsSL https://deb.nodesource.com/setup_18.x | bash -
53+
apt-get install -y nodejs
54+
npm install -g netlify-cli
4955
- name: Preview Deploy to Netlify
50-
uses: nwtgck/actions-netlify@v3
51-
with:
52-
publish-dir: '_build/html/'
53-
production-branch: main
54-
github-token: ${{ secrets.GITHUB_TOKEN }}
55-
deploy-message: "Preview Deploy from GitHub Actions"
56+
shell: bash -l {0}
57+
run: |
58+
netlify deploy \
59+
--dir _build/html/ \
60+
--site ${{ secrets.NETLIFY_SITE_ID }} \
61+
--auth ${{ secrets.NETLIFY_AUTH_TOKEN }} \
62+
--alias collab-pr-${{ github.event.pull_request.number }} \
63+
--context deploy-preview \
64+
--message "Collab Preview Deploy from GitHub Actions PR #${{ github.event.pull_request.number }} (commit: ${{ github.sha }})" \
65+
--json
5666
env:
5767
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
5868
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}

0 commit comments

Comments
 (0)