bower2buck: Fix import to follow Google's Python Style Guide
The Imports section of the style guide [1] says imports should only be used for packages and modules. [1] https://google.github.io/styleguide/pyguide.html?showone=Imports#Imports Change-Id: Id293cc0a0243d7f4943fe5b7645f8798633c3423
This commit is contained in:
@@ -26,7 +26,7 @@ import subprocess
|
||||
import sys
|
||||
import tempfile
|
||||
|
||||
from tools.js.bowerutil import hash_bower_component
|
||||
from tools.js import bowerutil
|
||||
|
||||
# This script is run with `buck run`, but needs to shell out to buck; this is
|
||||
# only possible if we avoid buckd.
|
||||
@@ -77,7 +77,7 @@ class Rule(object):
|
||||
self.version = bower_json['version']
|
||||
self.deps = bower_json.get('dependencies', {})
|
||||
self.license = bower_json.get('license', 'NO LICENSE')
|
||||
self.sha1 = hash_bower_component(
|
||||
self.sha1 = bowerutil.hash_bower_component(
|
||||
hashlib.sha1(), os.path.dirname(bower_json_path)).hexdigest()
|
||||
|
||||
def to_rule(self, packages):
|
||||
|
Reference in New Issue
Block a user