Page MenuHomePhabricator

Unified extension registration mechanism for core/VE/Parsoid
Open, LowPublic0 Story Points

Description

There should be a way for extensions to bundle the needed support code for VE and Parsoid in the same directory structure they use for mediawiki core. "Installing" support in VE and Parsoid for a new extension should just be unzipping an extension in a specific directory. For small wikis where Parsoid and VE are on the same host, then you ought to be able to ln -s /var/www/mediawiki/extensions /opt/srv/parsoid/extensions and only unzip the extension once.

Once this is in place, we ought to document and evangelize this mechanism, perhaps with a simple"Hello, World" extension that shows how support for all three pieces is written.

(01:58:57 PM) cscott-free: James_F: is there a convention for how extensions register VE support yet?  that should be easier, it's in a single directory tree still.
(01:59:46 PM) James_F: cscott: Yeah, it's trivial. See the bottom of https://gerrit.wikimedia.org/r/#/c/284681/4/extension.json
(01:59:57 PM) James_F: cscott: Add yourself as a "VisualEditorPluginModules"
(02:00:03 PM) cscott-free: James_F: ok, a good start!

ps. if you use node-php-embed, you can run everything from one install dir and one process group. ;)

Details

Related Gerrit Patches:
mediawiki/services/parsoid : masterAllow extensions to handle specific contentmodels.
mediawiki/services/parsoid : masterAdd autoload mechanism for user extension code.

Event Timeline

cscott created this task.Apr 21 2016, 6:07 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptApr 21 2016, 6:07 PM
Arlolra triaged this task as Medium priority.Apr 21 2016, 6:24 PM

Change 284738 had a related patch set uploaded (by Cscott):
Add autoload mechanism for user extension code.

https://gerrit.wikimedia.org/r/284738

Jdforrester-WMF renamed this task from Unified extension registration mechanism for core/VE/Parsoid. to Unified extension registration mechanism for core/VE/Parsoid.Apr 25 2016, 7:12 PM
Jdforrester-WMF assigned this task to cscott.
Jdforrester-WMF lowered the priority of this task from Medium to Low.
Jdforrester-WMF set the point value for this task to 0.
Jdforrester-WMF moved this task from To Triage to TR0: Interrupt on the VisualEditor board.

Change 284738 merged by jenkins-bot:
Add autoload mechanism for user extension code.

https://gerrit.wikimedia.org/r/284738

Change 295707 had a related patch set uploaded (by Cscott):
Allow extensions to handle specific contentmodels.

https://gerrit.wikimedia.org/r/295707

Change 295707 merged by jenkins-bot:
Allow extensions to handle specific contentmodels.

https://gerrit.wikimedia.org/r/295707