This is the mail archive of the
cygwin
mailing list for the Cygwin project.
gurl (call browser and it an URL)
- From: zzapper <david at tvis dot co dot uk>
- To: cygwin at cygwin dot com
- Date: Thu, 16 Feb 2006 18:11:56 +0000 (UTC)
- Subject: gurl (call browser and it an URL)
Hi
> gurl www.cygwin.com
or just gurl if url already in paste buffer
> gurl
function gurl()
{
# Go to URL
# description : Open URL in browser if no parameter use paste buffer
if [ $# -gt 0 ]
then
url=$1
else
url=$(getclip)
fi
if [[ "$url" = www* ]]
then
# add http:// prefix if required
url="http://${url}"
fi
# c:/progra~1/opera75/opera.exe $url
c:/Program\ Files/internet\ explorer/iexplore $url &
}
# I sent this before but didn't ever see it arrive?
--
zzapper
Success for Techies
http://SuccessTheory.com/ vim, zsh & success tips
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/