Add revision dump on release workflow (#2496)

Signed-off-by: Avgustin Marinov <Avgustin.Marinov@bosch.com>
This commit is contained in:
Avgustin Marinov
2025-06-25 08:36:08 +03:00
committed by GitHub
parent b43e5b36a5
commit 926765d1ee
2 changed files with 26 additions and 21 deletions

View File

@@ -41,7 +41,8 @@ jobs:
CHANGED_FILES_COUNT=$(git status --short | wc -l) CHANGED_FILES_COUNT=$(git status --short | wc -l)
CHANGED_FILES_COUNT=${CHANGED_FILES_COUNT//[[:space:]]/} CHANGED_FILES_COUNT=${CHANGED_FILES_COUNT//[[:space:]]/}
echo "Number of changed files: ${CHANGED_FILES_COUNT}" echo "Number of changed files: ${CHANGED_FILES_COUNT}"
if [ "$CHANGED_FILES_COUNT" -eq 1 ]; then if [ "${CHANGED_FILES_COUNT}" -ne 0 ]; then
if [ "${CHANGED_FILES_COUNT}" -eq 1 ]; then
DEPENDENCY_FILE=".3rd-party/DEPENDENCIES" DEPENDENCY_FILE=".3rd-party/DEPENDENCIES"
DEPENDENCIES_MODIFIED=$(git status --short | grep ".3rd-party/DEPENDENCIES") DEPENDENCIES_MODIFIED=$(git status --short | grep ".3rd-party/DEPENDENCIES")
# Check if the file is modified # Check if the file is modified
@@ -60,6 +61,7 @@ jobs:
git status --short git status --short
exit 1 exit 1
fi fi
fi
# do dash.fail=true so if there are restricted dependencis the build will fail # do dash.fail=true so if there are restricted dependencis the build will fail
mvn license-tool:license-check -Ddash.fail=true -PcheckLicense -Ddash.iplab.token=${GITLAB_API_TOKEN} --projects '!org.eclipse.hawkbit:hawkbit-repository-test,!org.eclipse.hawkbit:hawkbit-dmf-rabbitmq-test' mvn license-tool:license-check -Ddash.fail=true -PcheckLicense -Ddash.iplab.token=${GITLAB_API_TOKEN} --projects '!org.eclipse.hawkbit:hawkbit-repository-test,!org.eclipse.hawkbit:hawkbit-dmf-rabbitmq-test'
env: env:

View File

@@ -29,6 +29,9 @@ jobs:
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: "Release ${{ github.event.inputs.revision }}"
run: echo "Releasing ${{ github.event.inputs.revision }}"
- name: Set up JDK & Maven Central credentials - name: Set up JDK & Maven Central credentials
uses: actions/setup-java@v4 uses: actions/setup-java@v4
with: with:
@@ -93,8 +96,8 @@ jobs:
env: env:
REVISION: ${{ github.event.inputs.revision }} REVISION: ${{ github.event.inputs.revision }}
- name: Deploy - name: "Deploy ${{ github.event.inputs.revision }}"
run: mvn deploy -Ppublish -DskipTests -Drevision=${REVISION} --batch-mode javadoc:jar run: mvn deploy -Ppublish -Drevision=${REVISION} --batch-mode
env: env:
REVISION: ${{ github.event.inputs.revision }} REVISION: ${{ github.event.inputs.revision }}
MAVEN_USERNAME: ${{ secrets.CENTRAL_SONATYPE_TOKEN_USERNAME }} MAVEN_USERNAME: ${{ secrets.CENTRAL_SONATYPE_TOKEN_USERNAME }}