in reply to Re: File editing
in thread File editing
Wow ... peek into my brain as I look at your code above:
Even if you did assign your diamond operator to a variable, you're still going to accidentally let the first line of the file through, because it's already been pulled out by the implicit while (<>) { ... } continue { print } that the -p switch gives you. Basically, using the diamond operator inside of a -p or -n script is going to do strange things. I'd avoid it. See my note further down on a non-confusing way to do this :-)
-dlc
|
|---|