Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(23)

Side by Side Diff: tools/site_compare/scrapers/firefox/__init__.py

Issue 8678023: Fix python scripts in src/tools/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixes Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 #!/usr/bin/python2.4 1 #!/usr/bin/env python
2 # 2 # Copyright (c) 2011 The Chromium Authors. All rights reserved.
3 # Copyright 2007 Google Inc. All Rights Reserved. 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
4 5
5 """Selects the appropriate scraper for Firefox.""" 6 """Selects the appropriate scraper for Firefox."""
6 7
7 __author__ = 'jhaas@google.com (Jonathan Haas)'
8
9 8
10 def GetScraper(version): 9 def GetScraper(version):
11 """Returns the scraper module for the given version. 10 """Returns the scraper module for the given version.
12 11
13 Args: 12 Args:
14 version: version string of IE, or None for most recent 13 version: version string of IE, or None for most recent
15 14
16 Returns: 15 Returns:
17 scrape module for given version 16 scrape module for given version
18 """ 17 """
19 18
20 # Pychecker will warn that the parameter is unused; we only 19 # Pychecker will warn that the parameter is unused; we only
21 # support one version of Firefox at this time 20 # support one version of Firefox at this time
22 21
23 # We only have one version of the Firefox scraper for now 22 # We only have one version of the Firefox scraper for now
24 return __import__("firefox2", globals(), locals(), ['']) 23 return __import__("firefox2", globals(), locals(), [''])
25 24
25
26 # if invoked rather than imported, test 26 # if invoked rather than imported, test
27 if __name__ == "__main__": 27 if __name__ == "__main__":
28 version = "2.0.0.6"
29
30 print GetScraper("2.0.0.6").version 28 print GetScraper("2.0.0.6").version
31
OLDNEW
« no previous file with comments | « tools/site_compare/scrapers/chrome/chromebase.py ('k') | tools/site_compare/scrapers/firefox/firefox2.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698