hledger-ui 1.51.2 → 1.52
raw patch · 11 files changed
+519/−467 lines, 11 filesdep ~hledgerdep ~hledger-libPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: hledger, hledger-lib
API changes (from Hackage documentation)
Files
- CHANGES.md +37/−0
- Hledger/UI/AccountsScreen.hs +14/−2
- Hledger/UI/Main.hs +0/−2
- Hledger/UI/RegisterScreen.hs +10/−1
- Hledger/UI/Theme.hs +15/−15
- Hledger/UI/UIOptions.hs +2/−1
- Hledger/UI/UIScreens.hs +11/−3
- hledger-ui.1 +70/−70
- hledger-ui.cabal +7/−7
- hledger-ui.info +23/−23
- hledger-ui.txt +330/−343
CHANGES.md view
@@ -23,6 +23,37 @@ See also the hledger changelog. +# 1.52 2026-03-20++Fixes++- List screens with no items now correctly appear empty on all platforms.+ (An unguarded division by zero was disrupting the display on non-ARM machines.)+ (Tuong Nguyen Manh, Simon Michael) [#2476], [#2550]++- The less pager (used for displaying help, eg) is now invoked more robustly; we catch and report more kinds of failure clearly.+ [#2544]++Improvements++- New capital `J`/`K` keybindings move down/up 10 rows at a time.+ (Rahul Shankar V, Simon Michael) [#1911], [#2551]++- The `default` theme has been renamed to `light`.+ (Rahul Shankar V, Simon Michael) [#2168], [#2551]++- The selection colour has been changed to cyan, for better visibility in typical terminals.+ (Rahul Shankar V, Simon Michael) [#2175], [#2551]++[#1911]: https://github.com/simonmichael/hledger/issues/1911+[#2168]: https://github.com/simonmichael/hledger/issues/2168+[#2175]: https://github.com/simonmichael/hledger/issues/2175+[#2476]: https://github.com/simonmichael/hledger/issues/2476+[#2544]: https://github.com/simonmichael/hledger/issues/2544+[#2550]: https://github.com/simonmichael/hledger/issues/2550+[#2551]: https://github.com/simonmichael/hledger/issues/2551++ # 1.51.2 2026-01-08 - hledger add invoked via the `a` key now shows output properly,@@ -34,6 +65,7 @@ [#2512]: https://github.com/simonmichael/hledger/issues/2512 + # 1.51.1 2025-12-08 - Uses hledger 1.51.1.@@ -46,6 +78,11 @@ - Allow brick 2.10, vty 6.5. - Uses hledger 1.51.+++# 1.50.5 2025-12-08++- Uses hledger 1.50.5. # 1.50.4 2025-12-04
Hledger/UI/AccountsScreen.hs view
@@ -93,7 +93,7 @@ totalwidthseen = totalacctwidthseen + totalbalwidthseen shortfall = preferredacctwidth + preferredbalwidth + 2 - availwidth- acctwidthproportion = fromIntegral totalacctwidthseen / fromIntegral totalwidthseen+ acctwidthproportion = fromIntegral totalacctwidthseen `divideSafe` fromIntegral totalwidthseen adjustedacctwidth = min preferredacctwidth . max 15 . round $ acctwidthproportion * fromIntegral (availwidth - 2) -- leave 2 whitespace for padding adjustedbalwidth = availwidth - 2 - adjustedacctwidth @@ -225,7 +225,7 @@ VtyEvent (EvKey (KChar 'l') [MCtrl]) -> centerSelection >> redraw -- C-l: redraw VtyEvent (EvKey KEsc []) -> modify' (resetScreens d) -- ESC: reset VtyEvent (EvKey (KChar c) []) | c == '?' -> modify' (setMode Help) -- ?: enter help mode-+ -- AppEvents come from the system, in --watch mode. -- XXX currently they are handled only in Normal mode -- XXX be sure we don't leave unconsumed app events piling up@@ -248,6 +248,18 @@ VtyEvent (EvKey (KChar 'a') []) -> suspendAndResume $ clearScreen >> setCursorPosition 0 0 >> add (cliOptsDropArgs copts) j >> uiReloadIfFileChanged copts d j ui VtyEvent (EvKey (KChar 'A') []) -> suspendAndResume $ void (runIadd (journalFilePath j)) >> uiReloadIfFileChanged copts d j ui VtyEvent (EvKey (KChar 'E') []) -> suspendAndResume $ void (runEditor endPosition (journalFilePath j)) >> uiReloadIfFileChanged copts d j ui+ -- J/K Jumps: move 10 rows at a time+ VtyEvent (EvKey (KChar 'J') []) -> do+ let l' = listMoveBy 10 l+ -- Ensure we don't jump into the blank padding at the end+ let l'' = if isBlankItem (listSelectedElement l')+ then listMoveTo lastnonblankidx l'+ else l'+ put' ui{aScreen=scons ass{_assList=l''}}++ VtyEvent (EvKey (KChar 'K') []) -> do+ let l' = listMoveBy (-10) l+ put' ui{aScreen=scons ass{_assList=l'}} -- adjust the period displayed: VtyEvent (EvKey (KChar 'T') []) -> modify' (setReportPeriod (DayPeriod d) >>> regenerateScreens j d)
Hledger/UI/Main.hs view
@@ -100,8 +100,6 @@ -- when (debug_ $ cliopts_ opts) $ printf "%s\n" prognameandversion >> printf "opts: %s\n" (show opts) usecolor <- useColorOnStdout- -- When ANSI colour/styling is available and enabled, encourage user's $PAGER to use it (for command line help).- when usecolor setupPager -- And when it's not, disable colour in the TUI ? -- Theme.hs's themes currently hard code various colours and styles provided by vty, -- which probably are disabled automatically when terminal doesn't support them.
Hledger/UI/RegisterScreen.hs view
@@ -73,7 +73,7 @@ maxamtswidth = max 0 (totalwidth - minnonamtcolswidth - whitespacewidth) maxchangewidthseen = maximum' $ map (wbWidth . rsItemChangeAmount) displayitems maxbalwidthseen = maximum' $ map (wbWidth . rsItemBalanceAmount) displayitems- changewidthproportion = fromIntegral maxchangewidthseen / fromIntegral (maxchangewidthseen + maxbalwidthseen)+ changewidthproportion = fromIntegral maxchangewidthseen `divideSafe` fromIntegral (maxchangewidthseen + maxbalwidthseen) maxchangewidth = round $ changewidthproportion * fromIntegral maxamtswidth maxbalwidth = maxamtswidth - maxchangewidth changewidth = min maxchangewidth maxchangewidthseen@@ -269,7 +269,16 @@ VtyEvent (EvKey (KChar 'P') []) -> rsCenterSelection (regenerateScreens j d $ togglePending ui) >>= put' VtyEvent (EvKey (KChar 'C') []) -> rsCenterSelection (regenerateScreens j d $ toggleCleared ui) >>= put' VtyEvent (EvKey (KChar 'F') []) -> rsCenterSelection (regenerateScreens j d $ toggleForecast d ui) >>= put'+ VtyEvent (EvKey (KChar 'J') []) -> do+ let l' = listMoveBy 10 _rssList+ let l'' = if isBlankElement (listSelectedElement l')+ then listMoveTo lastnonblankidx l'+ else l'+ put' ui{aScreen=RS sst{_rssList=l''}} + VtyEvent (EvKey (KChar 'K') []) -> do+ let l' = listMoveBy (-10) _rssList+ put' ui{aScreen=RS sst{_rssList=l'}} VtyEvent (EvKey (KChar '/') []) -> put' $ regenerateScreens j d $ showMinibuffer "filter" Nothing ui VtyEvent (EvKey (KDown) [MShift]) -> put' $ regenerateScreens j d $ shrinkReportPeriod d ui VtyEvent (EvKey (KUp) [MShift]) -> put' $ regenerateScreens j d $ growReportPeriod d ui
Hledger/UI/Theme.hs view
@@ -24,7 +24,7 @@ import Safe (headErr) defaultTheme :: AttrMap-defaultTheme = fromMaybe (snd $ headErr themesList) $ getTheme "white" -- PARTIAL headErr succeeds because themesList is non-null+defaultTheme = fromMaybe (snd $ headErr themesList) $ getTheme "light" -- PARTIAL headErr succeeds because themesList is non-null -- the theme named here should exist; -- otherwise it will take the first one from the list, -- which must be non-empty.@@ -60,12 +60,12 @@ (&) = withStyle active = fg brightWhite & bold-selectbg = yellow+selectbg = cyan select = black `on` selectbg themesList :: [(String, AttrMap)] themesList = [- ("default", attrMap (black `on` white) [+ ("light", attrMap (black `on` white) [ (attrName "border" , white `on` black & dim) ,(attrName "border" <> attrName "bold" , currentAttr & bold) ,(attrName "border" <> attrName "depth" , active)@@ -94,16 +94,6 @@ -- ,(attrName "list" <> attrName "selected" , black `on` brightYellow) ]) - ,("greenterm", attrMap (green `on` black) [- (attrName "list" <> attrName "selected" , black `on` green)- ])-- ,("terminal", attrMap defAttr [- (attrName "border" , white `on` black),- (attrName "list" , defAttr),- (attrName "list" <> attrName "selected" , defAttr & reverseVideo)- ])- ,("dark", attrMap (white `on` black & dim) [ (attrName "border" , white `on` black) , (attrName "border" <> attrName "bold" , currentAttr & bold)@@ -123,8 +113,18 @@ , (attrName "list" <> attrName "balance" <> attrName "negative" , fg red) , (attrName "list" <> attrName "balance" <> attrName "positive" , fg white) , (attrName "list" <> attrName "balance" <> attrName "negative" <> attrName "selected" , red `on` black & bold)- , (attrName "list" <> attrName "balance" <> attrName "positive" <> attrName "selected" , yellow `on` black & bold)- , (attrName "list" <> attrName "selected" , yellow `on` black & bold)+ , (attrName "list" <> attrName "balance" <> attrName "positive" <> attrName "selected" , cyan `on` black & bold)+ , (attrName "list" <> attrName "selected" , cyan `on` black & bold)+ ])++ ,("terminal", attrMap defAttr [+ (attrName "border" , white `on` black),+ (attrName "list" , defAttr),+ (attrName "list" <> attrName "selected" , defAttr & reverseVideo)+ ])++ ,("greenterm", attrMap (green `on` black) [+ (attrName "list" <> attrName "selected" , black `on` green) ]) ]
Hledger/UI/UIOptions.hs view
@@ -116,7 +116,8 @@ where -- show historical balance by default (unlike hledger) accum = fromMaybe Historical $ balanceAccumulationOverride rawopts- checkTheme t = if t `M.member` themes then t else usageError $ "invalid theme name: " ++ t+ checkTheme t = let t' = if t == "default" then "light" else t -- "default" is a deprecated alias for "light"+ in if t' `M.member` themes then t' else usageError $ "invalid theme name: " ++ t -- XXX some refactoring seems due getHledgerUIOpts :: IO UIOpts
Hledger/UI/UIScreens.hs view
@@ -39,11 +39,12 @@ ) where -import Brick.Widgets.List (listMoveTo, listSelectedElement, list)+import Brick.Widgets.List (listMoveTo, listSelectedElement, list, listSelectedL, GenericList) import Data.List import Data.Maybe import Data.Text qualified as T import Data.Time.Calendar (Day, diffDays)+import Lens.Micro (over) import Safe import Data.Vector qualified as V @@ -145,7 +146,7 @@ & reportSpecSetFutureAndForecast (forecast_ $ inputopts_ copts) -- include/exclude future & forecast transactions & reportSpecAddQuery extraquery -- add any extra restrictions - l = listMoveTo selidx $ list AccountsList (V.fromList $ displayitems ++ blankitems) 1+ l = listMoveToIfDisplayItems selidx displayitems $ list AccountsList (V.fromList $ displayitems ++ blankitems) 1 where -- which account should be selected ? selidx = headDef 0 $ catMaybes [@@ -316,7 +317,7 @@ -- otherwise, the transaction nearest in date to it; -- or if there's several with the same date, the nearest in journal order; -- otherwise, the last (latest) transaction.- l' = listMoveTo newselidx l+ l' = listMoveToIfDisplayItems newselidx displayitems l where endidx = max 0 $ length displayitems - 1 newselidx =@@ -364,3 +365,10 @@ tsUpdate :: TransactionScreenState -> TransactionScreenState tsUpdate = dbgui "tsUpdate" +-- | Set selected index of a list if there are displayitems.+-- If there are no displayitems, remove the selected index of the list.+listMoveToIfDisplayItems :: Int -> [item] -> GenericList Name V.Vector item -> GenericList Name V.Vector item+listMoveToIfDisplayItems idx displayItems =+ if null displayItems+ then over listSelectedL $ const Nothing+ else listMoveTo idx
hledger-ui.1 view
@@ -1,5 +1,5 @@ -.TH "HLEDGER\-UI" "1" "December 2025" "hledger-ui-1.51.2 " "hledger User Manuals"+.TH "HLEDGER\-UI" "1" "March 2026" "hledger-ui-1.52 " "hledger User Manuals" @@ -17,7 +17,7 @@ .PD \f[CR]hledger ui [OPTS] [QUERYARGS]\f[R] .SH DESCRIPTION-This manual is for hledger\[aq]s terminal interface, version 1.51.2.+This manual is for hledger\(aqs terminal interface, version 1.52. See also the hledger manual for common concepts and file formats. .PP hledger is a robust, user\-friendly, cross\-platform set of programs for@@ -26,10 +26,10 @@ hledger is inspired by and largely compatible with ledger(1), and largely interconvertible with beancount(1). .PP-hledger\-ui is hledger\[aq]s terminal interface, providing an efficient+hledger\-ui is hledger\(aqs terminal interface, providing an efficient full\-window text UI for viewing accounts and transactions, and some limited data entry capability.-It is easier than hledger\[aq]s command\-line interface, and sometimes+It is easier than hledger\(aqs command\-line interface, and sometimes quicker and more convenient than the web interface. .PP Like hledger, it reads from (and appends to) a journal file specified by@@ -44,7 +44,7 @@ default. They can be revealed, along with any rule\-generated periodic transactions, by pressing the F key (or starting with \-\-forecast) to-enable \[dq]forecast mode\[dq].+enable \(dqforecast mode\(dq. .SH OPTIONS Any arguments are interpreted as a hledger query which filters the data. hledger\-ui provides the following options:@@ -53,20 +53,20 @@ Flags: \-w \-\-watch watch for data and date changes and reload automatically- \-\-theme=THEME use this custom display theme (default,- greenterm, terminal, dark)+ \-\-theme=THEME use this custom display theme (light,+ dark, terminal, greenterm) \-\-cash start in the cash accounts screen \-\-bs start in the balance sheet accounts screen \-\-is start in the income statement accounts screen \-\-all start in the all accounts screen- \-\-register=ACCTREGEX start in the (first matched) account\[aq]s register+ \-\-register=ACCTREGEX start in the (first matched) account\(aqs register \-\-change show period balances (changes) at startup instead of historical balances \-l \-\-flat show accounts as a flat list (default) \-t \-\-tree show accounts as a tree .EE .PP-and also supports many of hledger\[aq]s general options:+and also supports many of hledger\(aqs general options: .IP .EX General input/data transformation flags:@@ -80,18 +80,18 @@ \-\-alias=A=B|/RGX/=RPL transform account names from A to B, or by replacing regular expression matches \-\-auto generate extra postings by applying auto posting- rules (\[dq]=\[dq]) to all transactions+ rules (\(dq=\(dq) to all transactions \-\-forecast[=PERIOD] Generate extra transactions from periodic rules- (\[dq]\[ti]\[dq]), from after the latest ordinary transaction+ (\(dq\(ti\(dq), from after the latest ordinary transaction until 6 months from now. Or, during the specified PERIOD (the equals is required). Auto posting rules will also be applied to these transactions. In hledger\-ui, also make future\-dated transactions visible at startup.- \-I \-\-ignore\-assertions don\[aq]t check balance assertions by default+ \-I \-\-ignore\-assertions don\(aqt check balance assertions by default \-\-txn\-balancing=... how to check that transactions are balanced:- \[aq]old\[aq]: use global display precision- \[aq]exact\[aq]: use transaction precision (default)+ \(aqold\(aq: use global display precision+ \(aqexact\(aq: use transaction precision (default) \-\-infer\-costs infer conversion equity postings from costs \-\-infer\-equity infer costs from conversion equity postings \-\-infer\-market\-prices infer market prices from costs@@ -111,7 +111,7 @@ \-Y \-\-yearly multiperiod report with 1 year interval \-p \-\-period=PERIODEXP set begin date, end date, and/or report interval, with more flexibility- \-\-today=DATE override today\[aq]s date (affects relative dates)+ \-\-today=DATE override today\(aqs date (affects relative dates) \-\-date2 match/use secondary dates instead (deprecated) \-U \-\-unmarked include only unmarked postings/transactions \-P \-\-pending include only pending postings/transactions@@ -133,14 +133,14 @@ \-\-value=WHEN[,COMM] show amounts converted to their value on the specified date(s) in their default valuation commodity or a specified commodity. WHEN can be:- \[aq]then\[aq]: value on transaction dates- \[aq]end\[aq]: value at period end(s)- \[aq]now\[aq]: value today+ \(aqthen\(aq: value on transaction dates+ \(aqend\(aq: value at period end(s)+ \(aqnow\(aq: value today YYYY\-MM\-DD: value on given date- \-c \-\-commodity\-style=S Override a commodity\[aq]s display style.- Eg: \-c \[aq].\[aq] or \-c \[aq]1.000,00 EUR\[aq]+ \-c \-\-commodity\-style=S Override a commodity\(aqs display style.+ Eg: \-c \(aq.\(aq or \-c \(aq1.000,00 EUR\(aq \-\-pretty[=YN] Use box\-drawing characters in text output? Can be- \[aq]y\[aq]/\[aq]yes\[aq] or \[aq]n\[aq]/\[aq]no\[aq].+ \(aqy\(aq/\(aqyes\(aq or \(aqn\(aq/\(aqno\(aq. If YN is specified, the equals is required. General help flags:@@ -163,11 +163,11 @@ .SH MOUSE In most modern terminals, you can navigate through the screens with a mouse or touchpad:-.IP \[bu] 2+.IP \(bu 2 Use mouse wheel or trackpad to scroll up and down-.IP \[bu] 2+.IP \(bu 2 Click on list items to go deeper-.IP \[bu] 2+.IP \(bu 2 Click on the left margin (column 0) to go back. .SH KEYS Keyboard gives more control.@@ -183,6 +183,7 @@ deeper, \f[CR]LEFT\f[R] returns to the previous screen, \f[CR]UP\f[R]/\f[CR]DOWN\f[R]/\f[CR]PGUP\f[R]/\f[CR]PGDN\f[R]/\f[CR]HOME\f[R]/\f[CR]END\f[R] move up and down through lists.+\f[CR]J\f[R]/\f[CR]K\f[R] jump down/up 10 items at a time. Emacs\-style (\f[CR]CTRL\-p\f[R]/\f[CR]CTRL\-n\f[R]/\f[CR]CTRL\-f\f[R]/\f[CR]CTRL\-b\f[R]) and VI\-style (\f[CR]k\f[R],\f[CR]j\f[R],\f[CR]l\f[R],\f[CR]h\f[R])@@ -212,7 +213,7 @@ When narrowed, the current report period is displayed in the header line, pressing \f[CR]SHIFT\-LEFT\f[R] or \f[CR]SHIFT\-RIGHT\f[R] moves to the previous or next period, and pressing \f[CR]T\f[R] sets the-period to \[dq]today\[dq].+period to \(dqtoday\(dq. If you are using \f[CR]\-w/\-\-watch\f[R] and viewing a narrowed period containing today, the view will follow any changes in system date (moving to the period containing the new date).@@ -226,22 +227,22 @@ .PP (Tip: arrow keys with Shift do not work out of the box in all terminal software.-Eg in Apple\[aq]s Terminal, the SHIFT\-DOWN and SHIFT\-UP keys must be-configured as follows: in Terminal\[aq]s preferences, click Profiles,+Eg in Apple\(aqs Terminal, the SHIFT\-DOWN and SHIFT\-UP keys must be+configured as follows: in Terminal\(aqs preferences, click Profiles, select your current profile on the left, click Keyboard on the right,-click + and add this for SHIFT\-DOWN: \f[CR]\[rs]033[1;2B\f[R], click +-and add this for SHIFT\-UP: \f[CR]\[rs]033[1;2A\f[R].+click + and add this for SHIFT\-DOWN: \f[CR]\(rs033[1;2B\f[R], click ++and add this for SHIFT\-UP: \f[CR]\(rs033[1;2A\f[R]. \ In other terminals (Windows Terminal ?) you might need to configure SHIFT\-RIGHT and SHIFT\-LEFT to emit-\f[CR]\[rs]033[1;2C\f[R] and \f[CR]\[rs]033[1;2D\f[R] respectively.)+\f[CR]\(rs033[1;2C\f[R] and \f[CR]\(rs033[1;2D\f[R] respectively.) .PP \f[CR]ESCAPE\f[R] resets the UI state and jumps back to the top screen,-restoring the app\[aq]s initial state at startup.+restoring the app\(aqs initial state at startup. Or, it cancels minibuffer data entry or the help dialog. .PP \f[CR]CTRL\-l\f[R] redraws the screen and centers the selection if-possible (selections near the top won\[aq]t be centered, since we-don\[aq]t scroll above the top).+possible (selections near the top won\(aqt be centered, since we+don\(aqt scroll above the top). .PP \f[CR]g\f[R] reloads from the data file(s) and updates the current screen and any previous screens.@@ -254,7 +255,7 @@ re\-enabling balance assertions with the \f[CR]I\f[R] key also reloads the journal, like \f[CR]g\f[R].) .PP-\f[CR]a\f[R] runs command\-line hledger\[aq]s add command, and reloads+\f[CR]a\f[R] runs command\-line hledger\(aqs add command, and reloads the updated file. This allows some basic data entry. .PP@@ -264,14 +265,14 @@ $path. .PP \f[CR]E\f[R] runs $HLEDGER_UI_EDITOR, or $EDITOR, or a default-(\f[CR]emacsclient \-a \[dq]\[dq] \-nw\f[R]) on the journal file.+(\f[CR]emacsclient \-a \(dq\(dq \-nw\f[R]) on the journal file. With some editors (emacs, vi), the cursor will be positioned at the current transaction when invoked from the register and transaction screens, and at the error location (if possible) when invoked from the error screen. .PP \f[CR]B\f[R] toggles cost mode, showing amounts converted to their-cost\[aq]s commodity (see hledger manual > Cost reporting.+cost\(aqs commodity (see hledger manual > Cost reporting. .PP \f[CR]V\f[R] toggles value mode, showing amounts converted to their market value (see hledger manual > Valuation flag).@@ -291,7 +292,7 @@ like \f[CR]date:..YYYY\-MM\-DD\f[R]. \- Either cost mode, or value mode, can be active, but not both at once. Cost mode takes precedence.-\- There\[aq]s not yet any visual indicator that cost or value mode is+\- There\(aqs not yet any visual indicator that cost or value mode is active, other than the amount values. .PP \f[CR]q\f[R] quits the application.@@ -314,7 +315,7 @@ Note some of these may not show anything until you have configured account types. .SS Cash accounts screen-This screen shows \[dq]cash\[dq] (ie, liquid asset) accounts (like+This screen shows \(dqcash\(dq (ie, liquid asset) accounts (like \f[CR]hledger balancesheet type:c\f[R]). It always shows balances (historical ending balances on the date shown in the title line).@@ -335,38 +336,38 @@ .SS Register screen This screen shows the transactions affecting a particular account. Each line represents one transaction, and shows:-.IP \[bu] 2+.IP \(bu 2 the other account(s) involved, in abbreviated form. (If there are both real and virtual postings, it shows only the accounts affected by real postings.)-.IP \[bu] 2-the overall change to the current account\[aq]s balance; positive for an+.IP \(bu 2+the overall change to the current account\(aqs balance; positive for an inflow to this account, negative for an outflow.-.IP \[bu] 2+.IP \(bu 2 the running total after the transaction. With the \f[CR]H\f[R] key you can toggle between .RS 2-.IP \[bu] 2+.IP \(bu 2 the period total, which is from just the transactions displayed-.IP \[bu] 2+.IP \(bu 2 or the historical total, which includes any undisplayed transactions before the start of the report period (and matching the filter query if any). This will be the running historical balance (what you would see on a-bank\[aq]s website, eg) if not disturbed by a query.+bank\(aqs website, eg) if not disturbed by a query. .RE .PP-Note, this screen combines each transaction\[aq]s in\-period postings to+Note, this screen combines each transaction\(aqs in\-period postings to a single line item, dated with the earliest in\-period transaction or-posting date (like hledger\[aq]s \f[CR]aregister\f[R]).+posting date (like hledger\(aqs \f[CR]aregister\f[R]). So custom posting dates can cause the running balance to be temporarily inaccurate. (See hledger manual > aregister and posting dates.) .PP-Transactions affecting this account\[aq]s subaccounts will be included-in the register if the accounts screen is in tree mode, or if it\[aq]s-in list mode but this account has subaccounts which are not shown due to-a depth limit.+Transactions affecting this account\(aqs subaccounts will be included in+the register if the accounts screen is in tree mode, or if it\(aqs in+list mode but this account has subaccounts which are not shown due to a+depth limit. In other words, the register always shows the transactions contributing to the balance shown on the accounts screen. Tree mode/list mode can be toggled with \f[CR]t\f[R] here also.@@ -388,10 +389,10 @@ Press \f[CR]RIGHT\f[R] to view the selected transaction in detail. .SS Transaction screen This screen shows a single transaction, as a general journal entry,-similar to hledger\[aq]s print command and journal format+similar to hledger\(aqs print command and journal format (hledger_journal(5)). .PP-The transaction\[aq]s date(s) and any cleared flag, transaction code,+The transaction\(aqs date(s) and any cleared flag, transaction code, description, comments, along with all of its account postings are shown. Simple transactions have two postings, but there can be more (or in certain cases, fewer).@@ -402,9 +403,9 @@ that account register. They will vary depending on which account register you came from (remember most transactions appear in multiple account registers).-The #N number preceding them is the transaction\[aq]s position within-the complete unfiltered journal, which is a more stable id (at least-until the next reload).+The #N number preceding them is the transaction\(aqs position within the+complete unfiltered journal, which is a more stable id (at least until+the next reload). .PP On this screen (and the register screen), the \f[CR]E\f[R] key will open your text editor with the cursor positioned at the current transaction@@ -416,13 +417,13 @@ normal operation. (Or, you can press escape to cancel the reload attempt.) .SH WATCH MODE-One of hledger\-ui\[aq]s best features is the auto\-reloading+One of hledger\-ui\(aqs best features is the auto\-reloading \f[CR]\-w/\-\-watch\f[R] mode. With this flag, it will update the display automatically whenever changes are saved to the data files. .PP This is very useful when reconciling.-A good workflow is to have your bank\[aq]s online register open in a+A good workflow is to have your bank\(aqs online register open in a browser window, for reference; the journal file open in an editor window; and hledger\-ui in watch mode in a terminal window, eg: .IP@@ -438,18 +439,18 @@ .SS \-\-watch problems \f[I]However.\f[R] There are limitations/unresolved bugs with \f[CR]\-\-watch\f[R]:-.IP \[bu] 2+.IP \(bu 2 It may not work at all for you, depending on platform or system configuration. On some unix systems, increasing fs.inotify.max_user_watches or fs.file\-max parameters in /etc/sysctl.conf might help. (#836)-.IP \[bu] 2+.IP \(bu 2 It may not detect changes made from outside a virtual machine, ie by an editor running on the host system.-.IP \[bu] 2+.IP \(bu 2 It may not detect file changes on certain less common filesystems.-.IP \[bu] 2+.IP \(bu 2 It may use increasing CPU and RAM over time, especially with large files. (This is probably not \-\-watch specific, you may be able to reproduce@@ -457,16 +458,16 @@ (#1825) .PP Tips/workarounds:-.IP \[bu] 2-If \-\-watch won\[aq]t work for you, press \f[CR]g\f[R] to reload data+.IP \(bu 2+If \-\-watch won\(aqt work for you, press \f[CR]g\f[R] to reload data manually instead.-.IP \[bu] 2+.IP \(bu 2 If \-\-watch is leaking resources over time, quit and restart (or-suspend and resume) hledger\-ui when you\[aq]re not using it.-.IP \[bu] 2+suspend and resume) hledger\-ui when you\(aqre not using it.+.IP \(bu 2 When running hledger\-ui inside a VM, also make file changes inside the VM.-.IP \[bu] 2+.IP \(bu 2 When working with files mounted from another machine, make sure the system clocks on both machines are roughly in agreement. .SH ENVIRONMENT@@ -480,8 +481,7 @@ .PP Some known issues: .PP-\f[CR]\-f\-\f[R] doesn\[aq]t work (hledger\-ui can\[aq]t read from-stdin).+\f[CR]\-f\-\f[R] doesn\(aqt work (hledger\-ui can\(aqt read from stdin). .PP \f[CR]\-\-watch\f[R] is not robust, especially with large files (see WATCH MODE above).
hledger-ui.cabal view
@@ -1,11 +1,11 @@ cabal-version: 2.2 --- This file has been generated from package.yaml by hpack version 0.38.1.+-- This file has been generated from package.yaml by hpack version 0.39.1. -- -- see: https://github.com/sol/hpack name: hledger-ui-version: 1.51.2+version: 1.52 synopsis: Terminal interface for the hledger accounting system description: A simple terminal user interface for the hledger accounting system. It can be a more convenient way to browse your accounts than the CLI.@@ -69,7 +69,7 @@ hs-source-dirs: ./ ghc-options: -Wall -Wno-incomplete-uni-patterns -Wno-missing-signatures -Wno-orphans -Wno-type-defaults -Wno-unused-do-bind- cpp-options: -DVERSION="1.51.2"+ cpp-options: -DVERSION="1.52" build-depends: ansi-terminal >=0.9 , async@@ -84,8 +84,8 @@ , filepath , fsnotify >=0.4.2.0 && <0.5 , githash >=0.1.6.2- , hledger >=1.51.2 && <1.52- , hledger-lib >=1.51.2 && <1.52+ , hledger ==1.52.*+ , hledger-lib ==1.52.* , megaparsec >=7.0.0 && <9.8 , microlens >=0.4 , microlens-platform >=0.2.3.1@@ -100,7 +100,7 @@ , transformers , vector , vty >=6.1 && <6.6- , vty-crossplatform >=0.4.0.0 && <0.6.0.0+ , vty-crossplatform >=0.4.0.0 && <0.5.0.0 default-language: GHC2021 if (flag(debug)) cpp-options: -DDEBUG@@ -120,7 +120,7 @@ hs-source-dirs: app ghc-options: -Wall -Wno-incomplete-uni-patterns -Wno-missing-signatures -Wno-orphans -Wno-type-defaults -Wno-unused-do-bind -threaded- cpp-options: -DVERSION="1.51.2"+ cpp-options: -DVERSION="1.52" build-depends: base >=4.18 && <4.23 , hledger-ui
hledger-ui.info view
@@ -1,4 +1,4 @@-This is hledger-ui.info, produced by makeinfo version 7.2 from stdin.+This is hledger-ui.info, produced by makeinfo version 7.3 from stdin. INFO-DIR-SECTION User Applications START-INFO-DIR-ENTRY@@ -18,7 +18,7 @@ or 'hledger ui [OPTS] [QUERYARGS]' - This manual is for hledger's terminal interface, version 1.51.2. See+ This manual is for hledger's terminal interface, version 1.52. See also the hledger manual for common concepts and file formats. hledger is a robust, user-friendly, cross-platform set of programs@@ -66,8 +66,8 @@ Flags: -w --watch watch for data and date changes and reload automatically- --theme=THEME use this custom display theme (default,- greenterm, terminal, dark)+ --theme=THEME use this custom display theme (light,+ dark, terminal, greenterm) --cash start in the cash accounts screen --bs start in the balance sheet accounts screen --is start in the income statement accounts screen@@ -199,9 +199,9 @@ The cursor keys navigate: 'RIGHT' or 'ENTER' goes deeper, 'LEFT' returns to the previous screen, 'UP'/'DOWN'/'PGUP'/'PGDN'/'HOME'/'END'-move up and down through lists. Emacs-style-('CTRL-p'/'CTRL-n'/'CTRL-f'/'CTRL-b') and VI-style ('k','j','l','h')-movement keys are also supported.+move up and down through lists. 'J'/'K' jump down/up 10 items at a+time. Emacs-style ('CTRL-p'/'CTRL-n'/'CTRL-f'/'CTRL-b') and VI-style+('k','j','l','h') movement keys are also supported. (Tip: movement speed is limited by your keyboard repeat rate, to move faster you may want to adjust it. On a mac, the Karabiner app is one@@ -555,22 +555,22 @@ Tag Table: Node: Top221-Node: OPTIONS1869-Node: MOUSE8755-Node: KEYS9087-Node: SCREENS14229-Node: Menu screen14969-Node: Cash accounts screen15285-Node: Balance sheet accounts screen15646-Node: Income statement accounts screen15982-Node: All accounts screen16367-Node: Register screen16730-Node: Transaction screen19173-Node: Error screen20353-Node: WATCH MODE20719-Node: --watch problems21617-Node: ENVIRONMENT22864-Node: BUGS23097+Node: OPTIONS1867+Node: MOUSE8751+Node: KEYS9083+Node: SCREENS14267+Node: Menu screen15007+Node: Cash accounts screen15323+Node: Balance sheet accounts screen15684+Node: Income statement accounts screen16020+Node: All accounts screen16405+Node: Register screen16768+Node: Transaction screen19211+Node: Error screen20391+Node: WATCH MODE20757+Node: --watch problems21655+Node: ENVIRONMENT22902+Node: BUGS23135 End Tag Table
hledger-ui.txt view
@@ -1,463 +1,450 @@ -HLEDGER-UI(1) hledger User Manuals HLEDGER-UI(1)+HLEDGER-UI(1) hledger User Manuals HLEDGER-UI(1) NAME- hledger-ui - terminal interface (TUI) for hledger, a robust, friendly- plain text accounting app.+ hledger-ui - terminal interface (TUI) for hledger, a robust, friendly plain+ text accounting app. SYNOPSIS- hledger-ui [OPTS] [QUERYARGS]- or- hledger ui [OPTS] [QUERYARGS]+ hledger-ui [OPTS] [QUERYARGS]+ or+ hledger ui [OPTS] [QUERYARGS] DESCRIPTION- This manual is for hledger's terminal interface, version 1.51.2. See- also the hledger manual for common concepts and file formats.+ This manual is for hledger's terminal interface, version 1.52. See also+ the hledger manual for common concepts and file formats. - hledger is a robust, user-friendly, cross-platform set of programs for- tracking money, time, or any other commodity, using double-entry ac-- counting and a simple, editable file format. hledger is inspired by- and largely compatible with ledger(1), and largely interconvertible- with beancount(1).+ hledger is a robust, user-friendly, cross-platform set of programs for+ tracking money, time, or any other commodity, using double-entry accounting+ and a simple, editable file format. hledger is inspired by and largely+ compatible with ledger(1), and largely interconvertible with beancount(1). - hledger-ui is hledger's terminal interface, providing an efficient- full-window text UI for viewing accounts and transactions, and some- limited data entry capability. It is easier than hledger's com-- mand-line interface, and sometimes quicker and more convenient than the- web interface.+ hledger-ui is hledger's terminal interface, providing an efficient+ full-window text UI for viewing accounts and transactions, and some limited+ data entry capability. It is easier than hledger's command-line interface,+ and sometimes quicker and more convenient than the web interface. - Like hledger, it reads from (and appends to) a journal file specified- by the LEDGER_FILE environment variable (defaulting to- $HOME/.hledger.journal); or you can specify files with -f options. It- can also read timeclock files, timedot files, or any CSV/SSV/TSV file- with a date field. (See hledger(1) -> Input for details.)+ Like hledger, it reads from (and appends to) a journal file specified by+ the LEDGER_FILE environment variable (defaulting to $HOME/.hledger.jour-+ nal); or you can specify files with -f options. It can also read timeclock+ files, timedot files, or any CSV/SSV/TSV file with a date field. (See+ hledger(1) -> Input for details.) - Unlike hledger, hledger-ui hides all future-dated transactions by de-- fault. They can be revealed, along with any rule-generated periodic- transactions, by pressing the F key (or starting with --forecast) to- enable "forecast mode".+ Unlike hledger, hledger-ui hides all future-dated transactions by default.+ They can be revealed, along with any rule-generated periodic transactions,+ by pressing the F key (or starting with --forecast) to enable "forecast+ mode". OPTIONS- Any arguments are interpreted as a hledger query which filters the- data. hledger-ui provides the following options:+ Any arguments are interpreted as a hledger query which filters the data.+ hledger-ui provides the following options: - Flags:- -w --watch watch for data and date changes and reload- automatically- --theme=THEME use this custom display theme (default,- greenterm, terminal, dark)- --cash start in the cash accounts screen- --bs start in the balance sheet accounts screen- --is start in the income statement accounts screen- --all start in the all accounts screen- --register=ACCTREGEX start in the (first matched) account's register- --change show period balances (changes) at startup instead- of historical balances- -l --flat show accounts as a flat list (default)- -t --tree show accounts as a tree+ Flags:+ -w --watch watch for data and date changes and reload+ automatically+ --theme=THEME use this custom display theme (light,+ dark, terminal, greenterm)+ --cash start in the cash accounts screen+ --bs start in the balance sheet accounts screen+ --is start in the income statement accounts screen+ --all start in the all accounts screen+ --register=ACCTREGEX start in the (first matched) account's register+ --change show period balances (changes) at startup instead+ of historical balances+ -l --flat show accounts as a flat list (default)+ -t --tree show accounts as a tree - and also supports many of hledger's general options:+ and also supports many of hledger's general options: - General input/data transformation flags:- -f --file=[FMT:]FILE Read data from FILE, or from stdin if FILE is -,- inferring format from extension or a FMT: prefix.- Can be specified more than once. If not specified,- reads from $LEDGER_FILE or $HOME/.hledger.journal.- --rules=RULESFILE Use rules defined in this rules file for- converting subsequent CSV/SSV/TSV files. If not- specified, uses FILE.csv.rules for each FILE.csv.- --alias=A=B|/RGX/=RPL transform account names from A to B, or by- replacing regular expression matches- --auto generate extra postings by applying auto posting- rules ("=") to all transactions- --forecast[=PERIOD] Generate extra transactions from periodic rules- ("~"), from after the latest ordinary transaction- until 6 months from now. Or, during the specified- PERIOD (the equals is required). Auto posting rules- will also be applied to these transactions. In- hledger-ui, also make future-dated transactions- visible at startup.- -I --ignore-assertions don't check balance assertions by default- --txn-balancing=... how to check that transactions are balanced:- 'old': use global display precision- 'exact': use transaction precision (default)- --infer-costs infer conversion equity postings from costs- --infer-equity infer costs from conversion equity postings- --infer-market-prices infer market prices from costs- --pivot=TAGNAME use a different field or tag as account names- -s --strict do extra error checks (and override -I)- --verbose-tags add tags indicating generated/modified data+ General input/data transformation flags:+ -f --file=[FMT:]FILE Read data from FILE, or from stdin if FILE is -,+ inferring format from extension or a FMT: prefix.+ Can be specified more than once. If not specified,+ reads from $LEDGER_FILE or $HOME/.hledger.journal.+ --rules=RULESFILE Use rules defined in this rules file for+ converting subsequent CSV/SSV/TSV files. If not+ specified, uses FILE.csv.rules for each FILE.csv.+ --alias=A=B|/RGX/=RPL transform account names from A to B, or by+ replacing regular expression matches+ --auto generate extra postings by applying auto posting+ rules ("=") to all transactions+ --forecast[=PERIOD] Generate extra transactions from periodic rules+ ("~"), from after the latest ordinary transaction+ until 6 months from now. Or, during the specified+ PERIOD (the equals is required). Auto posting rules+ will also be applied to these transactions. In+ hledger-ui, also make future-dated transactions+ visible at startup.+ -I --ignore-assertions don't check balance assertions by default+ --txn-balancing=... how to check that transactions are balanced:+ 'old': use global display precision+ 'exact': use transaction precision (default)+ --infer-costs infer conversion equity postings from costs+ --infer-equity infer costs from conversion equity postings+ --infer-market-prices infer market prices from costs+ --pivot=TAGNAME use a different field or tag as account names+ -s --strict do extra error checks (and override -I)+ --verbose-tags add tags indicating generated/modified data - General output/reporting flags (supported by some commands):- -b --begin=DATE include postings/transactions on/after this date- -e --end=DATE include postings/transactions before this date- (with a report interval, will be adjusted to- following subperiod end)- -D --daily multiperiod report with 1 day interval- -W --weekly multiperiod report with 1 week interval- -M --monthly multiperiod report with 1 month interval- -Q --quarterly multiperiod report with 1 quarter interval- -Y --yearly multiperiod report with 1 year interval- -p --period=PERIODEXP set begin date, end date, and/or report interval,- with more flexibility- --today=DATE override today's date (affects relative dates)- --date2 match/use secondary dates instead (deprecated)- -U --unmarked include only unmarked postings/transactions- -P --pending include only pending postings/transactions- -C --cleared include only cleared postings/transactions- (-U/-P/-C can be combined)- -R --real include only non-virtual postings- -E --empty Show zero items, which are normally hidden.- In hledger-ui & hledger-web, do the opposite.- --depth=DEPTHEXP if a number (or -NUM): show only top NUM levels- of accounts. If REGEXP=NUM, only apply limiting to- accounts matching the regular expression.- -B --cost show amounts converted to their cost/sale amount- -V --market Show amounts converted to their value at period- end(s) in their default valuation commodity.- Equivalent to --value=end.- -X --exchange=COMM Show amounts converted to their value at period- end(s) in the specified commodity.- Equivalent to --value=end,COMM.- --value=WHEN[,COMM] show amounts converted to their value on the- specified date(s) in their default valuation- commodity or a specified commodity. WHEN can be:- 'then': value on transaction dates- 'end': value at period end(s)- 'now': value today- YYYY-MM-DD: value on given date- -c --commodity-style=S Override a commodity's display style.- Eg: -c '.' or -c '1.000,00 EUR'- --pretty[=YN] Use box-drawing characters in text output? Can be- 'y'/'yes' or 'n'/'no'.- If YN is specified, the equals is required.+ General output/reporting flags (supported by some commands):+ -b --begin=DATE include postings/transactions on/after this date+ -e --end=DATE include postings/transactions before this date+ (with a report interval, will be adjusted to+ following subperiod end)+ -D --daily multiperiod report with 1 day interval+ -W --weekly multiperiod report with 1 week interval+ -M --monthly multiperiod report with 1 month interval+ -Q --quarterly multiperiod report with 1 quarter interval+ -Y --yearly multiperiod report with 1 year interval+ -p --period=PERIODEXP set begin date, end date, and/or report interval,+ with more flexibility+ --today=DATE override today's date (affects relative dates)+ --date2 match/use secondary dates instead (deprecated)+ -U --unmarked include only unmarked postings/transactions+ -P --pending include only pending postings/transactions+ -C --cleared include only cleared postings/transactions+ (-U/-P/-C can be combined)+ -R --real include only non-virtual postings+ -E --empty Show zero items, which are normally hidden.+ In hledger-ui & hledger-web, do the opposite.+ --depth=DEPTHEXP if a number (or -NUM): show only top NUM levels+ of accounts. If REGEXP=NUM, only apply limiting to+ accounts matching the regular expression.+ -B --cost show amounts converted to their cost/sale amount+ -V --market Show amounts converted to their value at period+ end(s) in their default valuation commodity.+ Equivalent to --value=end.+ -X --exchange=COMM Show amounts converted to their value at period+ end(s) in the specified commodity.+ Equivalent to --value=end,COMM.+ --value=WHEN[,COMM] show amounts converted to their value on the+ specified date(s) in their default valuation+ commodity or a specified commodity. WHEN can be:+ 'then': value on transaction dates+ 'end': value at period end(s)+ 'now': value today+ YYYY-MM-DD: value on given date+ -c --commodity-style=S Override a commodity's display style.+ Eg: -c '.' or -c '1.000,00 EUR'+ --pretty[=YN] Use box-drawing characters in text output? Can be+ 'y'/'yes' or 'n'/'no'.+ If YN is specified, the equals is required. - General help flags:- -h --help show command line help- --tldr show command examples with tldr- --info show the manual with info- --man show the manual with man- --version show version information- --debug=[1-9] show this much debug output (default: 1)- --pager=YN use a pager when needed ? y/yes (default) or n/no- --color=YNA --colour use ANSI color ? y/yes, n/no, or auto (default)+ General help flags:+ -h --help show command line help+ --tldr show command examples with tldr+ --info show the manual with info+ --man show the manual with man+ --version show version information+ --debug=[1-9] show this much debug output (default: 1)+ --pager=YN use a pager when needed ? y/yes (default) or n/no+ --color=YNA --colour use ANSI color ? y/yes, n/no, or auto (default) - With hledger-ui, the --debug option sends debug output to a- hledger-ui.log file in the current directory.+ With hledger-ui, the --debug option sends debug output to a hledger-ui.log+ file in the current directory. - If you use the bash shell, you can auto-complete flags by pressing TAB- in the command line. If this is not working see Install > Shell com-- pletions.+ If you use the bash shell, you can auto-complete flags by pressing TAB in+ the command line. If this is not working see Install > Shell completions. MOUSE- In most modern terminals, you can navigate through the screens with a- mouse or touchpad:+ In most modern terminals, you can navigate through the screens with a mouse+ or touchpad: - o Use mouse wheel or trackpad to scroll up and down+ * Use mouse wheel or trackpad to scroll up and down - o Click on list items to go deeper+ * Click on list items to go deeper - o Click on the left margin (column 0) to go back.+ * Click on the left margin (column 0) to go back. KEYS- Keyboard gives more control.+ Keyboard gives more control. - ? shows a help dialog listing all keys. (Some of these also appear in- the quick help at the bottom of each screen.) Press ? again (or ES-- CAPE, or LEFT, or q) to close it. The following keys work on most- screens:+ ? shows a help dialog listing all keys. (Some of these also appear in the+ quick help at the bottom of each screen.) Press ? again (or ESCAPE, or+ LEFT, or q) to close it. The following keys work on most screens: - The cursor keys navigate: RIGHT or ENTER goes deeper, LEFT returns to- the previous screen, UP/DOWN/PGUP/PGDN/HOME/END move up and down- through lists. Emacs-style (CTRL-p/CTRL-n/CTRL-f/CTRL-b) and VI-style- (k,j,l,h) movement keys are also supported.+ The cursor keys navigate: RIGHT or ENTER goes deeper, LEFT returns to the+ previous screen, UP/DOWN/PGUP/PGDN/HOME/END move up and down through lists.+ J/K jump down/up 10 items at a time. Emacs-style+ (CTRL-p/CTRL-n/CTRL-f/CTRL-b) and VI-style (k,j,l,h) movement keys are also+ supported. - (Tip: movement speed is limited by your keyboard repeat rate, to move- faster you may want to adjust it. On a mac, the Karabiner app is one- way to do that.)+ (Tip: movement speed is limited by your keyboard repeat rate, to move+ faster you may want to adjust it. On a mac, the Karabiner app is one way+ to do that.) - / lets you set a general filter query limiting the data shown, using- the same query terms as in hledger and hledger-web. While editing the- query, you can use CTRL-a/e/d/k, BS, cursor keys; press ENTER to set- it, or ESCAPEto cancel. There are also keys for quickly adjusting some- common filters like account depth and transaction status (see below).- BACKSPACE or DELETE removes all filters, showing all transactions.+ / lets you set a general filter query limiting the data shown, using the+ same query terms as in hledger and hledger-web. While editing the query,+ you can use CTRL-a/e/d/k, BS, cursor keys; press ENTER to set it, or ES-+ CAPEto cancel. There are also keys for quickly adjusting some common fil-+ ters like account depth and transaction status (see below). BACKSPACE or+ DELETE removes all filters, showing all transactions. - As mentioned above, by default hledger-ui hides future transactions -- both ordinary transactions recorded in the journal, and periodic trans-- actions generated by rule. F toggles forecast mode, in which fu-- ture/forecasted transactions are shown.+ As mentioned above, by default hledger-ui hides future transactions - both+ ordinary transactions recorded in the journal, and periodic transactions+ generated by rule. F toggles forecast mode, in which future/forecasted+ transactions are shown. - Pressing SHIFT-DOWN narrows the report period, and pressing SHIFT-UP- expands it again. When narrowed, the current report period is dis-- played in the header line, pressing SHIFT-LEFT or SHIFT-RIGHT moves to- the previous or next period, and pressing T sets the period to "today".- If you are using -w/--watch and viewing a narrowed period containing- today, the view will follow any changes in system date (moving to the- period containing the new date). (These keys work only with the stan-- dard Julian calendar year/quarter/month/week/day periods; they are not- affected by a custom report interval specified at the command line.)+ Pressing SHIFT-DOWN narrows the report period, and pressing SHIFT-UP ex-+ pands it again. When narrowed, the current report period is displayed in+ the header line, pressing SHIFT-LEFT or SHIFT-RIGHT moves to the previous+ or next period, and pressing T sets the period to "today". If you are us-+ ing -w/--watch and viewing a narrowed period containing today, the view+ will follow any changes in system date (moving to the period containing the+ new date). (These keys work only with the standard Julian calendar+ year/quarter/month/week/day periods; they are not affected by a custom re-+ port interval specified at the command line.) - You can also specify a non-standard period with / and a date: query; in- this case, the period is not movable with the arrow keys.+ You can also specify a non-standard period with / and a date: query; in+ this case, the period is not movable with the arrow keys. - (Tip: arrow keys with Shift do not work out of the box in all terminal- software. Eg in Apple's Terminal, the SHIFT-DOWN and SHIFT-UP keys- must be configured as follows: in Terminal's preferences, click Pro-- files, select your current profile on the left, click Keyboard on the- right, click + and add this for SHIFT-DOWN: \033[1;2B, click + and add- this for SHIFT-UP: \033[1;2A. In other terminals (Windows Terminal ?)- you might need to configure SHIFT-RIGHT and SHIFT-LEFT to emit- \033[1;2C and \033[1;2D respectively.)+ (Tip: arrow keys with Shift do not work out of the box in all terminal+ software. Eg in Apple's Terminal, the SHIFT-DOWN and SHIFT-UP keys must be+ configured as follows: in Terminal's preferences, click Profiles, select+ your current profile on the left, click Keyboard on the right, click + and+ add this for SHIFT-DOWN: \033[1;2B, click + and add this for SHIFT-UP:+ \033[1;2A. In other terminals (Windows Terminal ?) you might need to+ configure SHIFT-RIGHT and SHIFT-LEFT to emit \033[1;2C and \033[1;2D re-+ spectively.) - ESCAPE resets the UI state and jumps back to the top screen, restoring- the app's initial state at startup. Or, it cancels minibuffer data en-- try or the help dialog.+ ESCAPE resets the UI state and jumps back to the top screen, restoring the+ app's initial state at startup. Or, it cancels minibuffer data entry or+ the help dialog. - CTRL-l redraws the screen and centers the selection if possible (selec-- tions near the top won't be centered, since we don't scroll above the- top).+ CTRL-l redraws the screen and centers the selection if possible (selections+ near the top won't be centered, since we don't scroll above the top). - g reloads from the data file(s) and updates the current screen and any- previous screens. (With large files, this could cause a noticeable- pause.)+ g reloads from the data file(s) and updates the current screen and any pre-+ vious screens. (With large files, this could cause a noticeable pause.) - I toggles balance assertion checking. Disabling balance assertions- temporarily can be useful for troubleshooting. (If hledger-ui was- started with a --pivot option, re-enabling balance assertions with the- I key also reloads the journal, like g.)+ I toggles balance assertion checking. Disabling balance assertions tem-+ porarily can be useful for troubleshooting. (If hledger-ui was started+ with a --pivot option, re-enabling balance assertions with the I key also+ reloads the journal, like g.) - a runs command-line hledger's add command, and reloads the updated- file. This allows some basic data entry.+ a runs command-line hledger's add command, and reloads the updated file.+ This allows some basic data entry. - A is like a, but runs the hledger-iadd tool, which provides a terminal- interface. This key will be available if hledger-iadd is installed in- $path.+ A is like a, but runs the hledger-iadd tool, which provides a terminal in-+ terface. This key will be available if hledger-iadd is installed in $path. - E runs $HLEDGER_UI_EDITOR, or $EDITOR, or a default (emacsclient -a ""- -nw) on the journal file. With some editors (emacs, vi), the cursor- will be positioned at the current transaction when invoked from the- register and transaction screens, and at the error location (if possi-- ble) when invoked from the error screen.+ E runs $HLEDGER_UI_EDITOR, or $EDITOR, or a default (emacsclient -a "" -nw)+ on the journal file. With some editors (emacs, vi), the cursor will be po-+ sitioned at the current transaction when invoked from the register and+ transaction screens, and at the error location (if possible) when invoked+ from the error screen. - B toggles cost mode, showing amounts converted to their cost's commod-- ity (see hledger manual > Cost reporting.+ B toggles cost mode, showing amounts converted to their cost's commodity+ (see hledger manual > Cost reporting. - V toggles value mode, showing amounts converted to their market value- (see hledger manual > Valuation flag). More specifically,+ V toggles value mode, showing amounts converted to their market value (see+ hledger manual > Valuation flag). More specifically, - 1. By default, the V key toggles showing end value (--value=end) on or- off. The valuation date will be the report end date if specified,- otherwise today.+ 1. By default, the V key toggles showing end value (--value=end) on or off.+ The valuation date will be the report end date if specified, otherwise+ today. - 2. If you started hledger-ui with some other valuation (such as- --value=then,EUR), the V key toggles that off or on.+ 2. If you started hledger-ui with some other valuation (such as+ --value=then,EUR), the V key toggles that off or on. - Cost/value tips: - When showing end value, you can change the report- end date without restarting, by pressing / and adding a query like- date:..YYYY-MM-DD. - Either cost mode, or value mode, can be active,- but not both at once. Cost mode takes precedence. - There's not yet- any visual indicator that cost or value mode is active, other than the- amount values.+ Cost/value tips: - When showing end value, you can change the report end+ date without restarting, by pressing / and adding a query like+ date:..YYYY-MM-DD. - Either cost mode, or value mode, can be active, but+ not both at once. Cost mode takes precedence. - There's not yet any vi-+ sual indicator that cost or value mode is active, other than the amount+ values. - q quits the application.+ q quits the application. - Additional screen-specific keys are described below.+ Additional screen-specific keys are described below. SCREENS- At startup, hledger-ui shows a menu screen by default. From here you- can navigate to other screens using the cursor keys: UP/DOWN to select,- RIGHT to move to the selected screen, LEFT to return to the previous- screen. Or you can use ESC to return directly to the top menu screen.+ At startup, hledger-ui shows a menu screen by default. From here you can+ navigate to other screens using the cursor keys: UP/DOWN to select, RIGHT+ to move to the selected screen, LEFT to return to the previous screen. Or+ you can use ESC to return directly to the top menu screen. - You can also use a command line flag to specific a different startup- screen (--cs, --bs, --is, --all, or --register=ACCT).+ You can also use a command line flag to specific a different startup screen+ (--cs, --bs, --is, --all, or --register=ACCT). Menu screen- This is the top-most screen. From here you can navigate to several- screens listing accounts of various types. Note some of these may not- show anything until you have configured account types.+ This is the top-most screen. From here you can navigate to several screens+ listing accounts of various types. Note some of these may not show any-+ thing until you have configured account types. Cash accounts screen- This screen shows "cash" (ie, liquid asset) accounts (like hledger bal-- ancesheet type:c). It always shows balances (historical ending bal-- ances on the date shown in the title line).+ This screen shows "cash" (ie, liquid asset) accounts (like hledger bal-+ ancesheet type:c). It always shows balances (historical ending balances on+ the date shown in the title line). Balance sheet accounts screen- This screen shows asset, liability and equity accounts (like hledger- balancesheetequity). It always shows balances.+ This screen shows asset, liability and equity accounts (like hledger bal-+ ancesheetequity). It always shows balances. Income statement accounts screen- This screen shows revenue and expense accounts (like hledger incomes-- tatement). It always shows changes (balance changes in the period- shown in the title line).+ This screen shows revenue and expense accounts (like hledger incomestate-+ ment). It always shows changes (balance changes in the period shown in the+ title line). All accounts screen- This screen shows all accounts in your journal (unless filtered by a- query; like hledger balance). It shows balances by default; you can- toggle showing changes with the H key.+ This screen shows all accounts in your journal (unless filtered by a query;+ like hledger balance). It shows balances by default; you can toggle show-+ ing changes with the H key. Register screen- This screen shows the transactions affecting a particular account.- Each line represents one transaction, and shows:+ This screen shows the transactions affecting a particular account. Each+ line represents one transaction, and shows: - o the other account(s) involved, in abbreviated form. (If there are- both real and virtual postings, it shows only the accounts affected- by real postings.)+ * the other account(s) involved, in abbreviated form. (If there are both+ real and virtual postings, it shows only the accounts affected by real+ postings.) - o the overall change to the current account's balance; positive for an- inflow to this account, negative for an outflow.+ * the overall change to the current account's balance; positive for an in-+ flow to this account, negative for an outflow. - o the running total after the transaction. With the H key you can tog-- gle between+ * the running total after the transaction. With the H key you can toggle+ between - o the period total, which is from just the transactions displayed+ * the period total, which is from just the transactions displayed - o or the historical total, which includes any undisplayed transac-- tions before the start of the report period (and matching the fil-- ter query if any). This will be the running historical balance- (what you would see on a bank's website, eg) if not disturbed by a- query.+ * or the historical total, which includes any undisplayed transactions+ before the start of the report period (and matching the filter query if+ any). This will be the running historical balance (what you would see+ on a bank's website, eg) if not disturbed by a query. - Note, this screen combines each transaction's in-period postings to a- single line item, dated with the earliest in-period transaction or- posting date (like hledger's aregister). So custom posting dates can- cause the running balance to be temporarily inaccurate. (See hledger- manual > aregister and posting dates.)+ Note, this screen combines each transaction's in-period postings to a sin-+ gle line item, dated with the earliest in-period transaction or posting+ date (like hledger's aregister). So custom posting dates can cause the+ running balance to be temporarily inaccurate. (See hledger manual > areg-+ ister and posting dates.) - Transactions affecting this account's subaccounts will be included in- the register if the accounts screen is in tree mode, or if it's in list- mode but this account has subaccounts which are not shown due to a- depth limit. In other words, the register always shows the transac-- tions contributing to the balance shown on the accounts screen. Tree- mode/list mode can be toggled with t here also.+ Transactions affecting this account's subaccounts will be included in the+ register if the accounts screen is in tree mode, or if it's in list mode+ but this account has subaccounts which are not shown due to a depth limit.+ In other words, the register always shows the transactions contributing to+ the balance shown on the accounts screen. Tree mode/list mode can be tog-+ gled with t here also. - U toggles filtering by unmarked status, showing or hiding unmarked- transactions. Similarly, P toggles pending transactions, and C toggles- cleared transactions. (By default, transactions with all statuses are- shown; if you activate one or two status filters, only those transac-- tions are shown; and if you activate all three, the filter is removed.)+ U toggles filtering by unmarked status, showing or hiding unmarked transac-+ tions. Similarly, P toggles pending transactions, and C toggles cleared+ transactions. (By default, transactions with all statuses are shown; if+ you activate one or two status filters, only those transactions are shown;+ and if you activate all three, the filter is removed.) - R toggles real mode, in which virtual postings are ignored.+ R toggles real mode, in which virtual postings are ignored. - z toggles nonzero mode, in which only transactions posting a nonzero- change are shown (hledger-ui shows zero items by default, unlike com-- mand-line hledger).+ z toggles nonzero mode, in which only transactions posting a nonzero change+ are shown (hledger-ui shows zero items by default, unlike command-line+ hledger). - Press RIGHT to view the selected transaction in detail.+ Press RIGHT to view the selected transaction in detail. Transaction screen- This screen shows a single transaction, as a general journal entry,- similar to hledger's print command and journal format (hledger_jour-- nal(5)).+ This screen shows a single transaction, as a general journal entry, similar+ to hledger's print command and journal format (hledger_journal(5)). - The transaction's date(s) and any cleared flag, transaction code, de-- scription, comments, along with all of its account postings are shown.- Simple transactions have two postings, but there can be more (or in- certain cases, fewer).+ The transaction's date(s) and any cleared flag, transaction code, descrip-+ tion, comments, along with all of its account postings are shown. Simple+ transactions have two postings, but there can be more (or in certain cases,+ fewer). - UP and DOWN will step through all transactions listed in the previous- account register screen. In the title bar, the numbers in parentheses- show your position within that account register. They will vary de-- pending on which account register you came from (remember most transac-- tions appear in multiple account registers). The #N number preceding- them is the transaction's position within the complete unfiltered jour-- nal, which is a more stable id (at least until the next reload).+ UP and DOWN will step through all transactions listed in the previous ac-+ count register screen. In the title bar, the numbers in parentheses show+ your position within that account register. They will vary depending on+ which account register you came from (remember most transactions appear in+ multiple account registers). The #N number preceding them is the transac-+ tion's position within the complete unfiltered journal, which is a more+ stable id (at least until the next reload). - On this screen (and the register screen), the E key will open your text- editor with the cursor positioned at the current transaction if possi-- ble.+ On this screen (and the register screen), the E key will open your text ed-+ itor with the cursor positioned at the current transaction if possible. Error screen- This screen will appear if there is a problem, such as a parse error,- when you press g to reload. Once you have fixed the problem, press g- again to reload and resume normal operation. (Or, you can press escape- to cancel the reload attempt.)+ This screen will appear if there is a problem, such as a parse error, when+ you press g to reload. Once you have fixed the problem, press g again to+ reload and resume normal operation. (Or, you can press escape to cancel+ the reload attempt.) WATCH MODE- One of hledger-ui's best features is the auto-reloading -w/--watch- mode. With this flag, it will update the display automatically when-- ever changes are saved to the data files.+ One of hledger-ui's best features is the auto-reloading -w/--watch mode.+ With this flag, it will update the display automatically whenever changes+ are saved to the data files. - This is very useful when reconciling. A good workflow is to have your- bank's online register open in a browser window, for reference; the- journal file open in an editor window; and hledger-ui in watch mode in- a terminal window, eg:+ This is very useful when reconciling. A good workflow is to have your+ bank's online register open in a browser window, for reference; the journal+ file open in an editor window; and hledger-ui in watch mode in a terminal+ window, eg: - $ hledger-ui --watch --register checking -C+ $ hledger-ui --watch --register checking -C - As you mark things cleared in the editor, you can see the effect imme-- diately without having to context switch. This leaves more mental- bandwidth for your accounting. Of course you can still interact with- hledger-ui when needed, eg to toggle cleared mode, or to explore the- history.+ As you mark things cleared in the editor, you can see the effect immedi-+ ately without having to context switch. This leaves more mental bandwidth+ for your accounting. Of course you can still interact with hledger-ui when+ needed, eg to toggle cleared mode, or to explore the history. --watch problems- However. There are limitations/unresolved bugs with --watch:+ However. There are limitations/unresolved bugs with --watch: - o It may not work at all for you, depending on platform or system con-- figuration. On some unix systems, increasing fs.ino-- tify.max_user_watches or fs.file-max parameters in /etc/sysctl.conf- might help. (#836)+ * It may not work at all for you, depending on platform or system configu-+ ration. On some unix systems, increasing fs.inotify.max_user_watches or+ fs.file-max parameters in /etc/sysctl.conf might help. (#836) - o It may not detect changes made from outside a virtual machine, ie by- an editor running on the host system.+ * It may not detect changes made from outside a virtual machine, ie by an+ editor running on the host system. - o It may not detect file changes on certain less common filesystems.+ * It may not detect file changes on certain less common filesystems. - o It may use increasing CPU and RAM over time, especially with large- files. (This is probably not --watch specific, you may be able to- reproduce it by pressing g repeatedly.) (#1825)+ * It may use increasing CPU and RAM over time, especially with large files.+ (This is probably not --watch specific, you may be able to reproduce it+ by pressing g repeatedly.) (#1825) - Tips/workarounds:+ Tips/workarounds: - o If --watch won't work for you, press g to reload data manually in-- stead.+ * If --watch won't work for you, press g to reload data manually instead. - o If --watch is leaking resources over time, quit and restart (or sus-- pend and resume) hledger-ui when you're not using it.+ * If --watch is leaking resources over time, quit and restart (or suspend+ and resume) hledger-ui when you're not using it. - o When running hledger-ui inside a VM, also make file changes inside- the VM.+ * When running hledger-ui inside a VM, also make file changes inside the+ VM. - o When working with files mounted from another machine, make sure the- system clocks on both machines are roughly in agreement.+ * When working with files mounted from another machine, make sure the sys-+ tem clocks on both machines are roughly in agreement. ENVIRONMENT- LEDGER_FILE The main journal file to use when not specified with- -f/--file. Default: $HOME/.hledger.journal.+ LEDGER_FILE The main journal file to use when not specified with -f/--file.+ Default: $HOME/.hledger.journal. BUGS- We welcome bug reports in the hledger issue tracker- (https://bugs.hledger.org), or on the hledger chat or mail list- (https://hledger.org/support).+ We welcome bug reports in the hledger issue tracker+ (https://bugs.hledger.org), or on the hledger chat or mail list+ (https://hledger.org/support). - Some known issues:+ Some known issues: - -f- doesn't work (hledger-ui can't read from stdin).+ -f- doesn't work (hledger-ui can't read from stdin). - --watch is not robust, especially with large files (see WATCH MODE- above).+ --watch is not robust, especially with large files (see WATCH MODE above). - If you press g with large files, there could be a noticeable pause with- the UI unresponsive.+ If you press g with large files, there could be a noticeable pause with the+ UI unresponsive. AUTHORS- Simon Michael <simon@joyful.com> and contributors.- See http://hledger.org/CREDITS.html+ Simon Michael <simon@joyful.com> and contributors.+ See http://hledger.org/CREDITS.html COPYRIGHT- Copyright 2007-2023 Simon Michael and contributors.+ Copyright 2007-2023 Simon Michael and contributors. LICENSE- Released under GNU GPL v3 or later.+ Released under GNU GPL v3 or later. SEE ALSO- hledger(1), hledger-ui(1), hledger-web(1), ledger(1)+ hledger(1), hledger-ui(1), hledger-web(1), ledger(1) -hledger-ui-1.51.2 December 2025 HLEDGER-UI(1)+hledger-ui-1.52 March 2026 HLEDGER-UI(1)