From 60c465fefe19df654b93498b3df2e3d9cf436b5d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christoph=20Fr=C3=B6hlich?= Date: Mon, 13 May 2024 19:02:34 +0200 Subject: [PATCH] Add jazzy and rename default branch to rolling (#293) --- .github/workflows/pr-stats.yml | 8 +++---- .../reusable-sphinx-check-single-version.yml | 2 +- .github/workflows/sphinx-check-links.yml | 4 ++-- .../sphinx-check-page-multiversion.yml | 7 ++++--- .github/workflows/sphinx-check-warnings.yml | 4 ++-- .github/workflows/sphinx-make-page.yml | 2 +- Makefile | 21 +++++++++++++------ conf.py | 9 +++++--- make_help_scripts/deploy_defines.py | 12 ++++++++++- 9 files changed, 46 insertions(+), 23 deletions(-) diff --git a/.github/workflows/pr-stats.yml b/.github/workflows/pr-stats.yml index 058fa84b862..c85b0e8f18b 100644 --- a/.github/workflows/pr-stats.yml +++ b/.github/workflows/pr-stats.yml @@ -2,14 +2,14 @@ name: "Create PR Stats" on: workflow_dispatch: - pull_request: # run if the file changed on a PR to master + pull_request: # run if the file changed on a PR to rolling branches: - - master + - rolling paths: - 'make_help_scripts/create_pr_stats.py' - push: # run if the file changed by pushes to master + push: # run if the file changed by pushes to rolling branches: - - master + - rolling paths: - 'make_help_scripts/create_pr_stats.py' schedule: diff --git a/.github/workflows/reusable-sphinx-check-single-version.yml b/.github/workflows/reusable-sphinx-check-single-version.yml index 314e5ec0e7f..58b0ca6970f 100644 --- a/.github/workflows/reusable-sphinx-check-single-version.yml +++ b/.github/workflows/reusable-sphinx-check-single-version.yml @@ -20,7 +20,7 @@ jobs: - uses: actions/checkout@v4 with: repository: ros-controls/control.ros.org - ref: master + ref: rolling fetch-depth: 0 - uses: actions/setup-python@v5 with: diff --git a/.github/workflows/sphinx-check-links.yml b/.github/workflows/sphinx-check-links.yml index 06a058f80e5..3769d0aa1a8 100644 --- a/.github/workflows/sphinx-check-links.yml +++ b/.github/workflows/sphinx-check-links.yml @@ -3,7 +3,7 @@ on: workflow_dispatch: push: branches: - - master + - rolling schedule: # Run every morning to ensure component documentation is up to date on deployment - cron: '23 5 * * *' @@ -14,7 +14,7 @@ jobs: strategy: fail-fast: false matrix: - BRANCH: [humble, iron, master] + BRANCH: [humble, iron, jazzy, rolling] steps: - uses: actions/checkout@v4 with: diff --git a/.github/workflows/sphinx-check-page-multiversion.yml b/.github/workflows/sphinx-check-page-multiversion.yml index 55619752d2c..4898efc998e 100644 --- a/.github/workflows/sphinx-check-page-multiversion.yml +++ b/.github/workflows/sphinx-check-page-multiversion.yml @@ -5,15 +5,16 @@ on: BASE_BRANCH: description: 'Chose branch to run on' required: true - default: 'master' + default: 'rolling' type: choice options: - humble - iron - - master + - jazzy + - rolling pull_request: branches: - - master + - rolling paths: - 'make_help_scripts/**' - 'conf.py' diff --git a/.github/workflows/sphinx-check-warnings.yml b/.github/workflows/sphinx-check-warnings.yml index 7cb692136c6..0230ac7f84f 100644 --- a/.github/workflows/sphinx-check-warnings.yml +++ b/.github/workflows/sphinx-check-warnings.yml @@ -3,7 +3,7 @@ on: workflow_dispatch: push: branches: - - master + - rolling schedule: # Run every morning to ensure component documentation is up to date on deployment - cron: '23 5 * * *' @@ -14,7 +14,7 @@ jobs: strategy: fail-fast: false matrix: - BRANCH: [humble, iron, master] + BRANCH: [humble, iron, jazzy, rolling] steps: - uses: actions/checkout@v4 with: diff --git a/.github/workflows/sphinx-make-page.yml b/.github/workflows/sphinx-make-page.yml index e60e7cc2fb4..03fe8dd9a56 100644 --- a/.github/workflows/sphinx-make-page.yml +++ b/.github/workflows/sphinx-make-page.yml @@ -3,7 +3,7 @@ on: workflow_dispatch: push: branches: - - master + - rolling schedule: # Run every morning to ensure component documentation is up to date on deployment - cron: '23 5 * * *' diff --git a/Makefile b/Makefile index 702f71eda23..c1e4fc722e2 100644 --- a/Makefile +++ b/Makefile @@ -80,8 +80,11 @@ multiversion: Makefile sphinx-multiversion $(SPHINXOPTS) $(SOURCEDIR) $(BUILDDIR)/html @echo Step 3: Deleting temporary commits ./make_help_scripts/delete_tmp_commits.py - @echo Step 4: Create correct index - @echo "" > "$(BUILDDIR)"/html/index.html + @echo Step 4: Create correct index + legacy master version + @echo "" > "$(BUILDDIR)"/html/index.html +# legacy, renamed Rolling version from "master" to "rolling" + @cp -r "$(BUILDDIR)"/html/rolling/ "$(BUILDDIR)"/html/master + @echo "" > "$(BUILDDIR)"/html/master/index.html multiversion-with-errors: Makefile @echo Building multi version documentation without API @@ -91,8 +94,11 @@ multiversion-with-errors: Makefile sphinx-multiversion $(SPHINXOPTS) -W --keep-going $(SOURCEDIR) $(BUILDDIR)/html @echo Step 3: Deleting temporary commits ./make_help_scripts/delete_tmp_commits.py - @echo Step 4: Create correct index - @echo "" > "$(BUILDDIR)"/html/index.html + @echo Step 4: Create correct index + legacy master version + @echo "" > "$(BUILDDIR)"/html/index.html +# legacy, renamed Rolling version from "master" to "rolling" + @cp -r "$(BUILDDIR)"/html/rolling/ "$(BUILDDIR)"/html/master + @echo "" > "$(BUILDDIR)"/html/master/index.html multiversion-with-api: Makefile @echo Building multi version documentation with API @@ -106,8 +112,11 @@ multiversion-with-api: Makefile ./make_help_scripts/delete_sub_repos.py @echo Step 5: Building multiversion API ./make_help_scripts/create_api_multi_version.py - @echo Step 6: Create correct index - @echo "" > "$(BUILDDIR)"/html/index.html + @echo Step 6: Create correct index + legacy master version + @echo "" > "$(BUILDDIR)"/html/index.html +# legacy, renamed Rolling version from "master" to "rolling" + @cp -r "$(BUILDDIR)"/html/rolling/ "$(BUILDDIR)"/html/master + @echo "" > "$(BUILDDIR)"/html/master/index.html .PHONY: help Makefile html-with-errors html-with-api multiversion multiversion-with-api multiversion-with-errors html-all-subrepos html-all-subrepos-with-api html-all-subrepos-with-errors linkcheck-all-subrepos-with-api diff --git a/conf.py b/conf.py index a2de0bb4f24..f1968770d80 100644 --- a/conf.py +++ b/conf.py @@ -33,7 +33,7 @@ ros_distro = "rolling" distro_title = "Rolling" distro_title_full = "Rolling Ridley" -repos_file_branch = "master" +repos_file_branch = "rolling" # for single version only # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the @@ -199,10 +199,10 @@ elif os.environ.get('BASE_BRANCH') is not None: base_branch = os.environ.get('BASE_BRANCH') else: - base_branch = "master" + base_branch = "rolling" # Add branches you want to whitelist here. -smv_branch_whitelist = r"^(foxy|galactic|humble|iron|"+ base_branch + r")$" +smv_branch_whitelist = r"^(foxy|galactic|humble|iron|jazzy|"+ base_branch + r")$" smv_released_pattern = r"^refs/(heads|remotes/[^/]+)/(foxy|galactic|humble|iron).*$" smv_remote_whitelist = r"^(origin)$" smv_latest_version = "iron" @@ -213,6 +213,7 @@ "galactic": "Galactic Geochelone", "humble": "Humble Hawksbill", "iron": "Iron Irwini", + "jazzy": "Jazzy Jalisco", "rolling": "Rolling Ridley", } @@ -331,6 +332,7 @@ def smv_rewrite_configs(app, config): # this map is used to match branches of control.ros.org to ROS distros, e.g., DISTRO macro branch_distro = { base_branch: "rolling", + "jazzy": "jazzy", "iron": "iron", "humble": "humble", "foxy": "foxy", @@ -339,6 +341,7 @@ def smv_rewrite_configs(app, config): # this map is used to match branches of control.ros.org to REPOS_FILE_BRANCH macro subrepo_branch = { base_branch: "master", + "jazzy": "jazzy", "iron": "iron", "humble": "humble", "foxy": "foxy", diff --git a/make_help_scripts/deploy_defines.py b/make_help_scripts/deploy_defines.py index 870b2e8c905..c05b4026777 100644 --- a/make_help_scripts/deploy_defines.py +++ b/make_help_scripts/deploy_defines.py @@ -25,7 +25,7 @@ elif os.environ.get('BASE_BRANCH') is not None: base_branch = os.environ.get('BASE_BRANCH') else: - base_branch = "master" + base_branch = "rolling" print(f"Using base_branch: {base_branch}") build_dir = "_build" @@ -63,6 +63,7 @@ def add_pr_stats_file(): "galactic": "galactic", "humble": "humble", "iron": "iron", + "jazzy": "jazzy", base_branch: "rolling" # master is rolling, PRs are tested on rolling } @@ -77,6 +78,7 @@ def add_pr_stats_file(): "galactic": "galactic", "humble": "humble", "iron": "iron", + "jazzy": "master", "rolling": "master" # master is rolling }, "pr": os.environ.get('ROS2_CONTROL_PR') @@ -88,6 +90,7 @@ def add_pr_stats_file(): "galactic": "galactic", "humble": "humble", "iron": "iron", + "jazzy": "master", "rolling": "master" # master is rolling }, "pr": os.environ.get('ROS2_CONTROLLERS_PR') @@ -99,6 +102,7 @@ def add_pr_stats_file(): "galactic": "galactic", "humble": "humble", "iron": "iron", + "jazzy": "master", "rolling": "master" # master is rolling }, "pr": os.environ.get('ROS2_CONTROL_DEMOS_PR') @@ -110,6 +114,7 @@ def add_pr_stats_file(): "galactic": "galactic", "humble": "humble", "iron": "iron", + "jazzy": "master", "rolling": "master" # master is rolling }, "pr": os.environ.get('GAZEBO_ROS2_CONTROL_PR') @@ -121,6 +126,7 @@ def add_pr_stats_file(): "galactic": "galactic", "humble": "humble", "iron": "iron", + "jazzy": "master", "rolling": "master" # master is rolling }, "pr": os.environ.get('GZ_ROS2_CONTROL_PR') @@ -132,6 +138,7 @@ def add_pr_stats_file(): "galactic": "ros2-master", "humble": "ros2-master", "iron": "ros2-master", + "jazzy": "ros2-master", "rolling": "ros2-master" # master is rolling }, "pr": None @@ -143,6 +150,7 @@ def add_pr_stats_file(): "galactic": "galactic-devel", "humble": "humble", "iron": "master", + "jazzy": "master", "rolling": "master" # master is rolling }, "pr": None @@ -154,6 +162,7 @@ def add_pr_stats_file(): "galactic": "master", "humble": "master", "iron": "master", + "jazzy": "master", "rolling": "master" # master is rolling }, "pr": None @@ -165,6 +174,7 @@ def add_pr_stats_file(): "galactic": "humble", "humble": "humble", "iron": "master", + "jazzy": "master", "rolling": "master" # master is rolling }, "pr": None