Re: repairing the From: headers of sed-users ...
| Newsgroups | gmane.editors.sed.user |
|---|---|
| Message-ID | <20150101215026.GA3909@rpi> |
> On 01Jan2015 09:27, Cameron Simpson <[email protected]> wrote: > >As I'm sure you're all aware, Yahoo Groups began mangling our From: > >headers last year to be from the list, not the author, because Yahoo > >moved to DKIM validation. [...] > >This sed script is here: > > https://bitbucket.org/cameron_simpson/css/src/tip/bin/fix-dkim-from > >will under to From: header, producing a correct original author. [...] I am having trouble with the first y command. Note that I have changed the list name and list server as this should fit any mailing list that uses DKIM, from what I see in your script itself: bash# echo 'From: "Sender Name [email protected]" <[email protected]>' | sed -f fix-dkim-from.sed sed: file fix-dkim-from.sed line 61: strings for `y' command are different lengths bash# grep -w y fix-dkim-from.sed y/ / / y/\n/ / bash# Any idea what I am doing wrong, or what is wrong with my copy of the script? I just quoted the From line above as an example, I get the same error message when I do: cat email/filename | sed -f fix.dkim-from.sed I did have trouble navigating bitbucket, and ended up printing a copy of the html page. Then I went back and got the gzip version of the script, and when I run that as above, there is no error, but I get no output, whether I just echo the From line, or process the whole email. Is that because the first line of the script is: #!/usr/bin/sed -nf When I remove the -nf, I still get no output?? As in, the script runs quietly and all I see as the result is a bash prompt. Thanks, Eliana