Skip to content

Commit

Permalink
chore: fix comment on PR (#954)
Browse files Browse the repository at this point in the history
  • Loading branch information
mscolnick committed Mar 15, 2024
1 parent 2fef685 commit 257e085
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions .github/workflows/dev-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -95,15 +95,19 @@ jobs:
script: |
try {
const pullRequest = await github.rest.search.issuesAndPullRequests({
q: context.sha
q: `sha:${context.sha} is:pr is:merged`
});
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: pullRequest.data.items[0].number,
body: '🚀 Development release published. You may be able to view the changes at https://marimo.app?v=${{ env.MARIMO_VERSION }}'
});
if (pullRequest.data.items.length > 0) {
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: pullRequest.data.items[0].number,
body: `🚀 Development release published. You may be able to view the changes at https://marimo.app?v=${process.env.MARIMO_VERSION}`
});
} else {
console.log("No merged PR found for this SHA.");
}
} catch (err) {
console.error(err);
}

0 comments on commit 257e085

Please sign in to comment.