Use curly braces in if condition#40865
Conversation
GitHub lint says it's strongly recommended to always wrap the full `if:` condition in `${{ }}`
|
Thanks for opening this pull request! A GitHub docs team member should be by to give feedback soon. In the meantime, please check out the contributing guidelines. |
There was a problem hiding this comment.
Pull Request Overview
This PR updates a GitHub Actions workflow example to follow best practices by wrapping the if condition in curly braces syntax as recommended by GitHub lint.
- Added
${{ }}wrapper around the if condition to align with GitHub's strongly recommended practices
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
How to review these changes 👓Thank you for your contribution. To review these changes, choose one of the following options: A Hubber will need to deploy your changes internally to review. Table of review linksNote: Please update the URL for your staging server or codespace. The table shows the files in the
Key: fpt: Free, Pro, Team; ghec: GitHub Enterprise Cloud; ghes: GitHub Enterprise Server 🤖 This comment is automatically generated. |
|
@glenthomas Looks right to me! I didn't even know it was possible to do an |
|
Thanks very much for contributing! Your pull request has been merged 🎉 You should see your changes appear on the site in approximately 24 hours. If you're looking for your next contribution, check out our help wanted issues ⚡ |
Why:
GitHub lint says it's strongly recommended to always wrap the full
if:condition in${{ }}. I think it would be best to include this in the example code to avoid leading people into unexpected issues.See the GH-Lint documentation for an explanation.
What's being changed (if available, include any code snippets, screenshots, or gifs):
Add braces to if.
Check off the following: