[go: up one dir, main page]

Page MenuHomePhabricator
Paste P186

wgFileExtensions mwgrep
ActivePublic

Authored by Legoktm on Dec 30 2014, 6:32 PM.
legoktm@terbium:~$ mwgrep "wgFileExtensions" --user
commonswiki User:Rillke/bigChunkedUpload.js
dewiki User:TMg/autoFormatter.js
dewiki User:TMg/autoFormatter.js/Beta.js
enwiki User:PerfektesChaos/js/DebugWikiGlobals/d.js
enwiki User:PerfektesChaos/js/DebugWikiGlobals/r.js
frwiki User:Dr Brains/CreatePortal.js
frwiki User:Dr Brains/MultiUpload.js
frwiki User:Dr Brains/MultiUploadUtils.js
hawiki User:Shrikarsan/format.js
hawiki User:Shrikarsan/shri.js
metawiki User:He7d3r/Tools/jsUpdater.js
metawiki User:He7d3r/global.js
(total: 12, shown: 12)

Event Timeline

Legoktm changed the title of this paste from untitled to wgFileExtensions mwgrep.
Legoktm updated the paste's language from autodetect to autodetect.

https://gerrit.wikimedia.org/r/182198/
I guess the authors of these 12 scripts could find a workaround till 13 January 2015. Thanks @Legoktm for pinging.

  • PerfektesChaos: völlig obsolet - obsolete script
  • Rillke: I think I'll find a fix in time.
  • Dr Brains: it have never been used (I'm not even sure they still work) and they are obsolete since UploadWizard is available; item of the list of obsolete variables

All other users should have been notified, either by the Gerrit change or by me directly.

In some cases (e.g. in my autoFormatter script) the "fix" is to duplicate the list of file extensions. Which raises an other problem: How do I keep my script and the setting in sync? And much worse: How should I know the allowed file extensions if my script is used in an other wiki? (May it be an other Wikimedia wiki or an external one. Yes, my script is used in external MediaWiki installations.)

I think this JS variable needs to be present on all wiki pages, at least in edit mode. There are scripts (like mine) that need to know which file extensions are valid in the [[File:, [[Media: and <gallery> syntax.

When a wiki is using a file repo and the file repo allows more file extensions than the wiki with your script, than the result maybe wrong, because the script rejects valid file usage (from the file repo).

@Umherirrender That's a good hint, thanks. However, I find having no access to any setting (may it be in sync with the file repo or not) worse.

Store the result of action=query&meta=siteinfo&siprop=fileextensions in some session storage; TTLs are available through jQuery.jStorage.