baslinux AT lists.ibiblio.org
Subject: Baslinux mailing list
List archive
Re: [BL] script to extract http://'s from a doc. 5A
- From: Lee Forrest <lforrestster AT gmail.com>
- To: baslinux AT lists.ibiblio.org, keesan AT sdf.lonestar.org
- Subject: Re: [BL] script to extract http://'s from a doc. 5A
- Date: Thu, 1 Mar 2007 18:39:24 +0000
On Thu, Mar 01, 2007 at 02:49:19PM +0000, Lee Forrest wrote:
[delete]
First script was sloppy. This truly deals with links, puts
"http://" in front of "www", uses the original url from the
file as the link name so that you can see which link is which,
and puts ".html" at the end of the resultant file so that a
browser knows it is to be interpreted as an html doc.
#!/bin/sh
#script.sh
#usage: script.sh file_with_urls
echo "<html><head></head><body>" > links.html
sed -n 's@^\(.*\)\(http://\|www\)\([^ ><"]*\)\(.*\)@<p><a
href="\2\3">\2\3</a>@p' "$1" | sed 's@\"www@\"http://www@' >> links.html
echo "</body></html>" >> links.html
links links.html
[delete]
Lee
--
BasicLinux: Small is Beautiful
http://www.basiclinux.com.ru
-
[BL] script to extract http://'s from a doc.,
sindi keesan, 03/01/2007
-
Re: [BL] script to extract http://'s from a doc.,
Lee Forrest, 03/01/2007
-
Re: [BL] script to extract http://'s from a doc. 5A,
Lee Forrest, 03/01/2007
-
Re: [BL] script to extract http://'s from a doc. 5A,
sindi keesan, 03/01/2007
- Re: [BL] script to extract http://'s from a doc. 5B, Lee Forrest, 03/01/2007
-
Re: [BL] script to extract http://'s from a doc. 5C,
Lee Forrest, 03/01/2007
- Re: [BL] script to extract http://'s from a doc. 5C, sindi keesan, 03/02/2007
-
Re: [BL] script to extract http://'s from a doc. 5A,
sindi keesan, 03/01/2007
- Re: [BL] script to extract http://'s from a doc., sindi keesan, 03/01/2007
-
Re: [BL] script to extract http://'s from a doc. 5A,
Lee Forrest, 03/01/2007
-
Re: [BL] script to extract http://'s from a doc.,
Samual Acorn, 03/02/2007
-
Re: [BL] script to extract http://'s from a doc.,
sindi keesan, 03/02/2007
-
Re: [BL] script to extract http://'s from a doc.,
3aoo-cvfd, 03/02/2007
-
Re: [BL] script to extract http://'s from a doc.,
sindi keesan, 03/03/2007
- Re: [BL] script to extract http://'s from a doc., sindi keesan, 03/03/2007
-
Re: [BL] script to extract http://'s from a doc.,
sindi keesan, 03/03/2007
-
Re: [BL] script to extract http://'s from a doc.,
3aoo-cvfd, 03/02/2007
-
Re: [BL] script to extract http://'s from a doc.,
sindi keesan, 03/02/2007
-
Re: [BL] script to extract http://'s from a doc.,
Lee Forrest, 03/01/2007
Archive powered by MHonArc 2.6.24.