Warning: You take full responsibility for any action you perform using Unpipe. You must read and understand Wikipedia policies and use this tool within these policies, or risk being blocked from editing. |
Description | Converts each piped link to a non-piped one if both lead to the same article |
---|---|
Updated | June 10, 2024 (4 months ago) |
Browsers | Chrome, Firefox, etc. (ES2017+ needed) |
Source | User:Nardog/Unpipe.js |
This script adds a button to the sidebar that converts piped links to non-piped ones where doing so does not change the destination of the link, to comply with WP:NOPIPE and WP:NOTBROKEN. That is, if both [[Foo|bar]]
and [[bar]]
lead to the same article or section directly or indirectly (i.e. through a redirect or not), the former is converted to the latter. Links to non-main namespaces and to redirects ending in " (disambiguation)" will not be replaced. The button is available only in source mode (not 2017 editor).
Installation
editAdd the following to your common.js:
mw.loader.load('//en.wikipedia.org/w/index.php?title=User:Nardog/Unpipe.js&action=raw&ctype=text/javascript');
Or you may enable the script installer in Preferences → Gadgets and click "Install" in the infobox on this page.
Acknowledgements
editThis script relies on Pathoschild's TemplateScript framework.