Skip to content

chore: add lint:fix script for ESLint auto-fixes - #1510

Merged
brendan-kellam merged 4 commits into
sourcebot-dev:mainfrom
var-raphael:chore/lint-fix-script
Aug 4, 2026
Merged

chore: add lint:fix script for ESLint auto-fixes#1510
brendan-kellam merged 4 commits into
sourcebot-dev:mainfrom
var-raphael:chore/lint-fix-script

Conversation

@var-raphael

@var-raphael var-raphael commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

Closes #1466

Added a lint:fix script that mirrors the existing lint script setup — root script fans out via yarn workspaces foreach, and added the actual eslint . --fix command in packages/web (currently the only workspace with a lint script).

Tested by running yarn lint:fix — it auto-fixed what ESLint could fix and correctly left 4 warnings that need manual review (unused vars, missing hook deps), same as expected behavior with --fix.

Also added a CHANGELOG entry under Unreleased.


Note

Low Risk
Tooling-only script additions with no runtime, auth, or data-path changes.

Overview
Adds yarn lint:fix at the repo root, using the same yarn workspaces foreach pattern as lint so workspaces can run an auto-fix pass in one command.

In @sourcebot/web, adds lint:fix as eslint . --fix with the same SKIP_ENV_VALIDATION wrapper as the existing lint script. That package is currently the only workspace defining lint, so this is where fix behavior lands today.

Reviewed by Cursor Bugbot for commit 1f6a33f. Bugbot is set up for automated code reviews on this repo. Configure here.

Summary by CodeRabbit

  • Chores
    • Added commands to automatically fix linting issues across the project.
    • Added web application support for automatically correcting ESLint errors and formatting issues.

@coderabbitai

coderabbitai Bot commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 6114991f-6bd2-480b-8164-0552df4baba3

📥 Commits

Reviewing files that changed from the base of the PR and between 1c6e175 and 1f6a33f.

📒 Files selected for processing (1)
  • package.json

Walkthrough

The change adds a root lint:fix command and a web workspace lint:fix command. The root command runs workspace scripts in topological order. The web command runs ESLint with auto-fix enabled and environment validation skipped.

Changes

Lint auto-fix scripts

Layer / File(s) Summary
Workspace lint auto-fix flow
package.json, packages/web/package.json
The root script delegates lint:fix across Yarn workspaces. The web script runs eslint . --fix with SKIP_ENV_VALIDATION=1.

Estimated code review effort: 1 (Trivial) | ~2 minutes

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR adds the root shortcut and web script, but it misses the other four workspace scripts and the required CONTRIBUTING.md update from #1466. Add lint:fix to backend, db, schemas, and shared; update CONTRIBUTING.md; then verify yarn lint:fix and yarn lint.
Out of Scope Changes check ⚠️ Warning The CHANGELOG.md entry is unrelated to the requested lint script and CONTRIBUTING.md changes, so it appears to be extra scope. Remove the changelog edit or move it to a separate release-notes PR unless it's required by repository policy.
✅ Passed checks (3 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the addition of the lint:fix script for ESLint auto-fixes.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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 `@CHANGELOG.md`:
- Around line 10-11: Update the changelog entry for the lint:fix script to
replace the placeholder [`#XXXX`] reference and URL with the actual pull request
number and corresponding GitHub link once the PR is created.
🪄 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: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 60313d5c-9208-4cbc-bd69-580d74077215

📥 Commits

Reviewing files that changed from the base of the PR and between 9491a13 and 52e9795.

📒 Files selected for processing (3)
  • CHANGELOG.md
  • package.json
  • packages/web/package.json

Comment thread CHANGELOG.md Outdated
@brendan-kellam
brendan-kellam merged commit b7c3158 into sourcebot-dev:main Aug 4, 2026
6 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

chore(ci): add yarn lint:fix script for ESLint auto-fixes

2 participants