From e6838ebf665dcdc7b127cfe77306f9b1e2045fe9 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Tue, 25 Aug 2026 12:23:22 +0000 Subject: [PATCH] Publish the p2 update site on every merge to main The site was never reachable: publishing only ran for v* tags and manual dispatches, so p2/ on main held nothing but a placeholder and Pages answered 404 for the documented install URL. Run the full test suite in the build job as well, now that the parser and test fixes make it pass. Co-authored-by: Kurrle, Philipp --- .github/workflows/p2-site.yml | 11 +++++++---- README.md | 12 ++++++------ 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/.github/workflows/p2-site.yml b/.github/workflows/p2-site.yml index e1bc774..e4c9714 100644 --- a/.github/workflows/p2-site.yml +++ b/.github/workflows/p2-site.yml @@ -4,6 +4,8 @@ on: push: branches: [main, "cursor/**"] tags: ["v*"] + # The publish job commits back to p2/; do not rebuild for that commit. + paths-ignore: ["p2/**"] pull_request: workflow_dispatch: @@ -27,9 +29,7 @@ jobs: java-version: "21" cache: maven - name: Build and verify p2 repository - # Existing unit tests fail independently of packaging; the site - # must still be produced so it can be published. - run: ./mvnw --batch-mode clean verify -DskipTests + run: ./mvnw --batch-mode clean verify - name: Resolve feature installation run: >- ./mvnw --batch-mode --non-recursive @@ -48,7 +48,10 @@ jobs: # GitHub Pages serves this repository's default branch, so the published # update site is the committed p2/ directory rather than a Pages artifact. publish: - if: startsWith(github.ref, 'refs/tags/v') || github.event_name == 'workflow_dispatch' + if: >- + github.ref == 'refs/heads/main' + || startsWith(github.ref, 'refs/tags/v') + || github.event_name == 'workflow_dispatch' needs: build runs-on: ubuntu-latest permissions: diff --git a/README.md b/README.md index 2335eca..53fd3f6 100644 --- a/README.md +++ b/README.md @@ -139,13 +139,13 @@ resolved earlier. If Eclipse reports that it cannot download an older version, select the site under **Preferences → Install/Update → Available Software Sites** and click **Reload**. -Enable GitHub Pages for this repository (**Settings → Pages**, deploy -from `main` at `/`) so the committed `p2/` directory is served. +GitHub Pages serves this repository from `main` at `/` +(**Settings → Pages**), which is what makes the committed `p2/` +directory reachable. -Releases are published by pushing a `v*` tag or by running the -**Build and publish p2 update site** workflow manually. Every push and -pull request still builds the site and uploads it as the -`p2-update-site` artifact. +Every merge to `main` republishes the site, and a `v*` tag or a manual +run of **Build and publish p2 update site** does the same. Pull requests +only build the site and upload it as the `p2-update-site` artifact. To test an unreleased change, download that artifact from the workflow run and add the extracted folder as a local repository.