CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
Search Posts SEARCH
Who's Online WHO'S
Log in LOG

Home: Perl Programming Help: Beginner: Re: [rovf] Outputting from a terminal invocation: Edit Log

New User

Oct 17, 2012, 10:05 AM

Views: 2092
Re: [rovf] Outputting from a terminal invocation

You my friend are a legend!!

Your example worked fantastically and I was ecstatic, however, although this has worked in your example for some reason when I try:

sh -f -c "perl -lpe 's/L/l/g' test.txt > test_out.txt"
sh -f -c "perl -p -le 's/L/l/g' test.txt > test_out.txt"

I get nothing (although the perl lines work fine in the terminal directly). I'm guessing it has something to do with the need to add the "-p" in there but without that I get a blank output (in perl). I've also tried replacing the single quotes with double quotes but still nothing, not even a blank document where it's tried to make a file.

p.s. I also tried complete file paths /Users/username/text*.txt

(This post was edited by CR15P0 on Oct 17, 2012, 10:19 AM)

Edit Log:
Post edited by CR15P0 (New User) on Oct 17, 2012, 10:19 AM

Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives