API reference generator #926
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: API reference generator | |
on: | |
workflow_dispatch: | |
inputs: | |
name: | |
description: "Manual trigger" | |
schedule: | |
- cron: '0 6 * * *' | |
jobs: | |
generate_rmw_api_reference: | |
runs-on: ubuntu-latest | |
container: ros:iron | |
steps: | |
- uses: actions/checkout@v3 | |
- run: git config --global --add safe.directory "$GITHUB_WORKSPACE" | |
- name: Get date | |
id: date | |
run: echo "::set-output name=date::$(date +'%d-%m-%Y %H:%M')" | |
- name: Update libraries | |
shell: bash | |
run: | | |
apt update | |
apt install -y doxygen wget git unzip cmake | |
pushd / | |
wget https://github.com/matusnovak/doxybook2/releases/download/v1.3.3/doxybook2-linux-amd64-v1.3.3.zip | |
unzip doxybook2-linux-amd64-v1.3.3.zip -d doxybook2 | |
mkdir -p ros2_ws/src; cd ros2_ws | |
git clone -b ros2 https://github.com/eProsima/Micro-CDR src/Micro-CDR | |
git clone -b ros2 https://github.com/eProsima/Micro-XRCE-DDS-Client src/Micro-XRCE-DDS-Client | |
git clone -b iron https://github.com/micro-ROS/rosidl_typesupport_microxrcedds src/rosidl_typesupport_microxrcedds | |
git clone -b iron https://github.com/micro-ROS/rmw-microxrcedds src/rmw-microxrcedds | |
source /opt/ros/$ROS_DISTRO/setup.bash | |
colcon build --packages-up-to rmw_microxrcedds --cmake-args -DBUILD_DOCUMENTATION=ON | |
popd | |
/doxybook2/bin/doxybook2 --input /ros2_ws/build/rmw_microxrcedds/doc/xml --output _includes/rmw_doc -c utils/doxy_config -t utils/doxy_templates | |
- name: Create Pull Request | |
uses: peter-evans/create-pull-request@v4 | |
with: | |
commit-message: micro-ROS RMW API reference auto-update ${{ steps.date.outputs.date }} | |
title: micro-ROS RMW API reference auto-update ${{ steps.date.outputs.date }} | |
body: This PR is autogenerated and updates the micro-ROS RMW API reference. Close and reopen to trigger CI. | |
branch: autoupdate_micro_ros_rmw_api_reference | |
delete-branch: true | |
base: master | |
generate_utils_api_reference: | |
runs-on: ubuntu-latest | |
container: ros:iron | |
steps: | |
- uses: actions/checkout@v3 | |
- run: git config --global --add safe.directory "$GITHUB_WORKSPACE" | |
- name: Get date | |
id: date | |
run: echo "::set-output name=date::$(date +'%d-%m-%Y %H:%M')" | |
- name: Update libraries | |
shell: bash | |
run: | | |
apt update | |
apt install -y doxygen wget git unzip cmake ros-iron-osrf-testing-tools-cpp | |
pushd / | |
wget https://github.com/matusnovak/doxybook2/releases/download/v1.3.3/doxybook2-linux-amd64-v1.3.3.zip | |
unzip doxybook2-linux-amd64-v1.3.3.zip -d doxybook2 | |
mkdir -p ros2_ws/src; cd ros2_ws | |
git clone -b iron https://github.com/micro-ROS/micro_ros_utilities src/micro_ros_utilities | |
source /opt/ros/$ROS_DISTRO/setup.bash | |
colcon build --packages-up-to micro_ros_utilities --cmake-args -DBUILD_DOCUMENTATION=ON | |
popd | |
/doxybook2/bin/doxybook2 --input /ros2_ws/build/micro_ros_utilities/doc/xml --output _includes/utils_doc -c utils/doxy_config -t utils/doxy_templates | |
- name: Create Pull Request | |
uses: peter-evans/create-pull-request@v4 | |
with: | |
commit-message: micro-ROS Utils API reference auto-update ${{ steps.date.outputs.date }} | |
title: micro-ROS Utils API reference auto-update ${{ steps.date.outputs.date }} | |
body: This PR is autogenerated and updates the micro-ROS Utils API reference. Close and reopen to trigger CI. | |
branch: autoupdate_micro_ros_utils_api_reference | |
delete-branch: true | |
base: master |