Bug 1436725 - [lint] Remove obsolete eslintvalidate files, r?Standard8 draft
authorAndrew Halberstadt <ahalberstadt@mozilla.com>
Thu, 08 Feb 2018 09:25:14 -0500
changeset 752576 7249aa99bfe7ebfb7408b215d9c236833f711f57
parent 752511 0ac953fcddf10132eaecdb753d72b2ba5a43c32a
push id98299
push userahalberstadt@mozilla.com
push dateThu, 08 Feb 2018 15:13:52 +0000
reviewersStandard8
bugs1436725
milestone60.0a1
Bug 1436725 - [lint] Remove obsolete eslintvalidate files, r?Standard8 As the eslintvalidate linters haven't been doing anything but printing an error message for a month, this is just cleanup. MozReview-Commit-ID: 5dhrSmEv0Gi
tools/git/eslintvalidate.py
tools/git/git-lint-commit-hook.sh
tools/lint/flake8.yml
tools/lint/py2.yml
tools/lint/py3.yml
tools/mercurial/eslintvalidate.py
tools/moz.build
deleted file mode 100755
--- a/tools/git/eslintvalidate.py
+++ /dev/null
@@ -1,30 +0,0 @@
-#!/usr/bin/python
-# This software may be used and distributed according to the terms of the
-# GNU General Public License version 2 or any later version.
-
-import sys
-
-OBSOLETE = """
-ERROR: the eslintvalidate hook is obsolete. This commit went
-through, but ESlint didn't run. You can lint your changes
-after the fact by running:
-
-    $ mach lint --outgoing
-
-Please remove this hook and upgrade by following these
-instructions:
-https://firefox-source-docs.mozilla.org/tools/lint/usage.html#using-a-vcs-hook
-""".lstrip()
-
-
-def output(message):
-    print >> sys.stderr, message
-
-
-def eslint():
-    output(OBSOLETE)
-    return False
-
-
-if __name__ == '__main__':
-    eslint()
deleted file mode 100755
--- a/tools/git/git-lint-commit-hook.sh
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/sh
-
-# Simple wrapper to try and ensure we get the right python version loaded.
-which python2.7 > /dev/null
-
-if [ $? -eq 0 ]
-then
-  python2.7 ./tools/git/eslintvalidate.py
-else
-  python ./tools/git/eslintvalidate.py
-fi
-
-exit $?
--- a/tools/lint/flake8.yml
+++ b/tools/lint/flake8.yml
@@ -30,20 +30,18 @@ flake8:
         - testing/mozharness/mozinfo
         - testing/mozharness/scripts
         - testing/remotecppunittests.py
         - testing/runcppunittests.py
         - testing/talos/
         - testing/xpcshell
         - toolkit/components/telemetry
         - toolkit/crashreporter/tools/upload_symbols.py
-        - tools/git
         - tools/lint
         - tools/mach_commands.py
-        - tools/mercurial
         - tools/tryselect
     # Excludes should be added to topsrcdir/.flake8 due to a bug in flake8 where
     # specifying --exclude causes custom configuration files to be ignored.
     exclude: []
     # The configure option is used by the build system
     extensions: ['configure', 'py']
     type: external
     payload: python.flake8:lint
--- a/tools/lint/py2.yml
+++ b/tools/lint/py2.yml
@@ -45,21 +45,19 @@ py2:
         - testing/runcppunittests.py
         - testing/runtimes
         - testing/tools
         - testing/tps
         - testing/web-platform
         - third_party
         - toolkit
         - tools/docs
-        - tools/git/eslintvalidate.py
         - tools/jprof/split-profile.py
         - tools/lint
         - tools/mach_commands.py
-        - tools/mercurial/eslintvalidate.py
         - tools/power/mach_commands.py
         - tools/profiler
         - tools/rb
         - tools/update-packaging
         - xpcom
     extensions: ['py']
     type: external
     payload: python.compat:lintpy2
--- a/tools/lint/py3.yml
+++ b/tools/lint/py3.yml
@@ -33,17 +33,16 @@ py3:
         - testing/gtest
         - testing/mochitest
         - testing/mozharness
         - testing/tools/iceserver
         - testing/tps
         - testing/web-platform
         - third_party
         - toolkit
-        - tools/git
         - tools/jprof
         - tools/profiler
         - tools/rb
         - tools/update-packaging
         - xpcom/idl-parser
         - xpcom/typelib
     extensions: ['py']
     type: external
deleted file mode 100644
--- a/tools/mercurial/eslintvalidate.py
+++ /dev/null
@@ -1,23 +0,0 @@
-# This software may be used and distributed according to the terms of the
-# GNU General Public License version 2 or any later version.
-
-OBSOLETE = """
-ERROR: the eslintvalidate hook is obsolete. This commit went
-through, but ESlint didn't run. You can lint your changes
-after the fact by running:
-
-    $ mach lint --outgoing
-
-Please remove this hook and upgrade by following these
-instructions:
-https://firefox-source-docs.mozilla.org/tools/lint/usage.html#using-a-vcs-hook
-""".lstrip()
-
-
-def eslinthook(ui, repo, node=None, **opts):
-    ui.warn(OBSOLETE)
-    return False
-
-
-def reposetup(ui, repo):
-    ui.setconfig('hooks', 'commit.eslint', eslinthook)
--- a/tools/moz.build
+++ b/tools/moz.build
@@ -21,19 +21,16 @@ with Files("coverity/**"):
 
 with Files("docs/**"):
     BUG_COMPONENT = ("Core", "Build Config")
     SCHEDULES.exclusive = ['docs']
 
 with Files("lint/**"):
     BUG_COMPONENT = ("Testing", "Lint")
 
-with Files("mercurial/**"):
-    BUG_COMPONENT = ("Core", "Build Config")
-
 with Files("profiler/**"):
     BUG_COMPONENT = ("Core", "Gecko Profiler")
 
 with Files("quitter/**"):
     BUG_COMPONENT = ("Testing", "General")
 
 with Files("rb/**"):
     BUG_COMPONENT = ("Core", "XPCOM")