Re: Shell Scripting Question

2003-06-24 Thread Cameron Simpson
On 08:21 24 Jun 2003, Jon Haugsand <[EMAIL PROTECTED]> wrote: | * Cameron Simpson | > | > I tend to do this: | > find dir -type f -name '*.html' -exec bsed 's|this|long/thing/with/slashes/this|g' {} ';' | > or just: | > bsed 's|this|long/thing/with/slashes/this|g' *.html | > for just the .

Re: bsed (was: Re: Shell Scripting Question)

2003-06-24 Thread Cameron Simpson
On 08:22 24 Jun 2003, Jon Haugsand <[EMAIL PROTECTED]> wrote: | * Cameron Simpson | > You can get bsed here: | > | > http://www.cskk.ezoshosting.com/cs/scripts/bsed | > | > An extremely useful wrapper for sed. | | Not much information here, is it? Can you give a short tutorial? You treat it

bsed (was: Re: Shell Scripting Question)

2003-06-23 Thread Jon Haugsand
* Cameron Simpson > You can get bsed here: > > http://www.cskk.ezoshosting.com/cs/scripts/bsed > > An extremely useful wrapper for sed. Not much information here, is it? Can you give a short tutorial? -- Jon Haugsand, [EMAIL PROTECTED] http://www.norges-bank.no -- redhat-list mailing

Re: Shell Scripting Question

2003-06-23 Thread Jon Haugsand
* Cameron Simpson > > I tend to do this: > find dir -type f -name '*.html' -exec bsed > 's|this|long/thing/with/slashes/this|g' {} ';' > or just: > bsed 's|this|long/thing/with/slashes/this|g' *.html > for just the .html files in the current directory. As far as I understood the quest

Re: Shell Scripting Question

2003-06-23 Thread Cameron Simpson
On 16:18 23 Jun 2003, Richard Crawford <[EMAIL PROTECTED]> wrote: | Jonathan Bartlett said: | > I'm very curious why you want this. Anyway, basically, go to the top | > level and run this perl script( NOTE - I haven't even tested this to see | > if it will compile, so it will likely delete all you

Re: Shell Scripting Question

2003-06-23 Thread Richard Crawford
Jonathan Bartlett said: > I'm very curious why you want this. Anyway, basically, go to the top > level and run this perl script( NOTE - I haven't even tested this to see > if it will compile, so it will likely delete all your files and set your > computer on fire. But it should give you a starti

Re: Shell Scripting Question

2003-06-23 Thread Richard Crawford
Jonathan Bartlett said: > I'm very curious why you want this. Anyway, basically, go to the top > level and run this perl script( NOTE - I haven't even tested this to see > if it will compile, so it will likely delete all your files and set your > computer on fire. But it should give you a starti

Re: Shell Scripting Question

2003-06-23 Thread Jonathan Bartlett
I'm very curious why you want this. Anyway, basically, go to the top level and run this perl script( NOTE - I haven't even tested this to see if it will compile, so it will likely delete all your files and set your computer on fire. But it should give you a starting point): #!/usr/bin/perl sub

RE: Shell Scripting Question

2003-06-23 Thread Brian Lucas
Title: RE: Shell Scripting Question Make a script using the below.  Then change to your highest folder and then run: # sh name_of_script.sh *.htm -- #!/bin/ksh tmpdir=tmp.$$ mkdir $tmpdir.new for f in $* do     sed -e 's/action="" href="http://www.the