* Sim Tov <[email protected]> [2022-02-06 12:43]:
> I would like to use the output of `ledger balance ...` in a bash script. I
> want to get a number/amount only, without all the strings around it... is
> there a command line option to get amount only (even without
> commodity/currency sign)?
This gets you the amount (with the commodity):
ledger bal assets:cash --balance-format "%(amount)"
I'm not sure if you can get just the number, but you can just run this
command through sed or perl to remove the commodity.
--
Martin Michlmayr
https://www.cyrius.com/
--
---
You received this message because you are subscribed to the Google Groups
"Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ledger-cli/YgBn3YhG1C3IrRH/%40jirafa.cyrius.com.