From f6f4a46cf5b14f9a2170cd6475958efbf320caec Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Tue, 5 Aug 2008 13:17:04 -0400 Subject: Moved around most of the files so that source code is in src/, documentation is in doc/, etc. --- contrib/scripts/entry | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100755 contrib/scripts/entry (limited to 'contrib/scripts/entry') diff --git a/contrib/scripts/entry b/contrib/scripts/entry new file mode 100755 index 00000000..cc030d8e --- /dev/null +++ b/contrib/scripts/entry @@ -0,0 +1,16 @@ +#!/bin/sh + +if [ -z "$LEDGER" -o ! -r "$LEDGER" ]; then + echo Please set your LEDGER environment variable. +fi + +line=`wc -l $LEDGER | awk '{print $1}'` + +if ledger entry "$@" > /tmp/entry; then + cat /tmp/entry >> $LEDGER +else + echo "$@" >> $LEDGER +fi +rm /tmp/entry + +vi +$line $LEDGER -- cgit v1.2.3