From 6589b506ed29faeb964376c486cb6b2645ae0fa9 Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Sun, 29 Jan 2023 08:14:15 -1000 Subject: [PATCH] ;bin: register-max: tweaks --- bin/hledger-register-max.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/hledger-register-max.hs b/bin/hledger-register-max.hs index 7b4d56c6c..7a4ecbe47 100755 --- a/bin/hledger-register-max.hs +++ b/bin/hledger-register-max.hs @@ -5,7 +5,7 @@ -- Usage: -- hledger-register-max [REGISTERARGS] -- hledger register-max -- [REGISTERARGS] --- For historical balances, add -H. For negative balances, add --invert. For value, add -V --infer-market-prices, etc. +-- For historical balances, add -H. To see the smallest, add --invert. For value, add -V --infer-market-prices, etc. -- Examples: -- $ hledger-register-max -f examples/bcexample.hledger -H checking @@ -46,10 +46,10 @@ printItem (_, _, _, p, bal) = do d = postingDate p mt = ptransaction p desc = fmt 30 $ maybe "-" tdescription mt - acct = fmt 40 $ paccount p + acct = fmt 30 $ paccount p amt = fmta 12 $ T.pack $ showMixedAmountOneLine $ pamount p baltxt = fmta 12 $ T.pack $ showMixedAmountOneLine bal T.putStrLn $ T.unwords [showDate d, desc, "", acct, "", amt, " ", baltxt] where - fmt w = formatText True (Just w) (Just w) . textElideRight (w-2) + fmt w = formatText True (Just w) (Just w) . textElideRight w fmta w = formatText False (Just w) Nothing