Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. | |
| 2 # Use of this source code is governed by a BSD-style license that can be | |
| 3 # found in the LICENSE file. | |
| 4 | |
| 5 import sys | |
| 6 | |
| 7 | |
| 8 def GetOSName(platform_name=sys.platform): | |
| 9 if platform_name == 'cygwin' or platform_name.startswith('win'): | |
| 10 return 'win' | |
| 11 elif platform_name.startswith('linux'): | |
| 12 return 'unix' | |
| 13 elif platform_name.startswith('darwin'): | |
| 14 return 'mac' | |
| 15 else: | |
| 16 return platform_name | |
| 17 | |
| 18 | |
| 19 def IsSvnRevision(revision): | |
| 20 revision = str(revision) | |
| 21 return len(revision) < 8 and revision.isdigit() | |
|
Martin Barbella
2014/07/16 20:50:49
This seems hacky.
stgao
2014/07/22 00:35:46
Yes, it is a little hacky. But I can't think out a
| |
| OLD | NEW |