The Command-Line Accountant

Simple accounting for the financially-disinclined

Not all of us have CPA's or have 99% of our life to spend on balancing our checkbook. If you want an easy, straight-to-the-point method to balancing your budget, check out the Command-line Accountant! It handles multiple users (on UNIX-based systems), multiple accounts per user, IOU's, and more. For simplicity, it does not use check numbers. Its interface works purely on command-line arguments-- there is no interactivity whatsoever. The good news is that this makes clacct completely scriptable!

The new version 0.2 is available with a flexible rule-processor 'clarule.' See below for details.

Download it here.

Hosted by SourceForge.net Logo

Sample session

SHELL>clacct -n checking              #creates a new account called 'checking' 
SHELL>clacct -a checking -amount +1000 -note 'starting balance'
SHELL>clacct -a checking -amount -715 -note 'rent payment'
SHELL>clacct -l -acc checking         #list the transactions on the account named 'checking'
1. Dec 10, 2003 (10:03)  +1000   1000   starting balance 
2. Dec 10, 2003 (10:03)  -715    285    rent payment 
SHELL>clacct -n mastercard
SHELL>clacct -a mastercard -amount -35000 -note 'starting balance'
SHELL>clacct -l            #list all accounts
checking
mastercard
SHELL>clacct -v -l         #verbosely list all accounts
checking ($285)
mastercard ($-35000)
SHELL>clacct -iou 700 -note "Darl McBride"   #add an I.O.U
SHELL>clacct -liou                           #list all I.O.U's
1. 700    Darl McBride
SHELL>clacct -pay 1
SHELL>clacct -liou                         #nothing happens
SHELL>clacct -v -liou                      #verbosely list all I.O.U's
1. 700    Darl McBride (paid on 12/10/03)
Total Owed: $0
SHELL>                #move money from one account to another
SHELL>clacct -mv 100 -from checking -to mastercard -note 'mc payment'
SHELL>clacct -l -acc mastercard
1. Dec 10, 2003 (10:07) -35000 -35000 starting balance
2. Dec 10, 2003 (10:08) 100    -34900 mc payment
SHELL>clacct -rec checking -amount 149  #reconcile your account
SHELL>clacct -l -acc checking
1. Dec 10, 2003 (10:03)  +1000   1000   starting balance 
2. Dec 10, 2003 (10:03)  -715    285    rent payment
3. Dec 10, 2003 (10:08)  -100    185    mc payment
3. Dec 10, 2003 (10:09)  -36     149    Account reconciliation 

The Rule-Processor

Start by creating a file called _rules in your ~/.clacct/ directory with contents per the following grammar:
Rule "[name]":
 [pay|receive] [amount|'variable amount']
    every ['day'|'week'|'month'] [on [mday|wkday]] [and on...]
    every [n] ['days'|'weeks'|'months'] [on [mday|wkday]]
    from [accountName]
    to [accountName]
    starting [date]
    ending [date]
    ending when balance of [accountName] is [amount];

Example _rules file

Rule "paycheck":
    receive $70 to checking
    every 2 weeks
    on friday
    starting 1/1/2004;

Rule "Alimony check":
    pay $100
    every month
    on 1
    and on 15
    from checking
    to alimonyfund
    starting 1/1/2004
    ending 1/1/2057;

Rule "mortgage":
   pay 543.21
   from checking
   to mortgage
   every month
   on 1
   starting 1/2/2004
   ending when balance of mortgage is 75000;
From the shell, then, just type:
SHELL>clarule
Applied Rule mortgage for 1 Feb 2004
Applied Rule mortgage for 1 Mar 2004
Applied Rule Alimony check for 1 Jan 2004
Applied Rule Alimony check for 15 Jan 2004
...
Then, going back to clacct, type (at the shell prompt)clacct -l -acc checking to see the changes made on the checking account.

Future plans

FAQ

How do I get help?

At the shell prompt, type: clacct --help
or leave a message in the help forum on the SourceForge project site at http://www.sourceforge.net/projects/clacct.
Last updated on December 21st, 2003 **The current version of the Command-Line Accountant is 0.11**