This repository has been archived by the owner on Aug 20, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathREADME
36 lines (27 loc) · 1.47 KB
/
README
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
This tool is currently a colossal hack. Proceed only with this in mind. ;-)
Everything here is released under the MIT license. See LICENSE for details.
Be sure to run "bundle install" so you get all the required gems.
Here is some code you can paste into "rails console" to test all the active
patches for MediaWiki core against a checkout of trunk/phase3 in /tmp/mw (this
code won't hurt the checkout but no warranties, etc.).
# Test all the active patches for MediaWiki core
s = Bugzilla::Site.new('https://bugzilla.wikimedia.org/')
bugs = s.search(:keywords=>'patch need-review',:keywords_type=>'allwords', :resolution=>'---', :product=>'MediaWiki'); bugs.size
bugs.each do |bug|
bug.active_patches.each do |patch|
result = patch.test('/tmp/mw')
puts "Bug: #{bug.id}; Patch: #{patch.id}; Status: #{result[:status]}; Strip: #{result[:strip]}; Path: #{result[:path]}"
end
end; 1
Currently, the only interesting code is under "extras/".
Basically I fetch pages with curb(libcurl) and pull out what I need with
nokogiri(libxml2) and some css selectors. Then I take each patch and attempt an
exhaustive search (after trying the easy cases) to see if it will apply.
I started with the Bugzilla API, but it was pretty annoying so I took the "easy"
route.
== Note on Patches/Pull Requests
* Fork the project.
* Make your feature addition or bug fix.
* Send me a pull request. Bonus points for topic branches.
== Copyright
Copyright (c) 2011 Rusty Burchfield. See LICENSE for details.