-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ci: publish release info on Discord #191
Conversation
📝 WalkthroughWalkthroughA new GitHub Actions workflow file named Changes
Sequence Diagram(s)sequenceDiagram
participant GitHub
participant Discord
GitHub->>GitHub: Release published
GitHub->>GitHub: Trigger workflow
GitHub->>GitHub: Checkout repository
GitHub->>Discord: Send notification via webhook
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Outside diff range and nitpick comments (1)
.github/workflows/release-to-discord.yaml (1)
9-10
: Consider updating to the latest version of actions/checkoutThe workflow is currently using
actions/checkout@v3
. While this version works, it's recommended to use the latest version (v4) to benefit from any improvements or bug fixes.Consider updating the checkout action:
- uses: actions/checkout@v3 + uses: actions/checkout@v4
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
📒 Files selected for processing (1)
- .github/workflows/release-to-discord.yaml (1 hunks)
🧰 Additional context used
🔇 Additional comments (3)
.github/workflows/release-to-discord.yaml (3)
1-3
: LGTM: Correct workflow triggerThe workflow is correctly set to trigger on the 'release' event, specifically for the 'published' type. This ensures that the Discord notification will be sent only when a new release is published.
5-7
: LGTM: Well-defined jobThe job is appropriately named 'github-releases-to-discord' and set to run on the latest Ubuntu runner, which is a good practice for most workflows.
11-19
: Suggestions for Discord notification configurationThe configuration for the Discord notification looks good overall. Here are some suggestions for improvement:
- The
max_description
length of 4096 characters is quite long. Consider reducing it to ensure the message fits well in Discord channels.- The
avatar_url
is hardcoded. Consider moving it to a repository secret or variable for easier updates.To ensure the webhook URL is correctly set, run the following script:
If the script doesn't find the secret, please make sure to set it in the repository settings.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Should be something like this:
Summary by CodeRabbit