mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-11-06 04:41:36 +08:00
px4airframes markdown: always use '/' for path separation
Because it's an URL and os.path.join() will use '\' on windows.
This commit is contained in:
@@ -17,6 +17,8 @@ class MarkdownTablesOutput():
|
|||||||
|
|
||||||
type_set = set()
|
type_set = set()
|
||||||
|
|
||||||
|
if len(image_path) > 0 and image_path[-1] != '/':
|
||||||
|
image_path = image_path + '/'
|
||||||
|
|
||||||
for group in groups:
|
for group in groups:
|
||||||
if group.GetClass() not in type_set:
|
if group.GetClass() not in type_set:
|
||||||
@@ -29,7 +31,7 @@ class MarkdownTablesOutput():
|
|||||||
image_name = group.GetImageName()
|
image_name = group.GetImageName()
|
||||||
result += '<div>\n'
|
result += '<div>\n'
|
||||||
if image_name != 'AirframeUnknown':
|
if image_name != 'AirframeUnknown':
|
||||||
image_name = os.path.join(image_path, image_name)
|
image_name = image_path + image_name
|
||||||
result += '<img src="%s.svg" width="29%%" style="max-height: 180px;"/>\n' % (image_name)
|
result += '<img src="%s.svg" width="29%%" style="max-height: 180px;"/>\n' % (image_name)
|
||||||
|
|
||||||
# check if all outputs are equal for the group: if so, show them
|
# check if all outputs are equal for the group: if so, show them
|
||||||
|
|||||||
Reference in New Issue
Block a user