;journal: document improved lot price parsing; changelog
This commit is contained in:
		
							parent
							
								
									ea3b290dd0
								
							
						
					
					
						commit
						5beeb56a87
					
				| @ -549,9 +549,6 @@ There are several ways to record a transaction price: | ||||
|       assets:dollars  $-135          ; for $135 | ||||
|     ``` | ||||
| 
 | ||||
| (Ledger users: Ledger uses a different [syntax](http://ledger-cli.org/3.0/doc/ledger3.html#Fixing-Lot-Prices) | ||||
| for fixed prices, `{=UNITPRICE}`, which hledger currently ignores). | ||||
| 
 | ||||
| Use the [`-B/--cost`](hledger.html#reporting-options) flag to convert | ||||
| amounts to their transaction price's commodity, if any. | ||||
| (mnemonic: "B" is from "cost Basis", as in Ledger). | ||||
| @ -582,6 +579,19 @@ $ hledger bal -N --flat -B | ||||
|                 €100  assets:euros | ||||
| ``` | ||||
| 
 | ||||
| ## Lot Prices | ||||
| 
 | ||||
| Ledger allows another kind of price,  | ||||
| [lot price](http://ledger-cli.org/3.0/doc/ledger3.html#Fixing-Lot-Prices), | ||||
| to be specified in curly braces | ||||
| (three variants: `{UNITPRICE}`, `{{TOTALPRICE}}`, `{=FIXEDUNITPRICE}`). | ||||
| This is normally used to select a lot when selling investments. | ||||
| hledger will parse these, for compatibility with Ledger journals, but | ||||
| currently ignores them. | ||||
| They may appear after the posting amount, before or after the | ||||
| [transaction price](#transaction-prices) if any, and before the | ||||
| balance assertion if any. | ||||
| 
 | ||||
| ## Balance Assertions | ||||
| 
 | ||||
| hledger supports | ||||
|  | ||||
| @ -3,6 +3,13 @@ User-visible changes in the hledger command line tool and library. | ||||
| 
 | ||||
| # e7e9f1ee | ||||
| 
 | ||||
| - Improved parse compatibility for Ledger lot prices: | ||||
|   hledger up to 1.17.1 did not accept Ledger's lot price syntax except | ||||
|   in vary limited circumstances (`{= }` at the end of the posting line). | ||||
|   hledger now accepts all three lot price syntaxes (`{ }`, `{{ }}`, `{= }`), | ||||
|   anywhere after the posting amount but before any balance assertion. | ||||
|   All of these lot prices are ignored. | ||||
| 
 | ||||
| - csv: don't discard explicit assignments of a 0 amount | ||||
|   Eg: an `amount1  $0.00` assignment was generating a posting1 with | ||||
|   missing amount. | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user