Skip to content

Commit 681861e

Browse files
committed
Fix paths to be relative to write directory
1 parent bd2fce7 commit 681861e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/techui_builder/builder.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ def _get_macros(element: ObjectifiedElement):
204204
if visited is None:
205205
visited = set()
206206

207-
current_node = JsonMap(str(screen_path.name))
207+
current_node = JsonMap(str(screen_path.relative_to(self._write_directory)))
208208

209209
abs_path = screen_path.absolute()
210210
dest_path = dest_path
@@ -262,7 +262,7 @@ def _get_macros(element: ObjectifiedElement):
262262
next_file_path, dest_path, visited
263263
)
264264
else:
265-
child_node = JsonMap(str(file_path.name), exists=False)
265+
child_node = JsonMap(str(file_path), exists=False)
266266

267267
child_node.macros = macro_dict
268268
# TODO: make this work for only list[JsonMap]

0 commit comments

Comments
 (0)