#!/bin/rc if(~ $#* 2){ from = $1 to = $2 } if not{ from = auto to = en } hget 'https://translate.googleapis.com/translate_a/single?client=gtx&sl='^$from^'&tl='^$to^'&dt=t&q='^`{urlencode} | sed 's/[^"]*"([^"]*).*/\1/;q'