summaryrefslogtreecommitdiff
path: root/bin/havedone.sh
blob: 7b71aca5d8637be0f626bf73d00c644c1b5cc8bf (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/bin/sh
cd ~/gtd
mkdir -p ~/gtd/done/$(date '+%Y-%m-%d')
OIFS="$IFS"
IFS=$'\n'
for f in $(find . -maxdepth 1 -type f -print0 | xargs -0 grep -li @done)
    do
        print $f
        mv $f ~/gtd/done/$(date '+%Y-%m-%d')
    done
IFS="$OIFS"