Browse Source

Add support for fetching mutual fund prices

Samuel W. Flint 6 years ago
parent
commit
816ddb6559
1 changed files with 2 additions and 0 deletions
  1. 2 0
      bean-prices

+ 2 - 0
bean-prices

@@ -18,6 +18,8 @@ for line in $(cat ~/.ledger/commodities.txt ) ; do
         bean-price -e "USD:google/$COMMODITY" | awk -e '{printf "%s %s %s %.2f %s\n", $1, $2, $3, $4, $5}'  | tee -a ${TEMP_FILE}
     elif [ $TYPE == 'm' ] ; then
         bean-price -e "USD:oanda/${COMMODITY}_USD" | sed -e 's/_USD//' | awk -e '{printf "%s %s %s %.2f %s\n", $1, $2, $3, $4, $5}'  | tee -a ${TEMP_FILE}
+    elif [ $TYPE == 'f' ] ; then
+        bean-price -e "USD:google/MUTF:${COMMODITY}" | sed -e 's/MUTF://' | awk -e '{printf "%s %s %s %.2f %s\n", $1, $2, $3, $4, $5}'  | tee -a ${TEMP_FILE}
     else
         echo "$TYPE is not currently a known type."
     fi