PC & IT SUPPORT MADE EASY FORUM
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Command Line Currency Convertion For Linux

Go down

Command Line Currency Convertion For Linux Empty Command Line Currency Convertion For Linux

Post by jamied_uk 25th March 2016, 01:21

Code:
sudo gedit ~/.bashrc



Create new line at the end of the file, and put this code:
Code:

currency_convert() {
        curl -s "http://www.google.com/finance/converter?a=$1&from=$2&to=$3" | sed '/res/!d;s/<[^>]*>//g';
        }



http://www.ubuntubuzz.com/2012/04/trick-currency-converter-on-command.html


now save and exit

now type


source ~/.bashrc


currency_convert 1 usd eur



Last edited by jamied_uk on 25th March 2016, 01:36; edited 2 times in total
jamied_uk
jamied_uk
Admin

Posts : 2951
Join date : 2010-05-09
Age : 41
Location : UK

https://jnet.sytes.net

Back to top Go down

Command Line Currency Convertion For Linux Empty Re: Command Line Currency Convertion For Linux

Post by jamied_uk 25th March 2016, 01:34

jamied_uk
jamied_uk
Admin

Posts : 2951
Join date : 2010-05-09
Age : 41
Location : UK

https://jnet.sytes.net

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum