Related to #563, when rendering a transaction, we reserve two more chars of width so that amounts remain aligned when there are posting flags. Affects hledger-ui's transaction screen, print, hledger-rewrite etc.
		
			
				
	
	
		
			77 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			77 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
# filtering by transaction status
 | 
						|
 | 
						|
# 1. with --cleared, print shows cleared transactions only
 | 
						|
hledger -f- print --cleared
 | 
						|
<<<
 | 
						|
2010/1/1 x
 | 
						|
  a  1
 | 
						|
  b
 | 
						|
 | 
						|
2010/1/2 * x
 | 
						|
  a  1
 | 
						|
  b
 | 
						|
 | 
						|
2010/1/3 *
 | 
						|
  a  1
 | 
						|
  b
 | 
						|
>>>
 | 
						|
2010/01/02 * x
 | 
						|
    a               1
 | 
						|
    b
 | 
						|
 | 
						|
2010/01/03 *
 | 
						|
    a               1
 | 
						|
    b
 | 
						|
 | 
						|
>>>=0
 | 
						|
 | 
						|
# 2. with --uncleared, shows uncleared transactions only
 | 
						|
hledger -f- print --uncleared
 | 
						|
<<<
 | 
						|
2010/1/1 x
 | 
						|
  a  1
 | 
						|
  b
 | 
						|
 | 
						|
2010/1/2 * x
 | 
						|
  a  1
 | 
						|
  b
 | 
						|
 | 
						|
2010/1/3 *
 | 
						|
  a  1
 | 
						|
  b
 | 
						|
>>>
 | 
						|
2010/01/01 x
 | 
						|
    a               1
 | 
						|
    b
 | 
						|
 | 
						|
>>>=0
 | 
						|
 | 
						|
# 3. can also have per-posting cleared status
 | 
						|
hledger -f- register --cleared
 | 
						|
<<<
 | 
						|
2012/1/1
 | 
						|
  a  1
 | 
						|
  *b  2
 | 
						|
  * c  4
 | 
						|
  d
 | 
						|
>>>
 | 
						|
2012/01/01                      b                                2             2
 | 
						|
                                c                                4             6
 | 
						|
>>>= 0
 | 
						|
 | 
						|
 | 
						|
# 4. also works with balance as shown, same as ledger. Hmm.
 | 
						|
hledger -f- balance --uncleared
 | 
						|
<<<
 | 
						|
2012/1/1
 | 
						|
  a  1
 | 
						|
  *b  2
 | 
						|
  d
 | 
						|
 | 
						|
>>>
 | 
						|
                   1  a
 | 
						|
                  -3  d
 | 
						|
--------------------
 | 
						|
                  -2
 | 
						|
>>>=0
 |