todos - TODO/HACK Comments
The todos command finds all TODO and HACK comments in your C# code. This helps you track technical debt, action items, and areas that need improvement. It’s useful for code reviews, sprint planning, and identifying work that needs to be done.
nmbl todos <ProjectFileOrDirectory>
ProjectFileOrDirectory- Path to a .csproj file or directory containing C# files
Lists all TODO and HACK comments with their locations (file and line number), making it easy to find and address them.
nmbl todos src/MyProject/MyProject.csproj
Shows all TODO and HACK comments in the project.
nmbl todos src/
Recursively searches all C# files in the directory tree.
nmbl todos src/ > technical-debt.txt
Save the list to track over time.
# Count TODO comments
nmbl todos src/ | grep -c "TODO"
# Count HACK comments
nmbl todos src/ | grep -c "HACK"
Get a count of technical debt items (Unix/Linux).
# Before cleanup
nmbl todos src/ > todos-before.txt
# After addressing items
nmbl todos src/ > todos-after.txt
# See what was fixed
diff todos-before.txt todos-after.txt
The command finds comments like:
// TODO: description// HACK: description/* TODO: description *//* HACK: description */
nmbl todos src/ > sprint-planning/technical-debt.txt
Review TODO items when planning work for the next sprint.
# Check for new TODOs in a feature branch
git checkout feature-branch
nmbl todos src/ > todos-feature.txt
git checkout main
nmbl todos src/ > todos-main.txt
diff todos-main.txt todos-feature.txt
Ensure new features don’t add excessive technical debt.
# Weekly report
nmbl todos src/ | wc -l > metrics/todo-count-$(date +%Y-%m-%d).txt
Track the number of TODO items over time.
# Before a release, address critical TODOs
nmbl todos src/ | grep -i "critical"
nmbl todos src/ | grep -i "before release"
Find items that must be addressed before shipping.
// ✅ Good - specific and actionable
// TODO: Replace magic number with constant after refactoring config system
// ❌ Bad - vague
// TODO: fix this
// TODO [P0]: Critical - must fix before release
// TODO [P1]: Important - should fix soon
// TODO [P2]: Nice to have - fix when time allows
- TODO: Future work, improvements, or known limitations
- HACK: Quick fixes or workarounds that should be refactored