Modify Ssld examplar and Free reporting section #3087
Workflow file for this run
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
# This workflow will build the main SET application and publish it to GitHub Packages | |
name: Build SET | |
on: | |
repository_dispatch: | |
pull_request: | |
push: | |
tags: | |
- 'v**' | |
branches: | |
- 'release/**' | |
- 'main' | |
paths-ignore: | |
- DEPENDENCIES | |
env: | |
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} | |
DEPLOY_DIR: ${{ github.workspace }}/java-test/m2deploy | |
DIFF_DIR: java-test/diff | |
TEST_APPLICATION_DIR: ${{ github.workspace }}/java-test/application-under-test | |
jobs: | |
docs: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Asciidoctor & Hugo | |
uses: eclipse-set/build/.github/actions/setup-asciidoctor@main | |
- name: Build About | |
run: hugo | |
working-directory: web/about | |
- name: Store artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: about-artifact | |
path: web/about/dist | |
retention-days: 1 | |
developerhelp: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Asciidoctor & Hugo | |
uses: eclipse-set/build/.github/actions/setup-asciidoctor@main | |
- name: Build About | |
run: hugo | |
working-directory: web/developerhelp | |
- name: Store artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: developerhelp-artifact | |
path: web/developerhelp/dist | |
retention-days: 1 | |
textviewer: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Build | |
run: | | |
npm ci | |
npm run build | |
working-directory: web/textviewer | |
- name: Store artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: textviewer-artifact | |
path: web/textviewer/dist | |
retention-days: 1 | |
pdfviewer: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Build | |
run: | | |
wget --no-verbose -O pdfjs.zip https://github.com/mozilla/pdf.js/releases/download/v$(node getVersion.js)/pdfjs-$(node getVersion.js)-dist.zip | |
npm ci | |
npm run build | |
working-directory: web/pdf | |
- name: Store artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: pdfviewer-artifact | |
path: web/pdf/dist | |
retention-days: 1 | |
siteplan: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Build | |
run: | | |
npm ci | |
npm run build-prod | |
working-directory: web/siteplan | |
- name: Store artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: siteplan-artifact | |
path: web/siteplan/dist | |
retention-days: 1 | |
news: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Java | |
uses: eclipse-set/build/.github/actions/setup-java@main | |
- name: Install Asciidoctor & Hugo | |
uses: eclipse-set/build/.github/actions/setup-asciidoctor@main | |
- name: Build Release Notes | |
run: mvn -Dnote-file-path="${{github.workspace}}/RELEASE_NOTES.md" clean compile | |
working-directory: web/news | |
- name: Store artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: news-artifact | |
path: web/news/public | |
retention-days: 1 | |
java: | |
runs-on: ubuntu-latest | |
needs: | |
- docs | |
- textviewer | |
- pdfviewer | |
- siteplan | |
- developerhelp | |
- news | |
permissions: | |
contents: write | |
packages: write | |
checks: write | |
pull-requests: write | |
actions: read | |
security-events: write | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@v3 | |
if: github.ref == 'refs/heads/main' | |
with: | |
languages: java, javascript | |
config: | | |
paths-ignore: | |
- '**/dist/**' | |
- '**/target/**' | |
- '**/siteplan/assets/**' | |
- '**/monaco/vs/**' | |
- name: Setup Java | |
uses: eclipse-set/build/.github/actions/setup-java@main | |
- name: Fetch pdf viewer | |
uses: actions/download-artifact@v4 | |
with: | |
name: pdfviewer-artifact | |
path: web/pdf/dist | |
- name: Fetch text viewer | |
uses: actions/download-artifact@v4 | |
with: | |
name: textviewer-artifact | |
path: web/textviewer/dist | |
- name: Fetch about | |
uses: actions/download-artifact@v4 | |
with: | |
name: about-artifact | |
path: web/about/dist | |
- name: Fetch siteplan | |
uses: actions/download-artifact@v4 | |
with: | |
name: siteplan-artifact | |
path: web/siteplan/dist | |
- name: Fetch developerhelp | |
uses: actions/download-artifact@v4 | |
with: | |
name: developerhelp-artifact | |
path: web/developerhelp/dist | |
- name: Fetch news | |
uses: actions/download-artifact@v4 | |
with: | |
name: news-artifact | |
path: web/news/public | |
- name: Build | |
run: mvn -T 1.5C -U -B clean deploy --settings .github/settings.xml -DaltDeploymentRepository=local::file://${{ github.workspace }}/set-m2deploy | |
env: | |
GITHUB_TOKEN: ${{ github.token }} | |
- name: Upload artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: eclipse-set-snapshot-${{github.run_number}} | |
path: java/bundles/org.eclipse.set.releng.set.product/target/products/SET/win32/win32/x86_64/ | |
retention-days: 7 | |
- name: Upload m2repo artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: set-m2deploy-${{github.run_number}} | |
path: ${{ github.workspace}}/set-m2deploy | |
retention-days: 1 | |
- name: Publish | |
run: mvn -T 1.5C -U -B deploy --settings .github/settings.xml -DaltDeploymentRepository=set-github::https://maven.pkg.github.com/${{ github.repository }} | |
if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/tags/') | |
env: | |
GITHUB_TOKEN: ${{ github.token }} | |
- name: Prepare release asset | |
if: startsWith(github.ref, 'refs/tags/') | |
run: | | |
VERSION=$(echo ${{ github.ref_name }} | cut -c 2-) | |
mv *.zip unsigned-Eclipse-SET-$VERSION.zip | |
working-directory: java/bundles/org.eclipse.set.releng.set.product/target/products | |
- name: Upload release asset | |
if: startsWith(github.ref, 'refs/tags/') | |
uses: softprops/action-gh-release@01570a1f39cb168c169c802c3bceb9e93fb10974 # v2.1.0 | |
with: | |
files: java/bundles/org.eclipse.set.releng.set.product/target/products/unsigned-Eclipse-SET-*.zip | |
- name: Publish Test Results | |
uses: EnricoMi/publish-unit-test-result-action@170bf24d20d201b842d7a52403b73ed297e6645b # v2.18.0 | |
if: always() | |
with: | |
files: | | |
${{ github.workspace }}/**/surefire-reports/*.xml | |
- name: Perform CodeQL Analysis | |
uses: github/codeql-action/analyze@v3 | |
if: github.ref == 'refs/heads/main' | |
swtbot: | |
runs-on: windows-latest | |
needs: | |
- java | |
permissions: | |
contents: write | |
checks: write | |
pull-requests: write | |
actions: read | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Java | |
uses: eclipse-set/build/.github/actions/setup-java@main | |
- name: Fetch SET | |
uses: actions/download-artifact@v4 | |
with: | |
name: eclipse-set-snapshot-${{github.run_number}} | |
path: ${{ env.TEST_APPLICATION_DIR }} | |
- name: Fetch m2 Deploy | |
uses: actions/download-artifact@v4 | |
with: | |
name: set-m2deploy-${{github.run_number}} | |
path: ${{ env.DEPLOY_DIR }} | |
- name: Run Test | |
id: test-steps | |
shell: bash | |
run: | | |
mvn -T 1.5C -U -B -f java-test/pom.xml clean verify \ | |
--settings ./.github/settings.xml \ | |
-Dskip-test=false \ | |
-Dm2-repo-path="file://${{ env.DEPLOY_DIR }}" \ | |
-Dapplication-under-test="${{ env.TEST_APPLICATION_DIR }}" \ | |
- name: Upload csv files | |
if: failure() && steps.test-steps.outcome == 'failure' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: table-csv-${{github.run_number}} | |
path: ${{ github.workspace}}/java/bundles/org.eclipse.set.swtbot/target/classes/diff/**/*.csv | |
retention-days: 1 | |
table-diff-view: | |
runs-on: ubuntu-latest | |
needs: swtbot | |
if: always() && github.actor_id != 49699333 | |
container: ghcr.io/eclipse-set/table-diff-view:latest | |
permissions: | |
contents: write | |
checks: write | |
pull-requests: write | |
actions: read | |
issues: write | |
steps: | |
- name: Get Branchname | |
shell: bash | |
run: | | |
if [ "${{ github.event_name }}" == "pull_request" ]; then | |
echo "BRANCH_NAME=${{ github.head_ref }}" >> $GITHUB_ENV | |
else | |
echo "BRANCH_NAME=${GITHUB_REF#refs/heads/}" >> $GITHUB_ENV | |
fi | |
- name: Fetch table csv | |
if: needs.swtbot.result == 'failure' | |
uses: actions/download-artifact@v4 | |
with: | |
name: table-csv-${{github.run_number}} | |
path: ${{ env.DIFF_DIR }} | |
- name: Create diff view | |
shell: bash | |
run: | | |
python -m tablediffview \ | |
--diffDir=${{ env.DIFF_DIR }} \ | |
--branchName=${{ env.BRANCH_NAME }} \ | |
--prNumber=${{github.event.pull_request.number}} \ | |
--runId=${{github.run_id}} | |
- name: Upload Diff-File | |
if: needs.swtbot.result == 'failure' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: table-diff-files-${{github.run_number}} | |
path: ${{ env.DIFF_DIR }}/diff-md | |
retention-days: 5 |