WhatToDo
command-line tool that scans directories for TODO comments in code files and generates a report.
Features
- Searches for TODO comments in specified file types
- Collects context, scope, and metadata for each TODO
- Outputs results to console, TSV, or Markdown format
- Tracks TODO history through git commits (when enabled)
- Shows when TODOs were added or removed
- Includes commit information (author, date, message)
- Supports both text and markdown output formats
** Note: this script is not intended to be a full-featured code analysis tool, it's just some regexs - the scope identification is very basic and could be improved.
Usage
python whattodo.py [path] [--extensions EXT [EXT ...]] [--output OUTPUT] [--git-history] [--git-history-format {text,markdown}]
Arguments
-por--path: Directory to search (default: current directory)-eor--extensions: File extensions to search (default: .py .R .sh .c .cpp .pl)-oor--output: Output file path (optional, .tsv or .md)--git-history: Include git history for TODOs (tracks when TODOs were added/removed)--git-history-format: Format for git history output ('text' or 'markdown', default: text)--include-hidden: Include hidden files and directories--ignore-paths: Additional paths to ignore
Examples
-
Search current directory with default settings:
python whattodo.py -
Search a specific directory:
python whattodo.py /path/to/project -
Specify custom file extensions:
python whattodo.py --extensions .py .js .html -
Output to a TSV file:
python whattodo.py --output todos.tsv -
Output to a Markdown file:
python whattodo.py --output todos.md -
Include git history in markdown format:
python whattodo.py --git-history --git-history-format markdown -
Combine options:
python whattodo.py /path/to/project --extensions .py .js --output todos.md --git-history
Requirements
- Python
- Git (optional, required for git history functionality)
Installation
There are two ways to install what2do:
1. Using pip (recommended)
pip install what2do
After installation, you can run the tool directly:
what2do --help
2. From source
- Clone this repository:
git clone https://github.com/urineri/what2do.git
cd what2do
- Install in development mode:
pip install -e .
- Run the tool:
what2do --help
License
Metadata
Release files for what2do 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| what2do-0.1.3.tar.gz | 8.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| what2do-0.1.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 16.9 kB
Release files / what2do-0.1.3.tar.gz
| Download URL | what2do-0.1.3.tar.gz |
|---|---|
| Size | 8.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
04e15e3f37202df4b9ee4b869475afb1f25a2e005cc536a7608d4dd88b7be966
|
|
BLAKE2b-256 checksum How to use checksums |
b86a2a298ec7b0c4f839b11cf72f2e72789065ebe58ea2437f5ada3b1bcea951
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.5
|
Release files / what2do-0.1.3-py3-none-any.whl
| Download URL | what2do-0.1.3-py3-none-any.whl |
|---|---|
| Size | 8.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
af96af9531b841417973963e2230ffecdecf59758ac0c90dbea8e6bdb122e7e7
|
|
BLAKE2b-256 checksum How to use checksums |
0a96c2fe1bbc074b9f735feb6032bb542ab959ffe272ac855f3f31a4d907ab17
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.5
|