{"library":"rush-lint-staged-plugin","title":"Rush Lint-Staged Plugin","description":"A Rush.js plugin that integrates lint-staged into Rush monorepos, enabling per-project lint-staged configurations via the multi-config feature introduced in lint-staged >=12.2.1. Current stable version: 0.2.2. Released as part of TikTok's rush-plugins, with no fixed schedule. Key differentiator: automatically matches staged files to the nearest .lintstagedrc file in the monorepo, correcting working directories for tasks. Requires Rush >=5.57.0 and Node >=12.","language":"javascript","status":"active","last_verified":"Fri May 01","install":{"commands":["npm install rush-lint-staged-plugin"],"cli":null},"imports":["npx rush lint-staged"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"# Enable the plugin in rush-plugins.json:\n# {\n#   \"plugins\": [\n#     {\n#       \"name\": \"rush-lint-staged-plugin\",\n#       \"version\": \"0.2.2\"\n#     }\n#   ]\n# }\n\n# Add a pre-commit hook (common/git-hooks/pre-commit):\n#!/bin/sh\nnode common/scripts/install-run-rush.js lint-staged || exit $?\n\n# Add a placeholder config at repo root (.lintstagedrc.json):\n{\n  \"*\": \"echo ok\"\n}\n\n# Create per-project .lintstagedrc files (e.g., apps/my-app/.lintstagedrc.js):\nmodule.exports = {\n  \"*.js\": \"eslint --fix\"\n};\n\n# Stage files and run:\ngit add somefile.js\nrush lint-staged","lang":"javascript","description":"Shows how to enable the Rush plugin, set up a pre-commit hook, add a placeholder config, and run lint-staged via Rush.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}