Closed kfranqueiro closed 4 months ago
Name | Link |
---|---|
Latest commit | e28b79a3d889e5de953a00e16c11656c9994d432 |
Latest deploy log | https://app.netlify.com/sites/wcag2/deploys/66a284e0d7140e0008c3741e |
Deploy Preview | https://deploy-preview-3990--wcag2.netlify.app |
Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify site configuration.
Didn't anticipate the action attempting to run from the PR itself, which raises the significant issue that this approach will not work on PRs from forks. I'm inclined to think this might make it not worthwhile for this particular repo - all we'd be getting out of it is linking to .../techniques and .../understanding rather than the top-level link supplied by Netlify's default PR comment, and I'm not sure that's worth the cost of not getting deploy previews from forks. Will discuss.
This PR adds a github workflow as an alternative to Netlify's automatic PR deploys.
Note: Turn off Deploy Previews in Netlify site configuration > build & deploy before merging, to avoid duplicate builds/comments.
Motivation
Using a GitHub action allows us to customize the comment that appears in the PR, e.g. to specify more useful preview links. Unfortunately this sort of customization doesn't seem to be possible through Netlify's own PR deploy preview feature.
Example custom PR comment using this branch (note, this intentionally shows a failed check, as explained under Behavior)
Contrast with Netlify's comment format, which will appear below this post.
Behavior
GitHub Secrets
This requires 2 github secrets which I've set up:
NETLIFY_SITE_ID
- the ID found under site information in NetlifyNETLIFY_AUTH_TOKEN
- a personal access token generated in Netlify user settings