2011-01-19 22:00:42 +03:00
|
|
|
# amount layout tests, using default vertical layout
|
|
|
|
# 1. print
|
2010-07-12 02:51:36 +04:00
|
|
|
bin/hledger -f - print
|
|
|
|
<<<
|
|
|
|
2010/1/1
|
|
|
|
a EUR 1 ; a euro
|
|
|
|
b USD 1 ; a dollar
|
|
|
|
c ; a euro and a dollar
|
|
|
|
>>>
|
|
|
|
2010/01/01
|
|
|
|
a EUR 1 ; a euro
|
|
|
|
b USD 1 ; a dollar
|
|
|
|
EUR -1
|
|
|
|
c USD -1 ; a euro and a dollar
|
|
|
|
|
2011-01-19 22:00:42 +03:00
|
|
|
# 2. register
|
2010-07-12 02:51:36 +04:00
|
|
|
bin/hledger -f - register
|
|
|
|
<<<
|
|
|
|
2010/1/1
|
|
|
|
a EUR 1 ; a euro
|
|
|
|
b USD 1 ; a dollar
|
|
|
|
c ; a euro and a dollar
|
|
|
|
>>>
|
|
|
|
2010/01/01 a EUR 1 EUR 1
|
|
|
|
EUR 1
|
|
|
|
b USD 1 USD 1
|
|
|
|
EUR -1
|
|
|
|
c USD -1 0
|
2011-01-19 22:00:42 +03:00
|
|
|
# 3. balance
|
2010-07-12 02:51:36 +04:00
|
|
|
bin/hledger -f - balance
|
|
|
|
<<<
|
|
|
|
2010/1/1
|
|
|
|
a EUR 1 ; a euro
|
|
|
|
b USD 1 ; a dollar
|
|
|
|
c ; a euro and a dollar
|
|
|
|
>>>
|
|
|
|
EUR 1 a
|
|
|
|
USD 1 b
|
|
|
|
EUR -1
|
|
|
|
USD -1 c
|
|
|
|
--------------------
|
|
|
|
EUR 0
|
2011-01-19 22:00:42 +03:00
|
|
|
# 4. mixed amounts with prices
|
|
|
|
# XXX
|
|
|
|
# bin/hledger -f - print
|
|
|
|
# <<<
|
|
|
|
# 2010/1/1
|
|
|
|
# a EUR 1 @ USD 1.1 ; a euro
|
|
|
|
# b USD 1 ; a dollar
|
|
|
|
# c ; a euro and a dollar
|
|
|
|
# >>>
|
|
|
|
# 2010/01/01
|
|
|
|
# a EUR 1 @ USD 1.1 ; a euro
|
|
|
|
# b USD 1 ; a dollar
|
|
|
|
# EUR -1 @ USD 1.1
|
|
|
|
# c USD -1 ; a euro and a dollar
|
|
|
|
#
|
|
|
|
##
|
|
|
|
# 2010/01/01
|
|
|
|
# a EUR 1 @ USD 1.1 ; a euro
|
|
|
|
# b USD 1.0 ; a dollar
|
|
|
|
# c USD -2.1 ; a euro and a dollar
|
|
|
|
#
|
|
|
|
# #
|
|
|
|
# bin/hledger -f - register
|
|
|
|
# <<<
|
|
|
|
# 2010/1/1
|
|
|
|
# a EUR 1 @ USD 1.1 ; a euro
|
|
|
|
# b USD 1 ; a dollar
|
|
|
|
# c ; a euro and a dollar
|
|
|
|
# >>>
|
|
|
|
# 2010/01/01 a EUR 1 EUR 1
|
|
|
|
# EUR 1
|
|
|
|
# b USD 1.0 USD 1.0
|
|
|
|
# EUR 1
|
|
|
|
# c USD -2.1 USD -1.1
|
|
|
|
# #
|
|
|
|
# bin/hledger -f - balance
|
|
|
|
# <<<
|
|
|
|
# 2010/1/1
|
|
|
|
# a EUR 1 @ USD 1.1 ; a euro
|
|
|
|
# b USD 1 ; a dollar
|
|
|
|
# c ; a euro and a dollar
|
|
|
|
# >>>
|
|
|
|
# EUR 1 a
|
|
|
|
# USD 1.0 b
|
|
|
|
# USD -2.1 c
|
|
|
|
# --------------------
|
|
|
|
# EUR 1
|
|
|
|
# USD -1.1
|