Skip to content

fix publish-java-cdk workflow on push-to-master #36975

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/workflows/publish-java-cdk-command.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ env:
# Use the provided GITREF or default to the branch triggering the workflow.
GITREF: ${{ github.event.inputs.gitref || github.ref }}
FORCE: "${{ github.event_name == 'push' || github.event.inputs.force == null && 'false' || github.event.inputs.force }}"
DRY_RUN: "${{ github.event.inputs.dry-run == null && 'true' || github.event.inputs.dry-run }}"
DRY_RUN: "${{ github.event_name == 'push' && 'false' || github.event.inputs.dry-run == null && 'true' || github.event.inputs.dry-run }}"
CDK_VERSION_FILE_PATH: "./airbyte-cdk/java/airbyte-cdk/core/src/main/resources/version.properties"
S3_BUILD_CACHE_ACCESS_KEY_ID: ${{ secrets.SELF_RUNNER_AWS_ACCESS_KEY_ID }}
S3_BUILD_CACHE_SECRET_KEY: ${{ secrets.SELF_RUNNER_AWS_SECRET_ACCESS_KEY }}
Expand Down Expand Up @@ -77,6 +77,9 @@ jobs:
id: read-target-java-cdk-version
run: |
cdk_version=$(cat $CDK_VERSION_FILE_PATH | tr -d '\n')
echo "CDK_VERSION=$CDK_VERSION"
echo "FORCE=$FORCE"
echo "DRY_RUN=$DRY_RUN"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good idea

if [[ -z "$cdk_version" ]]; then
echo "Failed to retrieve CDK version from $CDK_VERSION_FILE_PATH"
exit 1
Expand Down
Loading