#!/bin/bash # shorting url with kon.tl site # howto : # $ ./kon.sh http://google.com cobakon # Your New Short URL: http://kon.tl/cobakon # thank's to jim geovedi for the idea (https://github.com/geovedi/kontl) curl -s -d "url=$1&tag=$2" http://kon.tl/create.php > index link=`cat index | grep -i New | awk -F "=" '{print $2}' | sed 's/target//'` echo "Your Long URL: $1" echo "Your New Short URL: $link" rm index