Changeset - a4a10fc7b0ac
[Not reviewed]
0 4 0
Bradley Kuhn (bkuhn) - 11 years ago 2013-04-29 23:55:07
bkuhn@ebb.org
Initial documentation of the Program: tag.
Includes introduction of the section about making use of these tags.
4 files changed with 45 insertions and 1 deletions:
0 comments (0 inline, 0 general)
accounts/config/config-accounts.ledger
Show inline comments
...
 
@@ -43,3 +43,3 @@ account Accrued:Accounts Receivable:Main Org
 

	
 
define expenseChecker() = (tag("Receipt") !~ /^\s*$/ or tag("Invoice") !~ /^\s*$/ or tag("Statement") !~ /^\s*$/)
 
define expenseChecker() = (tag("Receipt") !~ /^\s*$/ or tag("Invoice") !~ /^\s*$/ or tag("Statement") !~ /^\s*$/) and tag("Program") !~ /^\s*$/
 
; or payee =~ /NEVER CHARGED/
accounts/config/config-tags.ledger
Show inline comments
...
 
@@ -41 +41,9 @@ tag IncomeType
 
    assert value =~ /^(Donations|RBI|UBTI)$/
 

	
 
; Program tag must match the general format of a ledger account as an
 
; assertion, but we at least check known names of programs, so that warnings
 
; are produced if a new program never seen before is encountered.
 

	
 
tag Program
 
    assert value =~ /[ A-z0-9\-]+(:[ A-z0-9\-]+)*/
 
    check  value =~ /^(Main Org:(Overhead|Direct Fundraising))$/
accounts/org/main-org.ledger
Show inline comments
...
 
@@ -8,2 +8,3 @@
 
    Expense:Main Org:Office Supplies          $35.00
 
        ;Program: Main Org:Overhead
 
    Liabilities:Credit Card:Visa             -$35.00
...
 
@@ -13,2 +14,3 @@
 
    Expense:Main Org:Hosting                 $100.00
 
        ;Program: Main Org:Overhead
 

	
...
 
@@ -17,2 +19,3 @@
 
    Expense:Main Org:Hosting                $-100.00
 
        ;Program: Main Org:Overhead
 

	
...
 
@@ -24 +27,2 @@
 
        ;IncomeType: Donations
 
        ;Program: Main Org:Direct Fundraising
npo-ledger-cli-tutorial.md
Show inline comments
...
 
@@ -263,2 +263,14 @@ Form 990 filing.
 

	
 
#### Program Tag
 

	
 
The `Program` tag is used primarily to track program activity for `Income:`
 
and `Expense:` accounts.  This allows for knowing what particular initiative
 
initiated the income (e.g., a specific fundraising campaign) and/or what
 
particular program activity an expense is toward (e.g., funding travel to
 
some specific conference).
 

	
 
The Program tag is always a string with the same format as a Ledger CLI
 
account (primarily for use with Ledger CLI's `--pivot` and `--group-by`,
 
[as described later](#testing-program-success).
 

	
 
### Expense Account Documentation
...
 
@@ -314,2 +326,22 @@ thus deprecated.
 

	
 
Analysis of the Data
 
--------------------
 

	
 
If this methodology is followed, Ledger can be used to analyze the financial
 
data for the organization.
 

	
 
### Testing Program Success
 

	
 
If you use the [`Program`](#program-tag) tag effectively, you can easily test
 
the successes of various fundraising programs with a command like this:
 

	
 
    $ ledger -f accounts/books.ledger --pivot Program bal '/^Income/'
 

	
 
Meanwhile, using the  [`Program`](#program-tag) tag for Expenses can help
 
track what programs are costing with commands like hese:
 

	
 
    $ ledger -f accounts/books.ledger --group-by 'tag("Program")' reg '/^Expense/'
 

	
 
FIXME: example output
 

	
 
Copyright and License of This File
0 comments (0 inline, 0 general)