BEAN-PRICE(1)

πŸ“¦
version 2.3.6 Β· 3 versions
, in ubuntu noble

🌸 NAME 🌸

bean-price β€” fetch from the internet commodity prices for Beancount processing πŸ’–


✨ DESCRIPTION ✨

okay so here's the whole vibe bestie: bean-price goes out onto the internet 🌐, grabs commodity prices, and spits them back out as Beancount price directives. that's the gig. that's the whole gig. iconic behavior fr fr.

here's the usage, verbatim, no cap:

usage: bean-price [-h] [--version] [-e] [-v] [-d DATE] [-i] [-u
UNDECLARED]

       [-c] [-a] [-s] [-n] [--cache CACHE_FILENAME] [--no-cache]
       [--clear-cache] sources [sources ...]

πŸŽ€ positional arguments

  • sources β€” a list of filenames to build your job list from πŸ’… (or, if you passed -e, a list of source "module/symbol" strings instead β€” iykyk).

πŸ’œ options

  • -h, --help β€” shows this help message and then dips out. bye bestie πŸ‘‹
  • --version, -V β€” shows the program's version number and exits. short and sweet.
  • -e, --expressions, --expression β€” read the arguments as "module/symbol" source strings. that's the plot twist.
  • -v, --verbose β€” prints out the progress log. say it twice and you get debugging info too πŸ‘€
  • -d DATE, --date DATE β€” pick the date you want prices fetched for. time travel but make it finance.
  • -i, --inactive β€” grabs all commodities from the input files, not just the ones that are active on the date. everyone's invited to the party πŸŽ‰
  • -u UNDECLARED, --undeclared UNDECLARED β€” pulls in commodities that show up in the file even when there's no matching Commodity directive, using this default source. the currency name itself is used as the lookup symbol in this default source. lowkey genius.
  • -c, --clobber β€” does not skip prices that are already sitting in your input files; it fetches them anyway. rude but effective 😀
  • -a, --all β€” a shorthand for --inactive, --undeclared, --clobber. three-for-one deal, we love to see it.
  • -s, --swap-inverted β€” for inverted sources, swaps the currencies instead of inverting the rate. for example, if fetching the rate for CAD from 'USD:google/^CURRENCY:USDCAD' results in 1.25, by default we'd output "price CAD 0.8000 USD". using this option we'd instead output " price USD 1.2500 CAD". math girlies stay winning πŸ”₯
  • -n, --dry-run β€” doesn't actually fetch anything, just prints the list of the prices that would be fetched. a little peek behind the curtain 🫣

🧚 cache

  • --cache CACHE_FILENAME β€” turns the cache on, and names it with the given cache name.
  • --no-cache β€” turns the price cache off. sorry cache, not today πŸ’€
  • --clear-cache β€” wipes the cache before startup. clean slate, main character energy ✨

ngl, the cache options are the sleeper hits here. turn them on, keep them tidy, and your price fetching will be giving absolutely flawless vibes 🌈

and that's the page, bestie πŸŽ€ this lil beauty is from bean-price 2.3.6, dated April 2024. mwah, go fetch some prices πŸ’‹πŸ‘‘

πŸ“¦ where this page comes from