Commit Graph

9098 Commits

Author SHA1 Message Date
Simon Michael
a1321b7f26 ;shake: commandhelp -> commandtxts, don't build this for "manuals" 2020-09-07 11:41:56 -07:00
Simon Michael
5344913d04 ;make ghci[d]-shake: extra package needed sometimes 2020-09-07 09:23:42 -07:00
Simon Michael
f8a57dae51 ;shake: help, cleanups 2020-09-07 09:23:42 -07:00
Simon Michael
5c86e0bdbd ;shake changelogs: do both dev & release updates, based on .version
And add changelogs-dry.
2020-09-07 09:23:42 -07:00
Simon Michael
79b532017b ;shake: setversion can operate on specified packages 2020-09-07 09:23:42 -07:00
Simon Michael
fdd346294f ;shake: setversion can save a new version number 2020-09-07 09:23:42 -07:00
Simon Michael
465e8cbc51 ;make: update help 2020-09-07 09:23:42 -07:00
Simon Michael
ec2826ba09 ;shake: cleanup 2020-09-07 09:23:42 -07:00
Simon Michael
13ccd23304 ;shake: bump resolver 2020-09-07 09:23:42 -07:00
Simon Michael
ab9e50003c shake: refactor; use only the first argument as build target 2020-09-07 09:23:42 -07:00
Simon Michael
a5fcb19bb0 ;doc: changelog updates 2020-09-07 09:23:42 -07:00
Stephen Morgan
600dab3976 lib: Correctly strip ansi sequences with no numbers/semicolons. 2020-09-06 19:11:28 -07:00
Jakob Schöttl
1fb6f17bb2 Update shell completion for current master (v1.19) 2020-09-06 17:11:59 -07:00
Simon Michael
a965bc8e75 install: add hledger-interest 1.6 2020-09-03 09:57:34 -07:00
Simon Michael
a9fbaaf284 ;partial comment cleanups 2020-09-03 09:52:00 -07:00
Simon Michael
c2929939e4 make account type autodetection (& hledger-smooth) case insensitive again (#1341)
lib: added case-insensitive variants of the accountNameToRegex functions.
2020-09-03 09:52:00 -07:00
Simon Michael
a229b658e8 ;tests: convert balancesheet tests to new format 2020-09-03 09:03:55 -07:00
Simon Michael
f4c4f06474 ;doc: 1.19 announcement 2020-09-02 12:38:49 -07:00
Simon Michael
0751536d25 install: bump minimum stack version to 2.3.1 2020-09-02 12:33:38 -07:00
Simon Michael
3ff8a6291f ;ci: release: see if making branches explicit enables this 2020-09-02 11:41:17 -07:00
Simon Michael
bb1d8f5ed8 ;ci: linux: re-enable artifact building 2020-09-02 11:09:19 -07:00
Simon Michael
d2a1afdfc2 ;ci: mac: invalidate mac cache to work around the usual failure
(cf https://github.com/haskell/cabal/issues/1076#issuecomment-685879454)
2020-09-02 10:35:28 -07:00
Simon Michael
5f1e040ad7 stack: bump default resolver to lts 16.12, ghc 8.8.4 2020-09-02 10:20:57 -07:00
Simon Michael
e95a222ad2 ;update some cabal files 2020-09-01 20:39:02 -07:00
Simon Michael
b9ff6c91c1 update hledger-install versions 2020-09-01 20:31:31 -07:00
Simon Michael
09ac90a70a ;doc: finalise changelogs 2020-09-01 20:28:04 -07:00
Simon Michael
3170cc7cbd bump version to 1.19 2020-09-01 20:27:17 -07:00
Simon Michael
7aefa6f0ce ;doc: changelogs 2020-09-01 20:23:30 -07:00
Simon Michael
e44c1cfae8 ;regen manuals 2020-09-01 16:31:18 -07:00
Simon Michael
c1a985f1c8 ;bal: doc: drop link to resolved sorting issue (#1279) 2020-09-01 16:31:18 -07:00
Simon Michael
4c3eaa5ffa ;stack: fix duplicate in stack8.4.yaml 2020-09-01 12:13:09 -07:00
Simon Michael
58f989715a Replace our stringly Regex with a safer compiled Regexp type
This PR #1330, addressing #1312 (parseQuery is partial) and #1245
(internal server error).

User-visible changes:

- hledger-web now handles malformed regular expressions
  (eg, a query consisting of the single character `?`) gracefully,
  showing a tidy error message instead "internal server error".

API/internal changes:

- The Regex type alias has been replaced by the Regexp ADT, which
  contains both the compiled regular expression (so is guaranteed to
  be usable at runtime) and the original string (so can be serialised,
  printed, compared, etc.) A Regexp also knows whether is it case
  sensitive or case insensitive. The Hledger.Utils.Regex api has changed.

- Typeable and Data instances are no longer derived for hledger's
  data types; they were redundant/no longer needed

- NFData instances are no longer derived for hledger's data types.
  This speeds up a full build by roughly 7%. But it means we can't
  deep-evaluate hledger values, or time hledger code with Criterion.
  https://github.com/simonmichael/hledger/pull/1330#issuecomment-684075129
  has some ideas on this.

- Query no longer has a custom Show instance

- Some internal use of regexps was replaced by text replacement or
  parsers.

- Hledger.Utils.String: quoteIfNeeded now actually escapes quotes in
  strings; dropped escapeQuotes

- Hledger.Utils.Tree: dropped some old utilities

- dropped some obsolete code for the old --display option

Merge branch 'regexp' into master
2020-09-01 10:33:33 -07:00
Stephen Morgan
7d1e6d7d12 lib: Fix quoteIfNeeded so it actually escapes quotes. 2020-09-01 11:41:55 +10:00
Stephen Morgan
07dd30c1e5 lib,cli,ui: Change to consistent naming scheme for Hledger.Utils.Regex. 2020-09-01 11:36:34 +10:00
Stephen Morgan
5b647902c9 lib: Filter starting balances by subreport query in compoundBalanceReportWith. 2020-08-31 09:07:11 -07:00
Stephen Morgan
b91b391d08 lib: Replace some regex functions with parsers. 2020-08-31 22:44:41 +10:00
Stephen Morgan
20b39a5dd0 lib: Remove unused --display code.
This was dropped back in 2014, and getting rid of this removes a use of
regular expressions.
2020-08-31 20:45:37 +10:00
Stephen Morgan
8dfffb1e61 lib,web: Replace regex functions with simple text replacement. 2020-08-31 20:45:28 +10:00
Stephen Morgan
2cd7877c46 lib: Remove unnecessary NFData instances. 2020-08-31 15:41:36 +10:00
Stephen Morgan
af31d6e140 lib,cli,ui: Remove redundant Typeable and Data instances.
Also add some explicit import lists.
2020-08-31 15:41:30 +10:00
Stephen Morgan
01f5a92761 lib: Improve Read and Show instances for Regexp, get rid of custom show instance for Query. 2020-08-31 12:04:47 +10:00
Stephen Morgan
e3b2c94353 lib: Remove unneeded total Query code. 2020-08-31 12:04:47 +10:00
Stephen Morgan
e5371d5a6a lib,cli,ui,web: Make Regexp a wrapper for Regex. 2020-08-31 12:04:45 +10:00
Stephen Morgan
ccd6fdd7b9 lib: Remove unused Tree functions. 2020-08-31 11:51:25 +10:00
Simon Michael
40ca6c62e7 Avoid some uses of fromIntegral, parse numbers more robustly.
This is PR #1326, addressing #1325 (fromIntegral considered harmful).

User-visible changes:

- parsing numbers with more than 255 decimal places now gives an error
  instead of silently misparsing.

- digit groups are now limited to at most 255 digits each.

- exponents greater than 9223372036854775807 or less than
  -9223372036854775808 are now parsed correctly, in theory. (In
  practice, very large exponents will cause hledger to eat all your
  memory, so avoid them for now.)

API/internal changes:

- some fromIntegral calls have been replaced with safer code
  avoiding potential bugs due to numeric wrapping.

- asprecision is now a sum type with Word8 instead of an Int with
  magic values.

- DigitGroupStyle uses Word8 instead of Int.

- exponents are parsed as Integer rather than Int.

Merge branch 'precisionword' into master
2020-08-30 12:51:24 -07:00
Stephen Morgan
7182fa4746 lib: Improve documentation for amountRoundedQuantity, fix a typo. 2020-08-30 23:01:04 +10:00
Stephen Morgan
f6fa76bba7 lib,cli: Get rid of magic values for asprecision, use a sum type instead. 2020-08-30 23:00:35 +10:00
Stephen Morgan
ee1ef9606b lib: Fail when parsing number with more than 255 decimal places. 2020-08-30 22:30:24 +10:00
Stephen Morgan
ba59fed6b2 lib: Replace more instances of fromIntegral with safer versions. 2020-08-30 22:20:58 +10:00
Stephen Morgan
ca2e55c954 lib: Replace some fromIntegral with toInteger. 2020-08-30 22:20:58 +10:00