Forráskód Böngészése

Support precious metals

Samuel W. Flint 6 éve
szülő
commit
11776bc4d6
1 módosított fájl, 1 hozzáadás és 1 törlés
  1. 1 1
      bean-prices

+ 1 - 1
bean-prices

@@ -17,7 +17,7 @@ for line in $(cat ~/.ledger/commodities.txt ) ; do
     elif [ $TYPE == 's' ] ; then
         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
-        echo "Precious metals are not currently supported."
+        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}
     else
         echo "$TYPE is not currently a known type."
     fi