Browse Source

split windows differently if there's a backlog file

master
Ben Savage 4 years ago
parent
commit
0d6379dddf
  1. 10
      cl

10
cl

@ -3,7 +3,7 @@ PROFILE='default'
function debug() {
echo $DEBUG
if [ ${DEBUG:-0} ]; then
if [ ${DEBUG:-0} -ne 0 ]; then
echo "$(date): $@"
fi
}
@ -199,12 +199,16 @@ function captains_log() {
fi
vi -O $CLDIR/{$YESTERDAY,$TODAY,$TOMORROW}
if [ -f "$CLDIR/backlog" ]; then
vi $CLDIR/{$YESTERDAY,$TODAY,$TOMORROW,backlog} -s <( echo -e ":vsplit\n:wincmd w\n:next\n:vsplit\n:wincmd w\n:next\n:split\n:wincmd w\n:next")
else
vi -O $CLDIR/{$YESTERDAY,$TODAY,$TOMORROW}
fi
if [ $GIT -ne 0 ]; then
echo Updating git...
if [ $( git -C "$CLDIR" status -s |wc -l) -ne 0 ]; then
git -C "$CLDIR" add -Aq
git -C "$CLDIR" add -A
git -C "$CLDIR" commit -qm "Auto-Commit by $(basename $0)"
git -C "$CLDIR" push -q
fi

Loading…
Cancel
Save