linttity
v1.1.3
Published
Automate ESlint and Prettier configuration and install the necessary packages for Nodejs projects
Readme
Linttity
Linttity is a CLI utility that bootstraps lint and format tooling for Node.js projects.
It installs the required development dependencies and generates a ready-to-use eslint.config.cjs preset.
Features
- Preset for Node.js + JavaScript
- Preset for Node.js + TypeScript
- Interactive mode when no preset flag is passed
- Automatic JavaScript/TypeScript project detection
- Merge or overwrite strategy for generated files
- Package manager detection (
npm,pnpm,yarn,bun) - Rule levels:
strict,balanced,relaxed - Import ordering rules included in generated ESLint configs
- Package script bootstrap (
lint,lint:fix,format,format:check) - Optional GitHub Actions workflow generation
doctorcommand for setup diagnostics- Automated smoke tests for CLI behavior
Installation
Global installation:
npm install -g linttityLocal usage without global install:
npx linttity --nodejsUsage
linttity [options]Options:
--nodejsor--njs: ESLint and Prettier config for Node.js + JavaScript--nodetsor--nts: ESLint and Prettier config for Node.js + TypeScript--merge: merge existing files safely when possible--overwrite: force overwrite generated files--strict|--balanced|--relaxed: choose lint rule strictness--package-manager <pm>: force package manager (npm|pnpm|yarn|bun)--no-ci: skip generating.github/workflows/quality.yml--skip-install: skip dependency installation (useful for tests)--doctor: inspect the current project lint/format setup
Use only one option at a time.
Examples
Setup JavaScript preset:
linttity --nodejs --balanced --mergeSetup TypeScript preset:
linttity --nodets --strict --overwriteCheck installed version:
linttity --versionRun setup diagnostics:
linttity --doctorRun interactive mode (no preset flag):
linttityWhat each preset does
Node.js + JavaScript (--nodejs)
- Installs lint/format dependencies for JavaScript projects.
- Creates or overwrites
eslint.config.cjswith a Node.js JavaScript preset. - Creates or overwrites
.prettierrc.jsonand.prettierignore. - Adds scripts to
package.jsonwhen missing. - Optionally generates
.github/workflows/quality.yml.
Node.js + TypeScript (--nodets)
- Installs lint/format dependencies for TypeScript projects.
- Creates or overwrites
eslint.config.cjswith a Node.js TypeScript preset. - Creates or overwrites
.prettierrc.jsonand.prettierignore. - Ensures
tsconfig.jsonexists for TypeScript projects. - Can normalize
tsconfig.jsonwhen using--overwrite. - Adds scripts to
package.jsonwhen missing. - Optionally generates
.github/workflows/quality.yml.
Notes
- The tool expects to run in the root of the target project.
- If you omit preset flags, Linttity prompts you interactively.
--mergekeeps existing files for non-safe merges (for example.eslintrc.cjs).--overwritereplaces generated config files.
Local development
Install dependencies:
npm installBuild:
npm run buildLint source files:
npm run lintFormat all files:
npm run formatCheck formatting:
npm run format:checkRun automated tests:
npm testGenerate a release checklist (auto-next patch by default):
npm run release:checklistGenerate or overwrite a checklist for a specific version:
npm run release:checklist -- 1.1.3 --forceRun patch release workflow (bump patch + checklist + release dry-runs):
npm run release:patchNote: release:checklist without version picks the next available patch checklist file.
Note: release:patch updates package.json version as part of the workflow.
Quick smoke test
From the repository root:
node dist/index.js --version
node dist/index.js --doctor
node dist/index.js --nodejs --skip-install --no-ci
node dist/index.js --nodets --skip-install --no-ciLicense
ISC
