ARaspberry523
ARaspberry523

Reputation: 1

How do I use pywikibot to clone one page into multiple other pages?

I need help copying the content of one page into multiple other pages using pywikibot. I.e. I wrote page 1 and I need page 2 and 3 to have the same content.

I tried reading the documentation, but I didn't find anything about doing that.

Upvotes: 0

Views: 32

Answers (1)

oli_vi_er
oli_vi_er

Reputation: 172

Why not use a template instead?

If you have a template, its content will be transcluded (embedded) on every page where it is used, and if you need to make any changes, all you have to do is edit the template, rather than dozens of pages. This is the recommended way of doing things on Wikipedia rather than using a bot.

If you really need to add the same content to different pages, I don't know about pywikibot, but I've already done it with the plug-in CSVLoader for AutoWikiBrowser.

You only need basic knowledge of regexes to use it, and you can append, prepend or replace text, and even create new pages with the desired content.

Upvotes: 0

Related Questions