~vcs-imports/bts-lin/trunk

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
Documentation for bts-link is in htdocs/index.html (cd htdocs && make)



Commands :
 * btsinfo : displays infos about a (remote) bug status from its URL
 
 * bin/btslink-spoolindex.sh [-v] .../wherever/bts-link/db-h : to get a copy of 
   the debbugs database under directory .../wherever/bts-link/db-h/ to be processed by 'btspull'
 
 * $ ./btspull nnnnnn :  sends a mail to the Debian BTS updating the status of the 
   upstream bugs for all bugs having a forwarded-to attribute.
   The mail sent to debbugs contains commands in the form of :

	From: theuser@running-btslink.com
	To: control@bugs.debian.org
	Cc: theuser@running-btslink.com, phpgroupware@packages.debian.org
	Subject: [bts-link] source package phpgroupware
	X-BTS-Link: phpgroupware
	Reply-To: bts-link-devel@lists.alioth.debian.org
	
	#
	# bts-link upstream status pull for source package phpgroupware
	# see http://lists.debian.org/debian-devel-announce/2006/05/msg00001.html
	#
	
	user bts-link-upstream@lists.alioth.debian.org
	
	# remote status report for #504255
	#  * http://savannah.gnu.org/bugs/?func=detailitem&item_id=24725
	#  * remote status changed: (?) -> Open
	usertags 504255 + status-Open
	
	thanks
   
   Here, such an email will be processed in order to add a bts-link usertag to 
   #504255 (a phpgroupware bug) which declares the remote bug 24725 as opened.
 
 * bin/btspull-debugrun.sh : will test the btspull processing without actually 
   sending the emails. Helps debug any problems.

Contents of btslink.cfg :
=========================

General configuration values
----------------------------
 - general.spool : mirror of the DBTS database
 - general.ldap : URL of the LDAP database for the BTS (see http://oldpeople.debian.org/~aba/bts2ldap/)

Example :
[general]
spool    = .../bts-link/db-h
ldap     = ldap://bts2ldap.debian.net:10101

Bugtracker configuration properties
-----------------------------------
For each bugtracker, several configuration values can be defined :
 - type : the bugtracker's type (berlios, bugzilla, gnats, launchpad, mantis, rt, savane, sourceforge, trac, gforge, jira, or redmine)
 - uri : the base URL of the bugtracker
 - uri-re (optional) : a regexp describing the bugtracker's bugs URLs isolating the bug number/id 
  
Example :

[name_of_bugtracker]
type	= bugtracker_type
uri		= http://this.bugtracker.com/tracker/
uri-re	= http://this.bugtracker.com/tracker/(?:index.php|)\?(?:.*&)*aid=([0-9]+)



Here I add some info from MadCoder about bts-link
=================================================

- how to exec the tool:
    ./bin/btslink-spoolindex.sh -v ../db-h && DEBEMAIL=bts-link-upstream@lists.alioth.debian.org ./bin/btspull-run.sh -s
    (from within the bts-link dir)

TODO:
-----

2009-01-07 17:32:22 <MadCoder>  though it may not be that useful anymore with the SOAP interface IIRC
2009-01-07 17:32:36 <MadCoder>  I don't remember if it's useful at all nowdayas
2009-01-07 17:32:55 <morph_>    I don't know if the SOAP int will allow to query only those bugs forwarded
2009-01-07 17:33:20 <MadCoder>  but maybe asking don to allow such a request to be done would simplify bts-link usage greatly
2009-01-07 17:33:34 <morph_>    absolutely

-*-

since we pass to btspull only the bug numbers, we can only store them into index.fwd

Warning:
--------

2009-01-07 17:34:44 <MadCoder>  the webscrapping sucks

-*-

2009-01-07 17:35:30 <MadCoder>  it forks wgets because the urllib from python didn't work at the time on many Bugzillas for some reason
2009-01-07 17:35:49 <MadCoder>  (probably missing headers who knows)
2009-01-07 17:36:10 <MadCoder>  though, wrt your ADSL line, beware, some BTS admin suck big time and may blacklist you
2009-01-07 17:36:24 <MadCoder>  my work IP was blacklisted from bugzilla.gnome.org because of that e.g.

-*-

2009-01-07 17:40:36 <MadCoder>  (and bts-link-commits needs cleansing, better ask on #alioth)
2009-01-07 17:40:59 <MadCoder>  also, you probably want to streamline the ML use and configuration (they suck, but I dislike mailman and never fixed that for real)
2009-01-07 17:41:15 <MadCoder>  e.g. it'd be better not to use bts-link-devel for the bts-link automatic mails
2009-01-07 17:41:38 <MadCoder>  and I think many of them go there
2009-01-07 17:41:59 <morph_>    yeah, I'm taking notes
2009-01-07 17:42:06 <MadCoder>  bts-link-upstream@ is the user-tag IIRC