Difference between revisions of "Change user in XML export"
From Organic Design wiki
(Perl snippet) |
(Fix regex accounting for <id> tags too) |
||
Line 5: | Line 5: | ||
}} | }} | ||
− | The Usernames are specified in the <nowiki><username></nowiki> tag, by default an xml export | + | The Usernames are specified in the <nowiki><username></nowiki> tag, by default an xml export usually dumps the current revision not the history of an article; |
{{code|<PHP> | {{code|<PHP> | ||
− | perl -ne ' | + | perl -ne 'ss/(\<username\>)\w+(\<\/username\>\s+\<id\>)\d+(\<\/id\>)/${1}WikiSysop${2}1${3}/g ; print ' IN.xml > OUT.xml |
</PHP> | </PHP> | ||
}} | }} |