-
Notifications
You must be signed in to change notification settings - Fork 3
chore: add windows and macos to CI #50
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
Conversation
WalkthroughGitHub Actions workflows updated: branch filter arrays reformatted, build matrices expanded to cover additional OS targets (dmd: ubuntu-latest, windows-latest; ldc: ubuntu-latest, macos-latest), checkout action upgraded to actions/checkout@v6, and dlang-community/setup-dlang updated to v2 with adjusted step indentation. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
Comment |
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: 1
🧹 Nitpick comments (1)
.github/workflows/ldc.yml (1)
23-23: Consider upgradingactions/checkoutto a newer version.The current workflow uses actions/checkout@v3. The latest version is v6.0.1 (released December 2, 2025). While v3 is not formally deprecated, GitHub recommends upgrading to newer versions for improved Node.js runtime support. Official examples for setup-dlang@v2 use actions/checkout@v4.
Apply this diff to upgrade:
- name: Checkout Source - uses: actions/checkout@v3 + uses: actions/checkout@v4Or use the latest version (v6):
- name: Checkout Source - uses: actions/checkout@v3 + uses: actions/checkout@v6
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
.github/workflows/dmd.yml(1 hunks).github/workflows/ldc.yml(1 hunks)
🧰 Additional context used
🪛 actionlint (1.7.9)
.github/workflows/ldc.yml
23-23: the runner of "actions/checkout@v3" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
.github/workflows/dmd.yml
23-23: the runner of "actions/checkout@v3" action is too old to run on GitHub Actions. update the action's version to fix this issue
(action)
🔇 Additional comments (4)
.github/workflows/ldc.yml (2)
15-19: Excellent addition of cross-platform testing matrix.Expanding to test on both Ubuntu and macOS strengthens CI coverage. This aligns with the stated PR objective.
26-28: No $DC environment variable usage detected in this codebase. The workflow file correctly uses thecompilerinput parameter for setup-dlang v2, and the build step (dub -q test) relies on DUB's compiler handling rather than direct $DC references. This concern does not apply to the current codebase..github/workflows/dmd.yml (2)
15-19: Excellent addition of cross-platform testing matrix.Expanding to test on both Windows and Ubuntu strengthens CI coverage across the major platforms where DMD is commonly used.
26-28: The setup-dlang v2 breaking change regarding the$DCenvironment variable is documented and confirmed:DCnow contains the full path to the compiler instead of just the filename. However, a search of the repository shows that the$DCenvironment variable is not used anywhere in the codebase, so this breaking change does not impact the current build or test setup.Likely an incorrect or invalid review comment.
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: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
.github/workflows/dmd.yml(1 hunks).github/workflows/ldc.yml(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
- .github/workflows/ldc.yml
🔇 Additional comments (4)
.github/workflows/dmd.yml (4)
5-5: Approved: Branch filter syntax is correct.The reformatted branch arrays from multiline to compact inline syntax (
["main"]) is functionally equivalent and is idiomatic YAML. No issues here.Also applies to: 7-7
15-17: Approved: Matrix expansion to Windows is well-structured.The matrix strategy correctly adds
windows-latestas a new OS target alongsideubuntu-latest, with a single DMD version. This aligns with the intentional pattern inldc.yml(which targets ubuntu + macOS) to distribute OS coverage across workflows.
23-23: Approved: Upgrade to actions/checkout@v6 addresses deprecation.The upgrade from the deprecated
actions/checkout@v3(Node 16) to@v6is correct and aligns with current best practices. This resolves the prior feedback from the previous review.
30-32: Approved: Build and Test step syntax is correct.The YAML indentation and structure for the build/test step is proper. The
dub -q testcommand is preserved correctly.
| - name: D Compiler Installation | ||
| uses: dlang-community/setup-dlang@v2 | ||
| with: | ||
| compiler: ${{ matrix.dc }} |
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.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
REPO="dlang-community/setup-dlang"
API="https://api.github.com/repos/$REPO"
echo "Checking tags for v2..."
curl -s "$API/tags" | jq -r '.[].name' | sed -n '1,200p' > /tmp/tags.txt || true
if grep -q '^v2$' /tmp/tags.txt; then
echo "TAG_FOUND: v2"
else
echo "TAG_NOT_FOUND: v2"
fi
echo
echo "Checking releases for tag v2..."
curl -s "$API/releases" | jq -r '.[] | {tag_name, prerelease, draft, published_at} | @json' | sed -n '1,200p' > /tmp/releases.json || true
jq -r '.tag_name' /tmp/releases.json 2>/dev/null | sed -n '1,50p' > /tmp/release_tags.txt || true
if grep -q '^v2$' /tmp/release_tags.txt; then
echo "RELEASE_FOUND: v2"
else
echo "RELEASE_NOT_FOUND: v2"
fi
echo
echo "Showing latest 5 release tags (if any):"
jq -r '.tag_name + " (prerelease: " + (.prerelease|tostring) + ", draft: " + (.draft|tostring) + ", published_at: " + (.published_at // "null") + ")"' /tmp/releases.json 2>/dev/null | sed -n '1,5p' || echo "No releases returned."
echo
echo "Searching issues mentioning Windows or windows-latest..."
# Use the search API for issues in the repo mentioning windows
curl -s "https://api.github.com/search/issues?q=repo:$REPO+windows&per_page=5" | jq -r '.items[] | {number, title, html_url}' | sed -n '1,50p' || echo "No matching issues."
echo
echo "Checking README for windows mentions..."
curl -s "$API/readme" | jq -r '.content' | base64 --decode 2>/dev/null | rg -n "Windows|windows|windows-latest" || echo "No explicit 'Windows' mention found in README snippet."
echo
echo "Done."Repository: gdamore/dcell
Length of output: 2313
Use an existing action ref (or add a v2 tag) and monitor Windows CI
There is no 'v2' tag in dlang-community/setup-dlang; the repository has a release/tag named 'v2.0.0'. Change the workflow to use dlang-community/[email protected] (or create a 'v2' tag in that repo). The action supports Windows (README includes windows-latest examples) but there are several Windows-related issues in the repo — run and watch windows-latest CI for platform-specific failures.
🤖 Prompt for AI Agents
.github/workflows/dmd.yml lines 25-28: the workflow references
dlang-community/setup-dlang@v2 but that tag does not exist; update the action
ref to a real release (e.g. dlang-community/[email protected]) or ensure the
upstream repo has a v2 tag, and then run CI on windows-latest to detect
platform-specific failures — change the uses line to point to the exact tag
(v2.0.0) and monitor Windows CI for any issues.
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.