Skip to content

Use EclipseWorkspaceManager.getWorkspace(URI, Mojo) in ApiAnalysisMojo #1020

Use EclipseWorkspaceManager.getWorkspace(URI, Mojo) in ApiAnalysisMojo

Use EclipseWorkspaceManager.getWorkspace(URI, Mojo) in ApiAnalysisMojo #1020

Workflow file for this run

name: Publish Tycho site-docs
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
on:
push:
branches:
- 'main'
permissions:
contents: read
jobs:
build:
name: Publish site-docs
runs-on: ubuntu-latest
strategy:
fail-fast: false
permissions:
contents: write
repository-projects: write
steps:
- name: Inject slug/short variables
uses: rlespinasse/github-slug-action@102b1a064a9b145e56556e22b18b19c624538d94 # v4.4.1
- name: Checkout tycho code
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
with:
path: 'tycho'
- name: Checkout page
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
with:
path: 'page'
token: ${{ secrets.TYCHO_SITE_PAT }}
repository: 'eclipse-tycho/eclipse-tycho.github.io'
- name: Set up Java
uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9 # v4.2.1
with:
java-version: 17
distribution: 'temurin'
- name: Cache local Maven repository
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-site-${{ hashFiles('**/pom.xml', '**/*.target') }}
restore-keys: |
${{ runner.os }}-maven-site-
- name: Set up Maven
uses: stCarolas/setup-maven@d6af6abeda15e98926a57b5aa970a96bb37f97d1 # v5
with:
maven-version: 3.9.6
- name: Build site-doc
env:
JAVA_HOME: ${{ env.JAVA_HOME_17_X64 }}
run: |
mvn -U -V -e -B -ntp clean install site site:stage --file tycho/pom.xml -T1C -DskipTests
- name: Upload site-doc
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
with:
name: site-docs-${{ env.GITHUB_REF_NAME }}
if-no-files-found: error
path: |
${{ github.workspace }}/tycho/target/staging/**/*.*
- run: |
cd ${{ github.workspace }}/page/doc/
git config user.name "Tycho Bot"
git config user.email tycho-bot@eclipse.org
cp -r ${{ github.workspace }}/tycho/target/staging/* ${{ env.GITHUB_REF_NAME }}
git add -A
git diff --quiet && git diff --staged --quiet || git commit -am "Update sitedocs for branch ${{ env.GITHUB_REF_NAME }}"
git push