Gnus development mailing list
 help / color / mirror / Atom feed
* anti top-posting gnus-article-outlook-rearrange-citation fails for gmail. II
@ 2014-09-30 13:21 Uwe Brauer
  2015-01-27  3:03 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 3+ messages in thread
From: Uwe Brauer @ 2014-09-30 13:21 UTC (permalink / raw)
  To: ding

Hello

I debuged the relevant functions and the problem is 
in the function 
gnus-outlook-repair-attribution-outlook 

I have attached it below.

To be more specific the problem lies in the call: 


re-search-forward

For example in top-posting generated by apple mail 

	     nil t) returns a number, say 700

While in top-posting generated by gmail 

	     nil t) returns nil

However when I sent my self a mail using gmail this does not happen so
I am really desperate.

So that is why the rearrangement does not work. I just don't understand
why it returns nil for some gmail messages

(defun gnus-outlook-repair-attribution-outlook ()  ;this function is the problem with google
  "Repair a broken attribution line (Outlook)."
  (let ((case-fold-search nil)
	(inhibit-read-only t)
	(cite-marks gnus-outlook-deuglify-cite-marks))
    (gnus-with-article-buffer
      (article-goto-body)
      (when (re-search-forward
	     (concat "^\\([^" cite-marks "].+\\)"
		     "\\(" gnus-outlook-deuglify-attrib-verb-regexp "\\)"
		     "\\(.*\n?[^\n" cite-marks "].*\\)?"
		     "\\(" gnus-outlook-deuglify-attrib-end-regexp "\\)$")
	     nil t)
       ^^^^^^^^
	(gnus-kill-all-overlays)
	(replace-match "\\1\\2\\4")
	(match-beginning 0)))))


Uwe Brauer 




^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: anti top-posting gnus-article-outlook-rearrange-citation fails for gmail. II
  2014-09-30 13:21 anti top-posting gnus-article-outlook-rearrange-citation fails for gmail. II Uwe Brauer
@ 2015-01-27  3:03 ` Lars Ingebrigtsen
       [not found]   ` <87wq3kpkir.fsf@mat.ucm.es>
  0 siblings, 1 reply; 3+ messages in thread
From: Lars Ingebrigtsen @ 2015-01-27  3:03 UTC (permalink / raw)
  To: ding

Uwe Brauer <oub@mat.ucm.es> writes:

> I debuged the relevant functions and the problem is 
> in the function 
> gnus-outlook-repair-attribution-outlook 

[...]

> While in top-posting generated by gmail 
>
> 	     nil t) returns nil

Could you include an example mail that fails?

-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: anti top-posting gnus-article-outlook-rearrange-citation fails for gmail. II
       [not found]   ` <87wq3kpkir.fsf@mat.ucm.es>
@ 2015-02-18  1:07     ` Lars Ingebrigtsen
  0 siblings, 0 replies; 3+ messages in thread
From: Lars Ingebrigtsen @ 2015-02-18  1:07 UTC (permalink / raw)
  To: Uwe Brauer; +Cc: ding

Uwe Brauer <oub@mat.ucm.es> writes:

>> Could you include an example mail that fails?
>
> Here is an example (off-list) tell me whether I send it in a different
> format. I used 
> gnus-summary-write-article-file

I think it's basically this thing that fails to match the line below:

      (when (re-search-forward
	     (concat "^\\(" gnus-outlook-deuglify-attrib-cut-regexp "\\)?"
		     "\\([^" cite-marks "].+\\)\n\\([^\n" cite-marks "].*\\)?"
		     "\\(" gnus-outlook-deuglify-attrib-verb-regexp "\\).*"
		     "\\(" gnus-outlook-deuglify-attrib-end-regexp "\\)$")
	     nil t)

> El 13/2/2015, a las 17:27, Uwe Brauer <oub@mat.ucm.es> escribió:

Perhaps someone familiar with that code can tweak the regexps further...

-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-02-18  1:07 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-30 13:21 anti top-posting gnus-article-outlook-rearrange-citation fails for gmail. II Uwe Brauer
2015-01-27  3:03 ` Lars Ingebrigtsen
     [not found]   ` <87wq3kpkir.fsf@mat.ucm.es>
2015-02-18  1:07     ` Lars Ingebrigtsen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).