Explorar o código

Fix precious metals price retrieval

Samuel W. Flint %!s(int64=5) %!d(string=hai) anos
pai
achega
91b81a3ba2
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  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:iex/$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=X" | sed -e 's/USD=X//' | awk -e '{printf "%s %s %s %.2f %s\n", $1, $2, $3, $4, $5}'  | tee -a ${TEMP_FILE}
+        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:yahoo/${COMMODITY}" | awk -e '{printf "%s %s %s %.2f %s\n", $1, $2, $3, $4, $5}'  | tee -a ${TEMP_FILE}
     else