Repository navigation
Standardized in-repo scripts directory - #29410
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (2)
📒 Files selected for processing (43)
💤 Files with no reviewable changes (1)
🚧 Files skipped from review as they are similar to previous changes (36)
WalkthroughThe PR creates an Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 Trivy (0.72.0)Trivy execution failed: 2026-07-16T21:14:09Z FATAL Fatal error run error: fs scan error: scan error: scan failed: failed analysis: post analysis error: post analysis error: kubernetes scan error: fs filter error: fs filter error: walk error range error: stat scripts/doctor.config.json: no such file or directory: range error: stat scripts/doctor.config.json: no such file or directory Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
| Command | Status | Duration | Result |
|---|---|---|---|
nx run ghost:test:ci:integration |
✅ Succeeded | 2m 54s | View ↗ |
nx run-many -t test:unit -p @tryghost/adapter-b... |
✅ Succeeded | 7m 16s | View ↗ |
nx run ghost:test:integration |
✅ Succeeded | 3m 5s | View ↗ |
nx run @tryghost/admin:test:acceptance |
✅ Succeeded | 5m 33s | View ↗ |
nx run ghost-monorepo:lint:boundaries |
✅ Succeeded | 20s | View ↗ |
nx run ghost:test:legacy |
✅ Succeeded | 3m 14s | View ↗ |
nx run-many -t lint -p @tryghost/adapter-base-r... |
✅ Succeeded | 3m 33s | View ↗ |
nx run ghost:test:e2e |
✅ Succeeded | 2m 46s | View ↗ |
Additional runs (8) |
✅ Succeeded | ... | View ↗ |
💡 Verify your cache is correct by running tasks in a sandbox. Read docs ↗
☁️ Nx Cloud last updated this comment at 2026-07-16 21:25:56 UTC
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #29410 +/- ##
==========================================
+ Coverage 74.17% 74.21% +0.04%
==========================================
Files 1592 1592
Lines 139000 139000
Branches 16858 16873 +15
==========================================
+ Hits 103100 103161 +61
+ Misses 34881 34789 -92
- Partials 1019 1050 +31
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
338c645 to
5e7772b
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@scripts/lib/release-notes.cjs`:
- Around line 16-26: Update getCommitLog to use execFileSync instead of
execSync, passing git, the log arguments, format value, and range as separate
arguments rather than interpolating fromTag and toTag into a shell command.
Preserve the existing cwd, encoding, trimming, and failure behavior.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: e77b274d-a9b2-43b8-8438-25be920fb1f9
⛔ Files ignored due to path filters (2)
.github/scripts/i18n-review/package-lock.jsonis excluded by!**/package-lock.jsonpnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (42)
.github/scripts/dependency-inspector.js.github/scripts/i18n-review/README.md.github/scripts/i18n-review/eslint.config.mjs.github/scripts/i18n-review/package.json.github/scripts/i18n-review/src/github.js.github/workflows/ci.yml.github/workflows/devcontainer-build.yml.github/workflows/i18n-review-checks.yml.github/workflows/publish-koenig-package.yml.github/workflows/release.yml.github/workflows/translation-review.ymlapps/admin-toolbar/package.jsonapps/admin-x-settings/package.jsonapps/admin-x-settings/src/utils/link-to-github-releases.tsapps/announcement-bar/package.jsonapps/comments-ui/package.jsonapps/portal/package.jsonapps/signup-form/package.jsonapps/sodo-search/package.jsondocker/ghost-dev/Dockerfileeslint.config.mjsghost/core/package.jsonkoenig/README.mdpackage.jsonpnpm-workspace.yamlscripts/README.mdscripts/build-public-apps-matrix.cjsscripts/check-app-version-bump.cjsscripts/check-migration-integrity.cjsscripts/clean.cjsscripts/compute-next-app-version.cjsscripts/create-package.jsscripts/enforce-package-manager.jsscripts/eslint.config.mjsscripts/lib/release-notes.cjsscripts/lib/resolve-base-tag.cjsscripts/package.jsonscripts/public-apps.jsonscripts/publish-koenig-packages.cjsscripts/release-apps.cjsscripts/release.cjsscripts/test/resolve-base-tag.test.cjs
💤 Files with no reviewable changes (1)
- .github/scripts/dependency-inspector.js
🚧 Files skipped from review as they are similar to previous changes (33)
- apps/portal/package.json
- apps/announcement-bar/package.json
- apps/comments-ui/package.json
- .github/scripts/i18n-review/eslint.config.mjs
- scripts/test/resolve-base-tag.test.cjs
- apps/sodo-search/package.json
- scripts/enforce-package-manager.js
- scripts/public-apps.json
- scripts/package.json
- pnpm-workspace.yaml
- .github/workflows/translation-review.yml
- scripts/create-package.js
- .github/workflows/release.yml
- ghost/core/package.json
- apps/admin-toolbar/package.json
- scripts/eslint.config.mjs
- scripts/publish-koenig-packages.cjs
- eslint.config.mjs
- .github/workflows/publish-koenig-package.yml
- .github/workflows/devcontainer-build.yml
- docker/ghost-dev/Dockerfile
- .github/scripts/i18n-review/package.json
- scripts/release-apps.cjs
- scripts/lib/resolve-base-tag.cjs
- scripts/clean.cjs
- .github/workflows/i18n-review-checks.yml
- .github/scripts/i18n-review/README.md
- scripts/compute-next-app-version.cjs
- scripts/build-public-apps-matrix.cjs
- scripts/check-migration-integrity.cjs
- scripts/check-app-version-bump.cjs
- package.json
- .github/workflows/ci.yml
There was a problem hiding this comment.
Caution
Inline review comments failed to post. This is likely due to GitHub's internal server error or limits when posting large numbers of comments. If you are seeing this consistently it is likely a permissions issue. Please check "Moderation" -> "Code review limits" under your organization settings.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@scripts/lib/release-notes.cjs`:
- Around line 16-26: Update getCommitLog to use execFileSync instead of
execSync, passing git, the log arguments, format value, and range as separate
arguments rather than interpolating fromTag and toTag into a shell command.
Preserve the existing cwd, encoding, trimming, and failure behavior.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: e77b274d-a9b2-43b8-8438-25be920fb1f9
⛔ Files ignored due to path filters (2)
.github/scripts/i18n-review/package-lock.jsonis excluded by!**/package-lock.jsonpnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (42)
.github/scripts/dependency-inspector.js.github/scripts/i18n-review/README.md.github/scripts/i18n-review/eslint.config.mjs.github/scripts/i18n-review/package.json.github/scripts/i18n-review/src/github.js.github/workflows/ci.yml.github/workflows/devcontainer-build.yml.github/workflows/i18n-review-checks.yml.github/workflows/publish-koenig-package.yml.github/workflows/release.yml.github/workflows/translation-review.ymlapps/admin-toolbar/package.jsonapps/admin-x-settings/package.jsonapps/admin-x-settings/src/utils/link-to-github-releases.tsapps/announcement-bar/package.jsonapps/comments-ui/package.jsonapps/portal/package.jsonapps/signup-form/package.jsonapps/sodo-search/package.jsondocker/ghost-dev/Dockerfileeslint.config.mjsghost/core/package.jsonkoenig/README.mdpackage.jsonpnpm-workspace.yamlscripts/README.mdscripts/build-public-apps-matrix.cjsscripts/check-app-version-bump.cjsscripts/check-migration-integrity.cjsscripts/clean.cjsscripts/compute-next-app-version.cjsscripts/create-package.jsscripts/enforce-package-manager.jsscripts/eslint.config.mjsscripts/lib/release-notes.cjsscripts/lib/resolve-base-tag.cjsscripts/package.jsonscripts/public-apps.jsonscripts/publish-koenig-packages.cjsscripts/release-apps.cjsscripts/release.cjsscripts/test/resolve-base-tag.test.cjs
💤 Files with no reviewable changes (1)
- .github/scripts/dependency-inspector.js
🚧 Files skipped from review as they are similar to previous changes (33)
- apps/portal/package.json
- apps/announcement-bar/package.json
- apps/comments-ui/package.json
- .github/scripts/i18n-review/eslint.config.mjs
- scripts/test/resolve-base-tag.test.cjs
- apps/sodo-search/package.json
- scripts/enforce-package-manager.js
- scripts/public-apps.json
- scripts/package.json
- pnpm-workspace.yaml
- .github/workflows/translation-review.yml
- scripts/create-package.js
- .github/workflows/release.yml
- ghost/core/package.json
- apps/admin-toolbar/package.json
- scripts/eslint.config.mjs
- scripts/publish-koenig-packages.cjs
- eslint.config.mjs
- .github/workflows/publish-koenig-package.yml
- .github/workflows/devcontainer-build.yml
- docker/ghost-dev/Dockerfile
- .github/scripts/i18n-review/package.json
- scripts/release-apps.cjs
- scripts/lib/resolve-base-tag.cjs
- scripts/clean.cjs
- .github/workflows/i18n-review-checks.yml
- .github/scripts/i18n-review/README.md
- scripts/compute-next-app-version.cjs
- scripts/build-public-apps-matrix.cjs
- scripts/check-migration-integrity.cjs
- scripts/check-app-version-bump.cjs
- package.json
- .github/workflows/ci.yml
🛑 Comments failed to post (1)
scripts/lib/release-notes.cjs (1)
16-26: 🔒 Security & Privacy | 🟠 Major | ⚡ Quick win
Use
execFileSyncto prevent shell injection and handle special characters.Constructing a shell command string with unescaped arguments (
fromTag,toTag) can lead to command injection or failure if the tag names contain special characters. UsingexecFileSyncis safer because it bypasses the shell and passes arguments directly to the executable.🔒️ Proposed fix to use
execFileSync-function getCommitLog(fromTag, toTag) { - const range = `${fromTag}..${toTag}`; - const format = '* %s - %an'; - const cmd = `git log --no-merges --pretty=tformat:'${format}' ${range}`; - - let log; - try { - log = execSync(cmd, {cwd: ROOT, encoding: 'utf8'}).trim(); - } catch { - return []; - } +function getCommitLog(fromTag, toTag) { + const range = `${fromTag}..${toTag}`; + const format = '* %s - %an'; + + let log; + try { + const {execFileSync} = require('node:child_process'); + log = execFileSync('git', ['log', '--no-merges', `--pretty=tformat:${format}`, range], {cwd: ROOT, encoding: 'utf8'}).trim(); + } catch { + return []; + }📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.function getCommitLog(fromTag, toTag) { const range = `${fromTag}..${toTag}`; const format = '* %s - %an'; let log; try { const {execFileSync} = require('node:child_process'); log = execFileSync('git', ['log', '--no-merges', `--pretty=tformat:${format}`, range], {cwd: ROOT, encoding: 'utf8'}).trim(); } catch { return []; }🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@scripts/lib/release-notes.cjs` around lines 16 - 26, Update getCommitLog to use execFileSync instead of execSync, passing git, the log arguments, format value, and range as separate arguments rather than interpolating fromTag and toTag into a shell command. Preserve the existing cwd, encoding, trimming, and failure behavior.
ref https://linear.app/ghost/issue/PLA-235/consolidate-ci-scripts-into-monorepo-package - relocate script files from .github/scripts/ to scripts/ - keep i18n-review in .github/scripts for now due to security/isolation constraints - ensure scripts + i18n-review are picked up and tested/linted
5e7772b to
5493760
Compare

ref https://linear.app/ghost/issue/PLA-235/consolidate-ci-scripts-into-monorepo-package