hledger
hledger copied to clipboard
`.latest.-` with imports from stdin
Importing via stdin (i.e. hledger import ... csv:-) creates a .latest.- file with that run's latest date, which means any other piped imports are subjected to that minimum date. This was a bit of a surprise as I'd expect the latest date not to be tracked here.
I'm using stdin as a way to reformat a series of different CSV files (e.g. sed ... $f.csv | hledger import ... csv:-), and I'd expect in general the source of a stdin import to vary between runs, so to me it would make more sense to suppress the .latest.- file by default when piping import data in, or else to have an option to prevent its creation / ignore it when present.
The import command help text talks about manipulating the latest files when needed, so I guess there's an expectation here that I'd remove them myself each time -- it just feels a little counter-intuitive.