Skip to content

Commit a070327

Browse files
author
Clemens Mandl
committed
Small Refactoring of variable definitions and removed some unnecessary brackets
1 parent 212e566 commit a070327

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

tools/export/nb/__init__.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,8 @@ def validate_resources(self):
123123
raise NotSupportedException("No linker script found.")
124124

125125
def create_jinja_ctx(self):
126-
126+
self.options = {}
127+
flags = {}
127128
self.validate_resources()
128129
# Convert all Backslashes to Forward Slashes
129130
self.resources.win_to_unix()
@@ -141,8 +142,6 @@ def create_jinja_ctx(self):
141142

142143
profile_ids = [s.lower() for s in profiles]
143144
profile_ids.sort()
144-
145-
self.options = {}
146145
for prof_id in profile_ids:
147146
# There are 4 categories of options, a category common too
148147
# all tools and a specific category for each of the tools.
@@ -231,7 +230,6 @@ def create_jinja_ctx(self):
231230
'ld_flags': self.flags['ld_flags'],
232231
'asm_flags': self.flags['asm_flags'],
233232
'common_flags': self.flags['common_flags'],
234-
'target': self.target,
235233
'include_paths': include_paths,
236234
'forced_includes': forced_includes,
237235
'c_sources': c_sources,
@@ -305,11 +303,12 @@ def get_all_profiles():
305303

306304
@staticmethod
307305
def get_netbeans_file_list(file_list):
308-
output = []
306+
cur_dir = ''
309307
prev_dir = ''
308+
output = []
310309
folder_count = 1
311310
dir_depth = 0
312-
for item in (file_list):
311+
for item in file_list:
313312
cur_dir = os.path.dirname(item)
314313
dir_temp = os.path.normpath(cur_dir)
315314
prev_dir_temp = os.path.normpath(prev_dir)

0 commit comments

Comments
 (0)