User:RagesossBot/coursesupportlinker.py: Difference between revisions

Content deleted Content added
source cdoe
 
m top: Replaced deprecated <source> tags with <syntaxhighlight>
 
(One intermediate revision by one other user not shown)
Line 1:
<sourcesyntaxhighlight lang="python">
#!/usr/bin/python
# -*- coding: utf-8 -*-
Line 74:
 
# Replace links to course pages, which start "[[Education Program:", with the {{course link}} template.
text = re.sub(ur'\[\[Education( |_)Program:(.+?)\]\]', ur'{{course link|Education Program:\12}}', text)
 
if not self.save(text, page, self.summary):
Line 177:
finally:
pywikibot.stopme()
</syntaxhighlight>
</source>