public inbox for gnats-devel@sourceware.org
 help / color / mirror / Atom feed
From: "Dirk Bergstrom" <dirk@juniper.net>
To: <help-gnats@gnu.org>
Subject: RE: Subject line processing in Gnats 4.0
Date: Fri, 02 Nov 2001 05:49:00 -0000	[thread overview]
Message-ID: <C53744A44FBC9B4BAE90EB41D2C09AC2052242@proton.jnpr.net> (raw)

paul traina writes:
> Negative Dirk,
> I had it behave that way before, and it sucked.  Every time 
> someone sent in anything like "OS/2" it would append it to PR #2.

mr. traina makes a good point (he does that rather often).  i had been wrestling with this, with no great success.  it's why the idea had been sitting in my files for months.  now that my memory has been jogged, i remember a couple of solutions i'd had in mind.  in order of increasing radicalism:

*) accept FW: as well as RE: -- change the subject pattern thusly:

- "(.*re[ \t]*(\\[[0-9]+\\])?:)?[ \t]*([-a-z0-9_+.]*[:/][ \t]*([0-9]+))"
+ "(.*(re|fwd?)[ \t]*(\\[[0-9]+\\])?:)?[ \t]*([-a-z0-9_+.]*[:/][ \t]*([0-9]+))"

this will require adjusting what parenthetical expression is saved out of the match.

*) gnats currently accepts things like "sw-foo: 1234" instead of "sw-foo/1234".  i'm guessing that the former is an antiquated form, since gnats doesn't emit it anymore.  people don't use it, but they *do* use "PR1234".  adjust the regex appropriately:

+ "(.*(re|fwd?)[ \t]*(\\[[0-9]+\\])?:)?[ \t]*(([-a-z0-9_+.]*/)|pr)([0-9]+))"

this will require some futher munging of code, since the stuff that pulls out and uses <category>/<number> will have to learn to contend with PR<number>.  since it really isn't necessary to use category to pull up the PR, it might be best to change the regex to save only the number, and not the category/number pair.  then we could just hack out the additional parsing code.

i think that the first change is the minimum we should do.

--
Dirk Bergstrom               dirk@juniper.net
_____________________________________________
Juniper Networks Inc.,          Computer Geek
Tel: 707.433.0564           Fax: 707.433.0769

_______________________________________________
Help-gnats mailing list
Help-gnats@gnu.org
http://mail.gnu.org/mailman/listinfo/help-gnats

WARNING: multiple messages have this Message-ID
From: "Dirk Bergstrom" <dirk@juniper.net>
To: <help-gnats@gnu.org>
Subject: RE: Subject line processing in Gnats 4.0
Date: Wed, 12 Dec 2001 14:20:00 -0000	[thread overview]
Message-ID: <C53744A44FBC9B4BAE90EB41D2C09AC2052242@proton.jnpr.net> (raw)
Message-ID: <20011212142000.5wW7zCCBduKjwvHcOBpYsfABu378SQKcBKcXa09Pac0@z> (raw)

paul traina writes:
> Negative Dirk,
> I had it behave that way before, and it sucked.  Every time 
> someone sent in anything like "OS/2" it would append it to PR #2.

mr. traina makes a good point (he does that rather often).  i had been wrestling with this, with no great success.  it's why the idea had been sitting in my files for months.  now that my memory has been jogged, i remember a couple of solutions i'd had in mind.  in order of increasing radicalism:

*) accept FW: as well as RE: -- change the subject pattern thusly:

- "(.*re[ \t]*(\\[[0-9]+\\])?:)?[ \t]*([-a-z0-9_+.]*[:/][ \t]*([0-9]+))"
+ "(.*(re|fwd?)[ \t]*(\\[[0-9]+\\])?:)?[ \t]*([-a-z0-9_+.]*[:/][ \t]*([0-9]+))"

this will require adjusting what parenthetical expression is saved out of the match.

*) gnats currently accepts things like "sw-foo: 1234" instead of "sw-foo/1234".  i'm guessing that the former is an antiquated form, since gnats doesn't emit it anymore.  people don't use it, but they *do* use "PR1234".  adjust the regex appropriately:

+ "(.*(re|fwd?)[ \t]*(\\[[0-9]+\\])?:)?[ \t]*(([-a-z0-9_+.]*/)|pr)([0-9]+))"

this will require some futher munging of code, since the stuff that pulls out and uses <category>/<number> will have to learn to contend with PR<number>.  since it really isn't necessary to use category to pull up the PR, it might be best to change the regex to save only the number, and not the category/number pair.  then we could just hack out the additional parsing code.

i think that the first change is the minimum we should do.

--
Dirk Bergstrom               dirk@juniper.net
_____________________________________________
Juniper Networks Inc.,          Computer Geek
Tel: 707.433.0564           Fax: 707.433.0769

_______________________________________________
Help-gnats mailing list
Help-gnats@gnu.org
http://mail.gnu.org/mailman/listinfo/help-gnats

             reply	other threads:[~2001-12-12 22:20 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-11-02  5:49 Dirk Bergstrom [this message]
2001-11-03  1:41 ` Paul Traina
2001-12-13  9:50   ` Paul Traina
2001-11-06  5:19 ` Milan Zamazal
2001-12-13 14:39   ` Milan Zamazal
2001-12-12 14:20 ` Dirk Bergstrom
  -- strict thread matches above, loose matches on Subject: below --
2001-11-06  5:58 Dirk Bergstrom
2001-11-09 14:17 ` Milan Zamazal
2001-11-19  0:36   ` Milan Zamazal
2001-12-23 12:36     ` Milan Zamazal
2001-12-15  7:24   ` Milan Zamazal
2001-12-13 15:09 ` Dirk Bergstrom
2001-11-01 15:18 Dirk Bergstrom
2001-12-12 13:03 ` Dirk Bergstrom
2001-11-01  7:16 Dirk Bergstrom
2001-11-01  7:18 ` Paul Traina
2001-11-01 14:36   ` Michael Richardson
2001-12-12 11:55     ` Michael Richardson
2001-12-11 21:45   ` Paul Traina
2001-11-02  5:50 ` Milan Zamazal
2001-11-02  5:57   ` Michael Richardson
2001-12-12 15:43     ` Michael Richardson
2001-11-04  0:17   ` Yngve Svendsen
2001-12-13 12:30     ` Yngve Svendsen
2001-11-06  7:43   ` Chad C. Walstrom
2001-11-10  8:07     ` Milan Zamazal
2001-12-15  7:24       ` Milan Zamazal
2001-12-13 21:36     ` Chad C. Walstrom
2001-12-12 15:06   ` Milan Zamazal
2001-12-11 18:12 ` Dirk Bergstrom
2001-10-28 13:34 Michael Richardson
2001-10-29 17:36 ` Milan Zamazal
2001-12-09  6:33   ` Milan Zamazal
2001-12-07 14:27 ` Michael Richardson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=C53744A44FBC9B4BAE90EB41D2C09AC2052242@proton.jnpr.net \
    --to=dirk@juniper.net \
    --cc=help-gnats@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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 read-only IMAP folder(s) and NNTP newsgroup(s).