Commit Graph

32 Commits

Author SHA1 Message Date
Simon Michael
102b76c17f lib: textification: commodity symbols
hledger -f data/100x100x10.journal stats
<<ghc: 39288536 bytes, 77 GCs, 196608/269560 avg/max bytes residency (3 samples), 2M in use, 0.000 INIT (0.001 elapsed), 0.016 MUT (0.028 elapsed), 0.009 GC (0.012 elapsed) :ghc>>
<<ghc: 39290808 bytes, 77 GCs, 196608/269560 avg/max bytes residency (3 samples), 2M in use, 0.000 INIT (0.003 elapsed), 0.015 MUT (0.021 elapsed), 0.009 GC (0.011 elapsed) :ghc>>

hledger -f data/1000x100x10.journal stats
<<ghc: 314268960 bytes, 612 GCs, 2143219/6826152 avg/max bytes residency (7 samples), 16M in use, 0.000 INIT (0.009 elapsed), 0.135 MUT (0.151 elapsed), 0.065 GC (0.178 elapsed) :ghc>>
<<ghc: 314254512 bytes, 612 GCs, 2072377/6628024 avg/max bytes residency (7 samples), 16M in use, 0.000 INIT (0.000 elapsed), 0.130 MUT (0.134 elapsed), 0.064 GC (0.075 elapsed) :ghc>>

hledger -f data/10000x100x10.journal stats
<<ghc: 3070016592 bytes, 5965 GCs, 13138220/64266016 avg/max bytes residency (10 samples), 128M in use, 0.000 INIT (0.000 elapsed), 1.272 MUT (1.322 elapsed), 0.527 GC (0.595 elapsed) :ghc>>
<<ghc: 3069989896 bytes, 5973 GCs, 12687877/62848920 avg/max bytes residency (10 samples), 124M in use, 0.000 INIT (0.002 elapsed), 1.295 MUT (1.324 elapsed), 0.511 GC (0.570 elapsed) :ghc>>

hledger -f data/100000x100x10.journal stats
<<ghc: 30753448072 bytes, 59763 GCs, 121502982/673169248 avg/max bytes residency (14 samples), 1640M in use, 0.000 INIT (0.007 elapsed), 12.421 MUT (12.672 elapsed), 6.240 GC (7.812 elapsed) :ghc>>
<<ghc: 30753350528 bytes, 59811 GCs, 117616668/666703600 avg/max bytes residency (14 samples), 1588M in use, 0.001 INIT (0.011 elapsed), 13.209 MUT (13.683 elapsed), 6.137 GC (7.117 elapsed) :ghc>>
2016-05-24 19:00:57 -07:00
Simon Michael
9e9aec957f print: --match shows the best match for a description
This was originally an add-on I used to guess account names for
ledger-autosync. It's nice for quickly looking up a recent transaction
with a guessed or partial description.
2015-08-28 15:10:51 -07:00
Simon Michael
74512814ec cli/ui/web: rename X.Options modules to X.XOptions
Make these modules' names more like the heavily-used types they
define (CliOpts, UIOpts, WebOpts). This is consistent with
RawOptions and ReportOptions, and helps with code navigation.
2015-08-28 12:43:51 -07:00
Simon Michael
3932655bde lib: expose two functions required by hledger-ui 2015-08-13 11:53:28 -07:00
Simon Michael
d1f63334ee handle pending status correctly, add --pending (#250)
A transaction/posting status of ! (pending) was effectively equivalent
to * (cleared). Now it's a separate state, not matched by --cleared.
The new Ledger-compatible --pending flag matches it, and so does
--uncleared. The equivalent search queries are now status:*, status:!
and status: (the old status:1 and status:0 spellings are deprecated).

Since we interpret --uncleared and status: as "any state except cleared",
it's not currently possible to match things which are neither cleared
nor pending.
2015-05-16 11:51:35 -07:00
Simon Michael
592d997438 whitespace 2015-03-29 16:03:23 -07:00
Simon Michael
855d4e1131 balance: with --tree and --flat, use the last (fix #219) 2014-12-05 12:56:33 -08:00
Simon Michael
9416d12d8a --output -> --output-file/-o & --output-format/-O, refactor
Use two options and less surprising behaviour. Notes:
* a recognised suffix on the output file name can set the format
* but --output-format always wins
* -o - means stdout
* currently these are command-specific options on balance, print, register
* later, --output-file should become a global option
* and --output-format should be available at least on all commands which
  support multiple formats. Each command may support a different set of
  output formats, which should be listed in its command line help.
2014-10-21 17:14:37 -07:00
Simon Michael
b6774f47a3 balance, print: add -o and CSV output here too
Not very elegant yet, but works.
2014-10-21 12:02:23 -07:00
gwern
d1618aaca8 strip trailing whitespace from all Haskell files 2014-10-14 18:48:24 -07:00
Simon Michael
7d73ab5264 cli: drop single-letter aliases, keep the familiar three-letter ones where useful 2014-04-27 18:46:34 -07:00
Simon Michael
6b5ed3d790 print: drop unnecessary showTransactions
refactor the tests later
2014-04-05 19:39:18 -07:00
Simon Michael
2d1e0d7cd4 move command-specific options to the respective command modules 2014-03-21 10:45:13 -07:00
Simon Michael
3ee6a351f3 big query/tests/show refactoring
- use new query system for command line too, filterspec is no more
- move unit tests near the code they test, run them in bottom up order, add more
- more precise Show instances, used for debugging not ui
2012-05-27 18:14:20 +00:00
Simon Michael
a27eb7c29f more matcher -> query renaming 2012-05-16 07:37:24 +00:00
Simon Michael
8492f6cae4 fix unicode handling on GHC >= 7.2, unify utf8 IO compatibility layer
tests pass again from GHC 6.12.3 to 7.4.1
2012-03-29 19:06:31 +00:00
Simon Michael
9a0a0be01c docs: whitespace 2011-09-23 14:27:26 +00:00
Simon Michael
a44aa8d7d2 refactor: remove unnecessary LANGUAGE CPP pragmas 2011-07-17 23:29:57 +00:00
Simon Michael
cbb0fc5c59 move basic reports into hledger-lib 2011-08-15 22:59:06 +00:00
Simon Michael
059825a9b2 optionsgeddon.. port to cmdargs and a fully modal cli 2011-08-15 22:50:09 +00:00
Simon Michael
6496c1ef61 raw journal report -> journal entries report 2011-08-07 16:24:09 +00:00
Simon Michael
ce30cb2cbe refactor: try to get these report names under control 2011-07-19 00:49:11 +00:00
Simon Michael
47b1142d49 move reports back to Hledger.Cli for now, forgot they still depend on cli options 2011-07-18 23:30:40 +00:00
Simon Michael
e4c4405c62 refactor: simplify some imports 2011-07-17 23:05:56 +00:00
Simon Michael
df7dc1464e refactor: move basic report generation to hledger-lib 2011-07-17 23:47:52 +00:00
Simon Michael
c565b2606d simplify api, optsToFilterSpec just needs a day not a time 2011-06-13 23:28:39 +00:00
Simon Michael
e7c6ee3dc3 refactor: convert to cost-basis at report time, not startup time 2011-06-03 03:29:57 +00:00
Simon Michael
eb6395e91c fix that refactoring for web handlers 2011-06-03 02:52:08 +00:00
Simon Michael
5084280879 imports, api cleanup 2011-05-28 04:11:44 +00:00
Simon Michael
dc7a692a19 refactor: remove costbasis and whichdate from FilterSpec 2011-06-03 02:14:36 +00:00
Simon Michael
6a845eb5e4 i18n: always read and write UTF-8, ignoring current locale (#34)
Also remove a bunch of CPP conditions.
Uses the GHC-version-independent UTF-8 layer from pandoc.
2011-01-21 01:24:51 +00:00
Simon Michael
1127c3f52f flatten modules a little 2010-11-15 06:48:49 +00:00