Commit f40fbb3b authored by maruel@chromium.org's avatar maruel@chromium.org

Make 'gcl diff emptychange' show nothing if given change, |emptychange|, doesn't contain files.

BUG=27243
TEST=Create change which contains no files and confirm 'gcl diff createdchange' doesn't output anything.

M      gcl.py

Review URL: http://codereview.chromium.org/388001

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@31551 0039d316-1c4b-4281-b951-d872f2087c98
parent 73171904
......@@ -1283,6 +1283,8 @@ def main(argv=None):
else:
# Everything else that is passed into gcl we redirect to svn, after adding
# the files. This allows commands such as 'gcl diff xxx' to work.
if command == "diff" and not change_info.GetFileNames():
return 0
args =["svn", command]
root = GetRepositoryRoot()
args.extend([os.path.join(root, x) for x in change_info.GetFileNames()])
......
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