gecko-dev/toolkit
Dave Townsend 56d83fc4bd Bug 1245916: Unify eslint global discovery rules. r=pbrosset
While working on turning on no-undef I discovered that the various rules we
have for defining globals are a little inconsistent in whether the files they
load recurse through import-globals-from directives and none of them imported
eslint globals directives.

I think we're better off putting all this global parsing code in a single place
rather than spread across multiple rules. Have one rule to turn it on for
parsed files and one function to load globals from other files and make them
share most of the code so we won't get inconsistent. If we find us needing to
turn on/off individual features we can figure out a way to do that in the
future.

This patch does that, the globals.js file does all global parsing with a shared
object that receives events from the AST, either through from an ESlint rule
or from a simple AST walker using estraverse.

MozReview-Commit-ID: 9KQZwsNNOUl

--HG--
extra : rebase_source : 0f1cceca29ac398be97a55bbcd09fe58a8be1435
extra : source : 878db4caf845282f06542793bc4b5c24fa658c14
2016-02-05 11:37:50 -08:00
..
components Bug 1245916: Unify eslint global discovery rules. r=pbrosset 2016-02-05 11:37:50 -08:00
content Merge m-i to m-c, a=merge 2016-02-13 19:18:53 -08:00
crashreporter Followup for bug 1069556: Remove what was removed in bug 1245055. r=me 2016-02-10 10:16:07 +09:00
forgetaboutsite Bug 1189998, Part 2 - Migrate Push service callers. r=mt 2015-12-08 15:41:48 -05:00
identity Bug 1245649: Turn on no-extra-semi. r=markh 2016-02-03 17:27:36 -08:00
library Bug 1234092: P1. Remove GStreamer support. r=kentuckyfriedtakahe 2015-12-23 01:14:22 +11:00
locales Bug 524757 - "Add architecture and operating system to about:support". r=adw 2016-02-09 15:57:00 +01:00
modules merge mozilla-inbound to mozilla-central a=merge 2016-02-12 15:15:17 +01:00
mozapps Bug 1232222 - expose isSystem flag if add-on is a system add-on r=Mossop 2016-02-13 17:51:21 -08:00
obsolete Bug 1245649: Turn on no-trailing-spaces. r=Gijs 2016-02-03 14:22:33 -08:00
pluginproblem Bug 1195162 - Move mozapps/plugins into pluginproblem (r=sicking,bsmedberg) 2015-09-14 19:08:06 -07:00
profile Bug 1245649: Turn on no-trailing-spaces. r=Gijs 2016-02-03 14:22:33 -08:00
system Bug 1243312 - nsNetCID is missing in toolkit/system/unixproxy/nsLibProxySettings.cpp. r=jduell 2016-01-27 01:47:00 +01:00
themes Bug 1206560 - Show the site favicon in XUL notifications. r=jaws 2016-01-08 12:53:34 -07:00
webapps Bug 1238576 - disable mozApps API on desktop/Android; r=ehsan,ochameau,bz,mcmanus,jmaher,marco 2016-02-08 11:24:22 -08:00
xre merge mozilla-inbound to mozilla-central a=merge 2016-02-12 15:15:17 +01:00
.eslintrc Bug 1245649: Enable no-nested-ternary. r=mconley 2016-02-03 21:17:16 -08:00
moz.build Backout 24dbe7da7370:a319694b46d5 (bug 1069556) for build bustage on various platforms on a CLOSED TREE 2016-01-29 11:55:43 -05:00
toolkit.mozbuild Bug 1239866 - Remove signaling standalone tests. r=bwc 2016-01-15 12:18:39 -08:00