Skip to content

chore(deps): bump @babel/plugin-transform-modules-systemjs from 7.28.5 to 7.29.4 #261

chore(deps): bump @babel/plugin-transform-modules-systemjs from 7.28.5 to 7.29.4

chore(deps): bump @babel/plugin-transform-modules-systemjs from 7.28.5 to 7.29.4 #261

Workflow file for this run

name: Check Changelog
on:
pull_request_target:
branches:
- main
types:
- opened
- synchronize
- reopened
- labeled
- unlabeled
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
pull-requests: write
jobs:
check-changelog:
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no changelog') && github.event.pull_request.user.login != 'dependabot[bot]' }}
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Check changelog entry
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
with:
script: |
const { execSync } = require('child_process');
const files = execSync('git diff --name-only origin/main...HEAD').toString();
const hasChangelog = files.split('\n').some(f => f.trim() === 'CHANGELOG.md');
if (hasChangelog) {
console.log('Changelog entry found.');
return;
}
const { data: comments } = await github.rest.issues.listComments({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
});
const marker = '<!-- check-changelog -->';
const existing = comments.find(c => c.body.includes(marker));
const author = context.payload.pull_request.user.login;
const pr = context.payload.pull_request;
const prNumber = pr.number;
const prUrl = pr.html_url;
const authorUrl = `https://github.com/${author}`;
const body = [
marker,
`Hey @${author}, this PR is missing a changelog entry.`,
'',
`Add the following under the **Unreleased** section in \`CHANGELOG.md\`:`,
'```',
`- **platform**: Description. ([#${prNumber}](${prUrl}) by [@${author}](${authorUrl}))`,
'```',
'',
'See [CONTRIBUTING.md](https://github.com/lodev09/react-native-true-sheet/blob/main/CONTRIBUTING.md#sending-a-pull-request) for more details.',
].join('\n');
// Skip commenting on first open — changelog is typically added after PR creation
if (context.payload.action !== 'opened' && !existing) {
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
body,
});
}
core.setFailed('Missing changelog entry. Please update CHANGELOG.md or add the \'no changelog\' label.');