Re: binmode in perl -p oneliner Optionen

2011-05-29 Thread Thomas Liebezeit
Thank you, John and Uri. I got a hint to use -e "binmode ARGVOUT" and it did the trick for me! JWK> BTW your substitution operator replaces only the first 'A' it finds JWK> with 'B'. If you want to replace all 'A's with 'B's then you have to JWK> use the /g option on the substitution: s/A/B/g.

binmode in perl -p oneliner Optionen

2011-05-28 Thread Thomas Liebezeit
Hello, I'm triying to do some substitutions on an pdf file. perl -p -i~ -w -e "s/A/B/;" file.pdf This works as intended, except: perl adds 0x0D (Windows \n) :-/ as a HEX diff shows. How can I work around this? Is there something like binmode()? cheers Thomas -- To unsubscribe, e-mail: