-
Notifications
You must be signed in to change notification settings - Fork 537
ci: add Devin review workflow for blog article PRs #3870
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
Open
devin-ai-integration
wants to merge
3
commits into
main
Choose a base branch
from
devin/1770819465-blog-auto-format-bot-token
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+84
−0
Open
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
58a9c48
ci: use Hyper Charlie bot token for blog auto-format commits
devin-ai-integration[bot] 491de84
ci: add Devin review workflow for blog article PRs
devin-ai-integration[bot] 5bc6b22
Merge origin/main into devin/1770819465-blog-auto-format-bot-token
devin-ai-integration[bot] File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,84 @@ | ||
| name: Blog Devin Review | ||
|
|
||
| on: | ||
| pull_request: | ||
| branches: | ||
| - main | ||
| paths: | ||
| - "apps/web/content/articles/**" | ||
|
|
||
| jobs: | ||
| devin-review: | ||
| if: startsWith(github.head_ref, 'blog/') | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: read | ||
|
|
||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| fetch-depth: 0 | ||
|
|
||
| - name: Get changed files | ||
| id: changed-files | ||
| run: | | ||
| FILES=$(git diff --name-only origin/${{ github.base_ref }}...HEAD -- 'apps/web/content/articles/*.mdx' | tr '\n' ' ') | ||
| echo "files=$FILES" >> $GITHUB_OUTPUT | ||
| if [ -z "$FILES" ]; then | ||
| echo "has_files=false" >> $GITHUB_OUTPUT | ||
| else | ||
| echo "has_files=true" >> $GITHUB_OUTPUT | ||
| fi | ||
|
|
||
| - name: Trigger Devin review | ||
| if: steps.changed-files.outputs.has_files == 'true' | ||
| uses: ./.github/actions/devin | ||
| with: | ||
| api_key: ${{ secrets.DEVIN_API_KEY }} | ||
| prompt: | | ||
| You are tasked with reviewing a blog article PR for Hyprnote. | ||
|
|
||
| ## Context | ||
| Hyprnote is a privacy-first AI notetaking application for meetings. | ||
| Repository: fastrepl/hyprnote | ||
| PR: #${{ github.event.pull_request.number }} | ||
| Branch: ${{ github.head_ref }} | ||
| Changed files: ${{ steps.changed-files.outputs.files }} | ||
|
|
||
| ## Your Task | ||
| 1. **Check out the PR branch** | ||
| - Clone the repo and check out the PR branch: `${{ github.head_ref }}` | ||
|
|
||
| 2. **Read the article content** | ||
| - Read each changed MDX file listed above | ||
| - Understand the article's topic, structure, and target audience | ||
|
|
||
| 3. **Review the article and leave PR comments** | ||
| Use the GitHub API to leave a review on PR #${{ github.event.pull_request.number }} in `fastrepl/hyprnote` with inline comments on specific lines. Focus on: | ||
|
|
||
| - **Factual accuracy**: Flag any technical claims that seem incorrect | ||
| - **Clarity**: Identify confusing or ambiguous sentences | ||
| - **Structure**: Suggest improvements to article flow and organization | ||
| - **Missing context**: Note where additional explanation would help readers | ||
| - **Frontmatter**: Check that meta_title, display_title, meta_description, author, category, and date are all filled in properly | ||
| - **Links**: Check that any links referenced in the article are valid | ||
|
|
||
| For each suggestion, leave an inline PR review comment on the specific line with: | ||
| - A clear description of the issue | ||
| - A concrete suggestion for improvement | ||
|
|
||
| 4. **Post a summary comment** | ||
| After reviewing, leave a top-level PR comment with: | ||
| - Overall assessment of the article quality | ||
| - Key suggestions summarized | ||
| - Any missing elements (images, links, metadata) | ||
|
|
||
| ## Important Notes | ||
| - Be constructive and specific in feedback | ||
| - Do not make changes to the code or create new commits | ||
| - Only leave review comments on the PR | ||
| - If the article looks good, still leave a brief positive review | ||
| - Focus on content quality, not formatting (dprint handles formatting separately) | ||
| title: ${{ github.run_id }}-blog-review | ||
| tags: '["blog_review"]' | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
The glob pattern
apps/web/content/articles/*.mdxonly matches.mdxfiles directly in the articles directory, not in subdirectories. This is inconsistent with the path trigger on line 8 which uses**to match files at any depth. If articles exist in subdirectories (e.g.,apps/web/content/articles/2026/post.mdx), the workflow will trigger but won't detect any changed files.FILES=$(git diff --name-only origin/${{ github.base_ref }}...HEAD -- 'apps/web/content/articles/**/*.mdx' | tr '\n' ' ')Spotted by Graphite Agent

Is this helpful? React 👍 or 👎 to let us know.