You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
687 B
Ruby
24 lines
687 B
Ruby
#!/usr/bin/env ruby
|
|
$:.unshift('vendor/ruby-mediawiki/lib')
|
|
require 'mediawiki/dotfile'
|
|
@wiki = MediaWiki.dotfile(nil,'entropia')
|
|
@putwhere = "Benutzer:Neinomat/"
|
|
@body = ""
|
|
|
|
@wiki.allpages.each do |title|
|
|
if @wiki.article(title).text.match("We are delicate. We do not delete your content.")
|
|
@body += "* [[#{title}]]\n"
|
|
end
|
|
|
|
# FIXME: We might better want to specify a namespace in MediaWiki::allpages
|
|
discussion_title = "Diskussion:#{title}"
|
|
|
|
if @wiki.article(discussion_title).text.match("We are delicate. We do not delete your content.")
|
|
@body += "* [[#{discussion_title}]]\n"
|
|
end
|
|
end
|
|
|
|
a = @wiki.article(@putwhere + "Spam-Artikel")
|
|
a.text = @body
|
|
a.submit("fnord")
|