Skip to content

Instantly share code, notes, and snippets.

@simonmichael
Last active March 20, 2025 08:52
Show Gist options
  • Save simonmichael/a1addcb652da4e78b183 to your computer and use it in GitHub Desktop.
Save simonmichael/a1addcb652da4e78b183 to your computer and use it in GitHub Desktop.

Revisions

  1. simonmichael revised this gist Jan 15, 2016. 1 changed file with 4 additions and 3 deletions.
    7 changes: 4 additions & 3 deletions envelope-budgeting.journal
    Original file line number Diff line number Diff line change
    @@ -135,9 +135,7 @@
    [assets:business:bank:wf:bchecking:available] $12.33
    [assets:business:bank:wf:bchecking:month:books] -$12.33

    ; Check your envelope balances periodically.
    ; Try to keep spending envelopes above zero, and to
    ; avoid unplanned withdrawals from savings envelopes.
    ; Check your envelope balances periodically:
    ;
    ; $ hledger bal checking:
    ; $2272.67 assets
    @@ -206,3 +204,6 @@
    ; or (good for reviewing transactions):
    ;
    ; $ hledger-ui checking:

    ; Try to keep spending envelopes above zero, and to
    ; avoid unplanned withdrawals from savings envelopes.
  2. simonmichael revised this gist Jan 15, 2016. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion envelope-budgeting.journal
    Original file line number Diff line number Diff line change
    @@ -135,7 +135,9 @@
    [assets:business:bank:wf:bchecking:available] $12.33
    [assets:business:bank:wf:bchecking:month:books] -$12.33

    ; Check your envelope balances periodically:
    ; Check your envelope balances periodically.
    ; Try to keep spending envelopes above zero, and to
    ; avoid unplanned withdrawals from savings envelopes.
    ;
    ; $ hledger bal checking:
    ; $2272.67 assets
  3. simonmichael revised this gist Jan 15, 2016. 1 changed file with 1 addition and 3 deletions.
    4 changes: 1 addition & 3 deletions envelope-budgeting.journal
    Original file line number Diff line number Diff line change
    @@ -142,7 +142,7 @@
    ; $340.58 business:bank:wf:bchecking
    ; $152.91 available
    ; $117.67 month
    ; $-2.33 books
    ; $-2.33 books <- overspent already
    ; $10.00 dues
    ; $40.00 equipment
    ; $20.00 online
    @@ -204,5 +204,3 @@
    ; or (good for reviewing transactions):
    ;
    ; $ hledger-ui checking:


  4. simonmichael revised this gist Jan 15, 2016. 1 changed file with 78 additions and 4 deletions.
    82 changes: 78 additions & 4 deletions envelope-budgeting.journal
    Original file line number Diff line number Diff line change
    @@ -55,6 +55,13 @@
    ; snacks
    ; gifts

    2016/1/1 * set up some balances for this example
    (assets:business:bank:wf:bchecking:month:books) $-9.42
    (assets:business:bank:wf:bchecking:available) $500
    (assets:personal:bank:wf:checking:month:food) $-24.28
    (assets:personal:bank:wf:checking:month:gifts) $-16.30
    (assets:personal:bank:wf:checking:available) $2100

    ; at the start of each month, zero out any overspending from last month:

    2016/1/1 * refill negative budget envelopes (business)
    @@ -99,7 +106,11 @@
    [assets:personal:bank:wf:checking:year:vacation] $50
    [assets:personal:bank:wf:checking:available] $-2000

    ; Then update appropriate envelopes as transactions are made:
    ; Update appropriate envelopes as transactions are made:

    2016/1/1 * automatic savings transfer
    assets:business:bank:wf:bchecking:month:autosave
    assets:business:bank:wf:savings:reserve $100

    2016/1/1 * automatic savings transfer
    assets:personal:bank:wf:checking:month:autosave
    @@ -124,11 +135,74 @@
    [assets:business:bank:wf:bchecking:available] $12.33
    [assets:business:bank:wf:bchecking:month:books] -$12.33

    ; etc.

    ; to check status:
    ; Check your envelope balances periodically:
    ;
    ; $ hledger bal checking:
    ; $2272.67 assets
    ; $340.58 business:bank:wf:bchecking
    ; $152.91 available
    ; $117.67 month
    ; $-2.33 books
    ; $10.00 dues
    ; $40.00 equipment
    ; $20.00 online
    ; $20.00 research
    ; $20.00 software
    ; $10.00 supplies
    ; $70.00 year
    ; $20.00 conferences
    ; $10.00 education
    ; $40.00 legal/accounting
    ; $1932.09 personal:bank:wf:checking
    ; $47.09 available
    ; $1835.00 month
    ; $30.00 clothing
    ; $288.00 food
    ; $27.00 gifts
    ; $300.00 health
    ; $1000.00 home
    ; $20.00 personal care
    ; $80.00 phone
    ; $20.00 recreation
    ; $20.00 spiritual
    ; $50.00 transport
    ; $50.00 year:vacation
    ; --------------------
    ; $2272.67
    ;
    ; $ hledger bal checking: --weekly --historical --drop 4
    ; Ending balances (historical) in 2015/12/28-2016/01/10:
    ;
    ; || 2016/01/03 2016/01/10
    ; =================================++=========================
    ; bchecking:available || $140.58 $152.91
    ; bchecking:month:books || $10.00 $-2.33
    ; bchecking:month:dues || $10.00 $10.00
    ; bchecking:month:equipment || $40.00 $40.00
    ; bchecking:month:online || $20.00 $20.00
    ; bchecking:month:research || $20.00 $20.00
    ; bchecking:month:software || $20.00 $20.00
    ; bchecking:month:supplies || $10.00 $10.00
    ; bchecking:year:conferences || $20.00 $20.00
    ; bchecking:year:education || $10.00 $10.00
    ; bchecking:year:legal/accounting || $40.00 $40.00
    ; checking:available || $59.42 $47.09
    ; checking:month:clothing || $30.00 $30.00
    ; checking:month:food || $288.00 $288.00
    ; checking:month:gifts || $27.00 $27.00
    ; checking:month:health || $300.00 $300.00
    ; checking:month:home || $1000.00 $1000.00
    ; checking:month:personal care || $20.00 $20.00
    ; checking:month:phone || $80.00 $80.00
    ; checking:month:recreation || $20.00 $20.00
    ; checking:month:spiritual || $20.00 $20.00
    ; checking:month:transport || $50.00 $50.00
    ; checking:year:vacation || $50.00 $50.00
    ; ---------------------------------++-------------------------
    ; || $2285.00 $2272.67
    ;
    ; or (good for reviewing transactions):
    ;
    ; $ hledger-ui checking:


  5. simonmichael revised this gist Jan 15, 2016. 1 changed file with 9 additions and 3 deletions.
    12 changes: 9 additions & 3 deletions envelope-budgeting.journal
    Original file line number Diff line number Diff line change
    @@ -1,8 +1,8 @@
    ; An example of YNAB-ish envelope budgetting with hledger/ledger
    ; cf https://github.com/simonmichael/hledger/issues/315

    ; Using accounts like the following:
    ;
    ; Accounts overview:
    ; $ hledger -f data/envelope-budgeting.journal accounts --ignore --tree
    ; assets
    ; business
    ; bank
    @@ -99,7 +99,7 @@
    [assets:personal:bank:wf:checking:year:vacation] $50
    [assets:personal:bank:wf:checking:available] $-2000

    ; update appropriate envelopes as transactions are made:
    ; Then update appropriate envelopes as transactions are made:

    2016/1/1 * automatic savings transfer
    assets:personal:bank:wf:checking:month:autosave
    @@ -126,3 +126,9 @@

    ; etc.

    ; to check status:
    ; $ hledger bal checking:
    ; or (good for reviewing transactions):
    ; $ hledger-ui checking:


  6. simonmichael revised this gist Jan 15, 2016. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion envelope-budgeting.journal
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,7 @@
    ; An example of YNAB-ish envelope budgetting with hledger/ledger
    ; cf https://github.com/simonmichael/hledger/issues/315
    ;
    ; Accounts used below:
    ; Accounts overview:
    ; $ hledger -f data/envelope-budgeting.journal accounts --ignore --tree
    ; assets
    ; business
  7. simonmichael revised this gist Jan 15, 2016. 1 changed file with 54 additions and 0 deletions.
    54 changes: 54 additions & 0 deletions envelope-budgeting.journal
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,59 @@
    ; An example of YNAB-ish envelope budgetting with hledger/ledger
    ; cf https://github.com/simonmichael/hledger/issues/315
    ;
    ; Accounts used below:
    ; $ hledger -f data/envelope-budgeting.journal accounts --ignore --tree
    ; assets
    ; business
    ; bank
    ; wf
    ; bchecking
    ; available
    ; month
    ; autosave
    ; banking
    ; books
    ; dues
    ; equipment
    ; online
    ; research
    ; software
    ; supplies
    ; year
    ; conferences
    ; education
    ; legal/accounting
    ; personal
    ; bank
    ; wf
    ; checking
    ; available
    ; month
    ; autosave
    ; clothing
    ; food
    ; gifts
    ; health
    ; home
    ; personal care
    ; phone
    ; recreation
    ; spiritual
    ; transport
    ; year
    ; vacation
    ; savings
    ; reserve
    ; expenses
    ; business
    ; books/periodicals
    ; online
    ; hosting
    ; personal
    ; food
    ; dining
    ; snacks
    ; gifts

    ; at the start of each month, zero out any overspending from last month:

  8. simonmichael created this gist Jan 15, 2016.
    74 changes: 74 additions & 0 deletions envelope-budgeting.journal
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,74 @@
    ; An example of YNAB-ish envelope budgetting with hledger/ledger
    ; cf https://github.com/simonmichael/hledger/issues/315

    ; at the start of each month, zero out any overspending from last month:

    2016/1/1 * refill negative budget envelopes (business)
    [assets:business:bank:wf:bchecking:month:books] $9.42 = $0
    [assets:business:bank:wf:bchecking:available] $-9.42

    2016/1/1 * refill negative budget envelopes (personal)
    [assets:personal:bank:wf:checking:month:food] $24.28 = $0
    [assets:personal:bank:wf:checking:month:gifts] $16.30 = $0
    [assets:personal:bank:wf:checking:available] $-40.58

    ; and transfer funds to various envelopes (books, etc.) for this month's
    ; spending, and longer-term saving goals:

    2016/1/1 * budget for this month's business expenses
    [assets:business:bank:wf:bchecking:month:autosave] $100
    [assets:business:bank:wf:bchecking:month:banking] 0
    [assets:business:bank:wf:bchecking:month:books] $10
    [assets:business:bank:wf:bchecking:month:dues] $10
    [assets:business:bank:wf:bchecking:month:equipment] $40
    [assets:business:bank:wf:bchecking:month:online] $70
    [assets:business:bank:wf:bchecking:month:research] $20
    [assets:business:bank:wf:bchecking:month:software] $20
    [assets:business:bank:wf:bchecking:month:supplies] $10
    [assets:business:bank:wf:bchecking:year:conferences] $20
    [assets:business:bank:wf:bchecking:year:education] $10
    [assets:business:bank:wf:bchecking:year:legal/accounting] $40
    [assets:business:bank:wf:bchecking:available] $-350

    2016/1/1 * budget for this month's personal expenses
    [assets:personal:bank:wf:checking:month:autosave] $100
    [assets:personal:bank:wf:checking:month:clothing] $30
    [assets:personal:bank:wf:checking:month:food] $300
    [assets:personal:bank:wf:checking:month:gifts] $30
    [assets:personal:bank:wf:checking:month:health] $300
    [assets:personal:bank:wf:checking:month:home] $1000
    [assets:personal:bank:wf:checking:month:personal care] $20
    [assets:personal:bank:wf:checking:month:phone] $80
    [assets:personal:bank:wf:checking:month:recreation] $20
    [assets:personal:bank:wf:checking:month:spiritual] $20
    [assets:personal:bank:wf:checking:month:transport] $50
    [assets:personal:bank:wf:checking:year:vacation] $50
    [assets:personal:bank:wf:checking:available] $-2000

    ; update appropriate envelopes as transactions are made:

    2016/1/1 * automatic savings transfer
    assets:personal:bank:wf:checking:month:autosave
    assets:personal:bank:wf:savings:reserve $100

    2016/1/2 * linode
    expenses:business:online:hosting $50
    assets:business:bank:wf:bchecking:month:online

    2016/1/3 * market
    expenses:personal:food:dining $10
    expenses:personal:food:snacks $2
    assets:personal:bank:wf:checking:month:food $-12
    expenses:personal:gifts $3
    assets:personal:bank:wf:checking:month:gifts $-3

    2016/1/4 * amazon open source everything
    ; a business purchase from personal account - use available
    expenses:business:books/periodicals $12.33
    assets:personal:bank:wf:checking:available -$12.33
    ; and adjust the appropriate business envelope
    [assets:business:bank:wf:bchecking:available] $12.33
    [assets:business:bank:wf:bchecking:month:books] -$12.33

    ; etc.