Commit debf6c85 authored by agable's avatar agable Committed by Commit bot

Remove gclient cleanup command

R=maruel@chromium.org
BUG=641588

Review-Url: https://codereview.chromium.org/2401483002
parent 7c61dcb3
......@@ -1562,24 +1562,6 @@ it or fix the checkout.
#### gclient commands.
def CMDcleanup(parser, args):
"""DEPRECATED: SVN-only. Cleaned up all working copies.
This is a no-op in Git.
"""
parser.add_option('--deps', dest='deps_os', metavar='OS_LIST',
help='override deps for the specified (comma-separated) '
'platform(s); \'all\' will process all deps_os '
'references')
(options, args) = parser.parse_args(args)
client = GClient.LoadCurrentConfig(options)
if not client:
raise gclient_utils.Error('client not configured; see \'gclient config\'')
if options.verbose:
client.PrintLocationAndContents()
return client.RunOnDeps('cleanup', args)
@subcommand.usage('[command] [args ...]')
def CMDrecurse(parser, args):
"""Operates [command args ...] on all the dependencies.
......
......@@ -143,7 +143,7 @@ class SCMWrapper(object):
print(*args, **kwargs)
def RunCommand(self, command, options, args, file_list=None):
commands = ['cleanup', 'update', 'updatesingle', 'revert',
commands = ['update', 'updatesingle', 'revert',
'revinfo', 'status', 'diff', 'pack', 'runhooks']
if not command in commands:
......@@ -270,13 +270,6 @@ class GitWrapper(SCMWrapper):
# time-stamp of the currently checked out revision.
return self._Capture(['log', '-n', '1', '--format=%ai'])
@staticmethod
def cleanup(options, args, file_list):
"""'Cleanup' the repo.
There's no real git equivalent for the svn cleanup command, do a no-op.
"""
def diff(self, options, _args, _file_list):
try:
merge_base = [self._Capture(['merge-base', 'HEAD', self.remote])]
......
......@@ -143,16 +143,6 @@ class GClientSmokeBase(fake_repos.FakeReposTestBase):
self.assertEquals(len(results), len(items), (stdout, items, len(results)))
return results
@staticmethod
def svnBlockCleanup(out):
"""Work around svn status difference between svn 1.5 and svn 1.6
I don't know why but on Windows they are reversed. So sorts the items."""
for i in xrange(len(out)):
if len(out[i]) < 2:
continue
out[i] = [out[i][0]] + sorted([x[1:].strip() for x in out[i][1:]])
return out
class GClientSmoke(GClientSmokeBase):
"""Doesn't require git-daemon."""
......@@ -179,7 +169,6 @@ class GClientSmoke(GClientSmokeBase):
def testNotConfigured(self):
res = ('', 'Error: client not configured; see \'gclient config\'\n', 1)
self.check(res, self.gclient(['cleanup']))
self.check(res, self.gclient(['diff']))
self.check(res, self.gclient(['pack']))
self.check(res, self.gclient(['revert']))
......@@ -265,7 +254,6 @@ class GClientSmoke(GClientSmokeBase):
self.assertTree({})
results = self.gclient(['revinfo'])
self.check(('./: None\n', '', 0), results)
self.check(('', '', 0), self.gclient(['cleanup']))
self.check(('', '', 0), self.gclient(['diff']))
self.assertTree({})
self.check(('', '', 0), self.gclient(['pack']))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment