Skip to content

Merge pull request #94 from assimbly/develop #12

Merge pull request #94 from assimbly/develop

Merge pull request #94 from assimbly/develop #12

Workflow file for this run

name: Release

Check failure on line 1 in .github/workflows/release.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/release.yml

Invalid workflow file

`on.workflow_run` does not reference any workflows. See https://docs.github.com/actions/learn-github-actions/events-that-trigger-workflows#workflow_run for more information
on:
workflow_dispatch:
# schedule:
# - cron: '0 0 * * *'
inputs:
branch:
description: 'Branch to use'
type: string
default: 'develop'
milestone:
description: 'Milestone to use as version'
type: string
required: true
workflow_run:
inputs:
branch:
description: 'Branch to use'
type: string
default: 'develop'
milestone:
description: 'Milestone to use as version'
type: string
required: true
jobs:
delete_old_snapshots:
runs-on: ubuntu-latest
permissions: write-all
steps:
- name: Delete older snapshots
uses: smartsquaregmbh/[email protected]
with:
organization: assimbly
type: maven
keep: 0
semver-pattern: "${{inputs.milestone}}"
names: |
org.assimbly.base
org.assimbly.common-base
org.assimbly.camel-base
org.assimbly.spring-base
org.assimbly.activemq-base
org.assimbly.test-base
org.assimbly.database-drivers
org.assimbly.camel-components
org.assimbly.utils
org.assimbly.extra
release-jars:
needs: delete_old_snapshots
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout the code
uses: actions/checkout@v4
with:
repository: "assimbly/base"
ref: ${{ inputs.branch }}
fetch-depth: 0
token: ${{ secrets.RELEASE_TOKEN }}
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- name: Setup Maven settings.xml
uses: whelk-io/maven-settings-xml-action@v22
with:
repositories: >
[
{
"id": "maven",
"name": "Maven Central",
"url": "https://repo1.maven.org/maven2"
},
{
"id": "github",
"name": "Assimbly Base Repository",
"url": "https://maven.pkg.github.com/assimbly/base",
"snapshots": {
"enabled": "true"
}
},
{
"id": "aurea",
"name": "Aurea Sonic Repository",
"url": "https://int-factory.aurea.com/nexus/content/repositories/sonic-releases/"
}
]
servers: >
[
{
"id": "github",
"username": "assimbly",
"password": "${{ secrets.MAVEN_TOKEN }}"
}
]
- name: Publish package
run: mvn --batch-mode deploy -DskipTests
env:
GITHUB_TOKEN: ${{ secrets.MAVEN_TOKEN }}