Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TIMOB-9283] Tooling: Symlinks are ignored compiling on device #2715

Merged
merged 2 commits into from
Aug 13, 2012
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion support/android/android.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def pipe(args1,args2):
def copy_resources(source, target):
if not os.path.exists(os.path.expanduser(target)):
os.mkdir(os.path.expanduser(target))
for root, dirs, files in os.walk(source):
for root, dirs, files in os.walk(source, True, None, True):
for name in ignoreDirs:
if name in dirs:
dirs.remove(name) # don't visit ignored directories
Expand Down
6 changes: 3 additions & 3 deletions support/android/builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ def error(msg):

def copy_all(source_folder, dest_folder, ignore_dirs=[], ignore_files=[], ignore_exts=[], one_time_msg=""):
msg_shown = False
for root, dirs, files in os.walk(source_folder):
for root, dirs, files in os.walk(source_folder, True, None, True):
for d in dirs:
if d in ignore_dirs:
dirs.remove(d)
Expand Down Expand Up @@ -1252,7 +1252,7 @@ def generate_stylesheet(self):
if not os.path.exists(app_stylesheet):
update_stylesheet = True
else:
for root, dirs, files in os.walk(resources_dir):
for root, dirs, files in os.walk(resources_dir, True, None, True):
remove_ignored_dirs(dirs)
for f in files:
if f in ignoreFiles:
Expand Down Expand Up @@ -1456,7 +1456,7 @@ def zip_contains(zip, entry):
apk_zip.write(self.classes_dex, 'classes.dex')

# add all resource files from the project
for root, dirs, files in os.walk(self.project_src_dir):
for root, dirs, files in os.walk(self.project_src_dir, True, None, True):
remove_ignored_dirs(dirs)
for f in files:
if f in ignoreFiles:
Expand Down
2 changes: 1 addition & 1 deletion support/android/compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ def compile(self, compile_bytecode=True, info_message="Compiling Javascript Reso
if info_message:
print "[INFO] %s" % info_message
sys.stdout.flush()
for root, dirs, files in os.walk(self.project_dir):
for root, dirs, files in os.walk(self.project_dir, True, None, True):
for dir in dirs:
if dir in ignoreDirs:
dirs.remove(dir)
Expand Down
4 changes: 2 additions & 2 deletions support/iphone/builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ def infoplist_has_appid(f,appid):
def copy_module_resources(source, target, copy_all=False, force=False):
if not os.path.exists(os.path.expanduser(target)):
os.makedirs(os.path.expanduser(target))
for root, dirs, files in os.walk(source):
for root, dirs, files in os.walk(source, True, None, True):
for name in ignoreDirs:
if name in dirs:
dirs.remove(name) # don't visit ignored directories
Expand Down Expand Up @@ -184,7 +184,7 @@ def make_map(dict):
def dump_resources_listing(rootdir,out):
out.write("\nFile listing for %s\n\n" % rootdir)
total = 0
for root, subFolders, files in os.walk(rootdir):
for root, subFolders, files in os.walk(rootdir, True, None, True):
for file in files:
p = os.path.join(root,file)
s = os.path.getsize(p)
Expand Down
4 changes: 2 additions & 2 deletions support/iphone/compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ def compile_module(self):
root_asset = self.compile_commonjs_file(self.appid+'.js', os.path.join(self.assets_dir, self.appid+'.js'))

js_files = []
for root, dirs, files in os.walk(self.assets_dir):
for root, dirs, files in os.walk(self.assets_dir, True, None, True):
for file in [f for f in files if os.path.splitext(f)[1] == '.js']:
full_path = os.path.join(root, file)
self.compile_js_file(os.path.relpath(full_path, self.assets_dir), full_path, js_files)
Expand Down Expand Up @@ -615,7 +615,7 @@ def compile_js_files():
def add_compiled_resources(source,target):
print "[DEBUG] copy resources from %s to %s" % (source,target)
compiled_targets = {}
for root, dirs, files in os.walk(source):
for root, dirs, files in os.walk(source, True, None, True):
for name in ignoreDirs:
if name in dirs:
dirs.remove(name) # don't visit ignored directories
Expand Down
2 changes: 1 addition & 1 deletion support/iphone/projector.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ def process_file(self,source,target,cb=None):
def copy_module_resources(self, source, target):
if not os.path.exists(os.path.expanduser(target)):
os.mkdir(os.path.expanduser(target))
for root, dirs, files in os.walk(source):
for root, dirs, files in os.walk(source, True, None, True):
for name in ignoreDirs:
if name in dirs:
dirs.remove(name) # don't visit ignored directories
Expand Down