A command-line tool to scan your project for TODO and FIXME comments, helping you keep track of pending tasks and issues in your codebase.
- Recursively scans directories for TODO and FIXME comments
- Supports multiple file types including JavaScript, TypeScript, Markdown, HTML, CSS, and more
- Excludes common directories like node_modules, .git, and build folders
- Flexible output formats: console, JSON, and CSV
- Easy to use with customizable options
Install the package globally using npm:
npm install -g todo-fixme-scanner
Or use it directly with npx:
npx todo-fixme-scanner@latest
To scan the current directory and display results in the console:
todo-fixme-scanner
To scan a specific directory:
todo-fixme-scanner --dir /path/to/your/project
Choose between console (default), JSON, or CSV output:
todo-fixme-scanner --output console
todo-fixme-scanner --output json
todo-fixme-scanner --output csv
-
--dir
,-d
: Specify the directory to scan (default: current working directory) -
--output
,-o
: Specify the output format: 'console', 'json', or 'csv' (default: console)
🔍 Scanning project for TODO/FIXME comments...
TODO: Implement user authentication
File: /path/to/your/project/src/auth.js:15
FIXME: Optimize database query for better performance
File: /path/to/your/project/src/database.js:42
✅ Scan complete.
[
{
"type": "TODO",
"text": "Implement user authentication",
"file": "/path/to/your/project/src/auth.js",
"line": 15
},
{
"type": "FIXME",
"text": "Optimize database query for better performance",
"file": "/path/to/your/project/src/database.js",
"line": 42
}
]
Type,Text,File,Line
TODO,"Implement user authentication",/path/to/your/project/src/auth.js,15
FIXME,"Optimize database query for better performance",/path/to/your/project/src/database.js,42
The scanner supports the following file extensions:
- JavaScript: .js, .jsx
- TypeScript: .ts, .tsx
- Markdown: .md, .mdx
- HTML: .html
- CSS: .css
- JSON: .json
- YAML: .yml, .yaml
- SCSS/SASS: .scss, .sass
- LESS: .less
The following directories are automatically excluded from scanning:
- node_modules
- .next
- .out
- .dist
- .git
- build
- .cache
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License.