Skip to content

Commit

Permalink
Vuepress removal /changes for vitepress (PX4#22972)
Browse files Browse the repository at this point in the history
* Vuepress removal /changes for vitepress

* generate_msg_docs.py - README is index in vitepress
  • Loading branch information
hamishwillee authored Apr 9, 2024
1 parent d8fabd1 commit f9c65cd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
2 changes: 0 additions & 2 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -171,10 +171,8 @@ pipeline {
sh('cp airframes.md PX4-user_guide/en/airframes/airframe_reference.md')
sh('cp parameters.md PX4-user_guide/en/advanced_config/parameter_reference.md')
sh('cp -R modules/*.md PX4-user_guide/en/modules/')
sh('cp -R graph_*.json PX4-user_guide/.vuepress/public/en/middleware/') // vuepress
sh('cp -R graph_*.json PX4-user_guide/public/middleware/') // vitepress
sh('cp -R msg_docs/*.md PX4-user_guide/en/msg_docs/')
sh('cp -R failsafe_sim/* PX4-user_guide/.vuepress/public/en/config/failsafe') // vuepress
sh('cp -R failsafe_sim/* PX4-user_guide/public/config/failsafe') // vitepress
sh('cd PX4-user_guide; git status; git add .; git commit -a -m "Update PX4 Firmware metadata `date`" || true')
sh('cd PX4-user_guide; git push origin main || true')
Expand Down
16 changes: 8 additions & 8 deletions Tools/msg/generate_msg_docs.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,13 @@ def get_msgs_list(msgdir):
with open(output_file, 'w') as content_file:
content_file.write(markdown_output)

readme_markdown_file_link='- [%s](%s.md)' % (msg_name,msg_name)
index_markdown_file_link='- [%s](%s.md)' % (msg_name,msg_name)
if summary_description:
readme_markdown_file_link+=" — %s" % summary_description
filelist_in_markdown+=readme_markdown_file_link+"\n"
index_markdown_file_link+=" — %s" % summary_description
filelist_in_markdown+=index_markdown_file_link+"\n"

# Write out the README.md file
readme_text="""# uORB Message Reference
# Write out the index.md file
index_text="""# uORB Message Reference
:::note
This list is [auto-generated](https://github.com/PX4/PX4-Autopilot/blob/main/Tools/msg/generate_msg_docs.py) from the source code.
Expand All @@ -98,6 +98,6 @@ def get_msgs_list(msgdir):
%s
""" % (filelist_in_markdown)
readme_file = os.path.join(output_dir, 'README.md')
with open(readme_file, 'w') as content_file:
content_file.write(readme_text)
index_file = os.path.join(output_dir, 'index.md')
with open(index_file, 'w') as content_file:
content_file.write(index_text)

0 comments on commit f9c65cd

Please sign in to comment.