update to Eclipse 2024-12 #1022
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: Build component | |
on: | |
push: | |
pull_request: | |
repository_dispatch: | |
types: [upstream-build, manual-build] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout sources from component repository | |
uses: actions/checkout@v4 | |
- name: Checkout additional sources from product repository | |
uses: actions/checkout@v4 | |
with: | |
repository: Guite/MostProduct | |
token: ${{ secrets.ACCESS_MOST_PRODUCT }} | |
path: MostProduct | |
# see https://github.com/actions/setup-java | |
- name: Setup JDK | |
uses: actions/setup-java@master | |
with: | |
distribution: temurin | |
java-version: 21 | |
cache: maven | |
# Tycho 4 requires Maven 3.8 at least | |
- name: Update Maven | |
run: | | |
wget -q https://dlcdn.apache.org/maven/maven-3/3.9.8/binaries/apache-maven-3.9.8-bin.tar.gz | |
tar xzf apache-maven-3.9.8-bin.tar.gz && rm apache-maven-3.9.8-bin.tar.gz | |
mv apache-maven-3.9.8 maven | |
# https://stackoverflow.com/questions/71069/can-maven-be-made-less-verbose | |
- name: Maven Build | |
run: | | |
maven/bin/mvn verify -B -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn | |
- name: Collect artifacts to deploy | |
run: | | |
mkdir -p deploy/repo | |
cp -R releng/org.zikula.modulestudio.generator.build/target/repository/* deploy/repo | |
# see https://github.com/WebFreak001/deploy-nightly | |
- name: Deploy standalone generator | |
uses: WebFreak001/deploy-nightly@master | |
with: | |
upload_url: https://uploads.github.com/repos/Guite/MostGenerator/releases/22066470/assets{?name,label} | |
release_id: 22066470 | |
asset_path: ./bundles/org.zikula.modulestudio.generator/target/ModuleStudio-generator.jar | |
#asset_name: ModuleStudio-generator-$$.jar # $$ inserts date (YYYYMMDD) and 6 letter commit hash, example: https://github.com/Pure-D/serve-d/releases/tag/nightly | |
asset_name: ModuleStudio-generator.jar | |
asset_content_type: application/java-archive | |
max_releases: 1 # optional, if there are more releases than this matching the asset_name, the oldest ones are going to be deleted | |
- name: Regenerate apps | |
run: ./.github/scripts/regenerateApps.sh | |
env: | |
DISPATCH_TOKEN: ${{ secrets.DISPATCH_TOKEN }} | |
# see https://github.com/SamKirkland/FTP-Deploy-Action | |
- name: Deploy repository | |
uses: SamKirkland/FTP-Deploy-Action@master | |
with: | |
server: ${{ secrets.FTP_SERVER }} | |
username: ${{ secrets.FTP_USERNAME }} | |
password: ${{ secrets.FTP_PASSWORD }} | |
local-dir: deploy/repo/ | |
server-dir: components/generator/ | |
dangerous-clean-slate: true | |
# see https://github.com/peter-evans/repository-dispatch | |
- name: Dispatch downstream job | |
uses: peter-evans/repository-dispatch@main | |
with: | |
token: ${{ secrets.DISPATCH_TOKEN }} | |
repository: Guite/MostProduct | |
event-type: upstream-build |