Bug 1293493 - Remove `mach rage` since it was unused; r=ted
authorGregory Szorc <gps@mozilla.com>
Mon, 24 Apr 2017 16:33:51 -0700
changeset 355061 87efe1f55cdfd0491a5700375186a82f9050adba
parent 355060 1cab6bbbe25ac440cafa7ac67b63e622a11596aa
child 355062 03a3ed5fbce14c38e0b2bd452b6aed182dfcd957
push id41562
push usergszorc@mozilla.com
push dateWed, 26 Apr 2017 22:49:15 +0000
treeherderautoland@87efe1f55cdf [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersted
bugs1293493
milestone55.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1293493 - Remove `mach rage` since it was unused; r=ted We've had 4 submissions in 2017. jgriffin and I agreed that it was a failed experiment and we should either abandon it or figure out how to increase participation. Since nobody is available to improve it, I'm inclined to just delete it. If we want to bring it back, it is always in version control. MozReview-Commit-ID: AizkZxjQ8IJ
tools/mach_commands.py
--- a/tools/mach_commands.py
+++ b/tools/mach_commands.py
@@ -4,17 +4,16 @@
 
 from __future__ import absolute_import, unicode_literals
 
 import sys
 import os
 import stat
 import platform
 import errno
-import subprocess
 
 from mach.decorators import (
     CommandArgument,
     CommandProvider,
     Command,
 )
 
 from mozbuild.base import MachCommandBase, MozbuildObject
@@ -76,69 +75,16 @@ class UUIDProvider(object):
         if format in [None, 'cpp', 'c++']:
             u = u.hex
             print('{ 0x%s, 0x%s, 0x%s, \\' % (u[0:8], u[8:12], u[12:16]))
             pairs = tuple(map(lambda n: u[n:n+2], range(16, 32, 2)))
             print(('  { ' + '0x%s, ' * 7 + '0x%s } }') % pairs)
 
 
 @CommandProvider
-class RageProvider(MachCommandBase):
-    @Command('rage', category='misc',
-             description='Express your frustration')
-    def rage(self):
-        """Have a bad experience developing Firefox? Run this command to
-        express your frustration.
-
-        This command will open your default configured web browser to a short
-        form where you can submit feedback. Just close the tab when done.
-        """
-        import getpass
-        import urllib
-        import webbrowser
-
-        # Try to resolve the current user.
-        user = None
-        with open(os.devnull, 'wb') as null:
-            if os.path.exists(os.path.join(self.topsrcdir, '.hg')):
-                try:
-                    user = subprocess.check_output(['hg', 'config',
-                                                    'ui.username'],
-                                                   cwd=self.topsrcdir,
-                                                   stderr=null)
-
-                    i = user.find('<')
-                    if i >= 0:
-                        user = user[i + 1:-2]
-                except subprocess.CalledProcessError:
-                    pass
-            elif os.path.exists(os.path.join(self.topsrcdir, '.git')):
-                try:
-                    user = subprocess.check_output(['git', 'config', '--get',
-                                                    'user.email'],
-                                                   cwd=self.topsrcdir,
-                                                   stderr=null)
-                except subprocess.CalledProcessError:
-                    pass
-
-        if not user:
-            try:
-                user = getpass.getuser()
-            except Exception:
-                pass
-
-        url = 'https://docs.google.com/a/mozilla.com/forms/d/e/1FAIpQLSeDVC3IXJu5d33Hp_ZTCOw06xEUiYH1pBjAqJ1g_y63sO2vvA/viewform'  # noqa: E501
-        if user:
-            url += '?entry.1281044204=%s' % urllib.quote(user)
-
-        print('Please leave your feedback in the opened web form')
-        webbrowser.open_new_tab(url)
-
-
-@CommandProvider
 class PastebinProvider(object):
     @Command('pastebin', category='misc',
              description='Command line interface to pastebin.mozilla.org.')
     @CommandArgument('--language', default=None,
                      help='Language to use for syntax highlighting')
     @CommandArgument('--poster', default='',
                      help='Specify your name for use with pastebin.mozilla.org')
     @CommandArgument('--duration', default='day',