#!/bin/bash # Find all TODO: marks in current git repository [ -n "$1" ] && cd "$1" if git rev-parse --show-toplevel &>/dev/null; then grep -n -R "^[[:space:]]*[#/\";-]*[[:space:]]*TODO:" . \ | expand \ | sed -r 's/([[:digit:]]):/\1:@@ /' \ | tr -s ' ' \ | column -t -s '@@' fi