From e56ccdca8e4b66e88a3a6c333a286d0163097ee9 Mon Sep 17 00:00:00 2001 From: DarkWiiPlayer Date: Thu, 25 Feb 2021 09:53:10 +0100 Subject: [PATCH] Add git todo script to crawl tasks in repositories --- bin/git-todo | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100755 bin/git-todo diff --git a/bin/git-todo b/bin/git-todo new file mode 100755 index 0000000..3691081 --- /dev/null +++ b/bin/git-todo @@ -0,0 +1,15 @@ +#!/bin/sh + +if [ -z "$1" ] +then dir="." +else dir=$1 +fi + +for root in $(find -L $dir -name '.git' -type d | xargs -L 1 dirname ) +do + if [ -d $root/.git/task ] + then + echo "→ \033[1;4;33m"$root"\033[0m" + (cd $root; git task 2>/dev/null | head -n -1 | sed -e '3d' ) + fi +done