Auto-generated tile from GitHub (10 skills)
92
94%
Does it follow best practices?
Impact
92%
1.16xAverage score across 44 eval scenarios
Advisory
Suggest reviewing before use
A small open-source Node.js library called envparser has been using the standard package for code style enforcement since 2021. The team has decided to modernize their tooling stack after repeatedly hitting limitations with standard's lack of configurability, its slow integration with IDEs, and incompatibility with several newer ESLint plugins they'd like to adopt.
The library is a pure JavaScript project with some TypeScript type declaration files. It currently has a standard entry in package.json for configuration, a "lint": "standard src/" script, and a .husky/pre-commit hook that runs npx standard --fix src/. There is also a GitHub Actions workflow that runs npm run lint on every pull request.
The team wants to migrate to a modern ESLint v9 setup using neostandard as the Standard-like baseline, while keeping the same code style guarantees. They also want to make sure there is no leftover configuration from the old standard setup once the migration is complete.
Produce the following files in the workspace:
package.json — updated with new dependencies, updated lint scripts, and old standard config removed.github/workflows/lint.yml — CI workflow that runs lint (read-only, no auto-fix).husky/pre-commit (or .lintstagedrc.json) — pre-commit hook configurationMIGRATION.md — a brief document describing the steps taken to migrate, including the commands runThe following files represent the current state of the project. Extract them before beginning.
=============== FILE: package.json =============== { "name": "envparser", "version": "2.3.1", "description": "Parse and validate environment variables", "main": "src/index.js", "type": "module", "scripts": { "test": "node --test test/.test.js", "lint": "standard src/", "lint:check": "standard src/" }, "standard": { "ignore": ["dist/**"] }, "devDependencies": { "standard": "^17.1.0", "husky": "^9.0.0", "lint-staged": "^15.0.0" }, "lint-staged": { ".js": ["npx standard --fix"] }, "engines": { "node": ">=18" } }
=============== FILE: .github/workflows/lint.yml =============== name: Lint
on: pull_request: push: branches: [main]
jobs: lint: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: node-version: '20' - run: npm ci - run: npm run lint
=============== FILE: src/index.js =============== import { readFileSync } from 'node:fs'
export function parseEnv (filepath) { const content = readFileSync(filepath, 'utf8') const result = {} for (const line of content.split('\n')) { const trimmed = line.trim() if (!trimmed || trimmed.startsWith('#')) continue const eqIdx = trimmed.indexOf('=') if (eqIdx < 0) continue const key = trimmed.slice(0, eqIdx).trim() const value = trimmed.slice(eqIdx + 1).trim() result[key] = value } return result }
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10
scenario-11
scenario-12
scenario-13
scenario-14
scenario-15
scenario-16
scenario-17
scenario-18
scenario-19
scenario-20
scenario-21
scenario-22
scenario-23
scenario-24
scenario-25
scenario-26
scenario-27
scenario-28
scenario-29
scenario-30
scenario-31
scenario-32
scenario-33
scenario-34
scenario-35
scenario-36
scenario-37
scenario-38
scenario-39
scenario-40
scenario-41
scenario-42
scenario-43
scenario-44
skills
documentation
fastify
init
linting-neostandard-eslint9
node
nodejs-core
rules
oauth
octocat
snipgrapher