Skip to content

Bump org.jlleitschuh.gradle.ktlint from 12.1.0 to 12.1.1 #93

Bump org.jlleitschuh.gradle.ktlint from 12.1.0 to 12.1.1

Bump org.jlleitschuh.gradle.ktlint from 12.1.0 to 12.1.1 #93

Workflow file for this run

name: Build
on: [ push ]
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up JDK
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '17'
- name: Get tag or branch
id: get_tag_or_branch
run: |
if echo $GITHUB_REF | grep -Eq '^refs\/tags\/.*'; then
echo "TAG_OR_BRANCH=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
else
echo "TAG_OR_BRANCH=${GITHUB_REF#refs/heads/}" >> $GITHUB_OUTPUT
fi
- name: Gradle build
env:
GRADLE_CLI_OPTS: "-Dversion=${{steps.get_tag_or_branch.outputs.TAG_OR_BRANCH}}"
run: "chmod +x ./gradlew && ./gradlew ${GRADLE_CLI_OPTS} dockerBuild"
- name: Login to DockerHub
if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags')
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and push Docker images
if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags')
env:
TAG_OR_BRANCH: ${{steps.get_tag_or_branch.outputs.TAG_OR_BRANCH}}
run: |
docker tag faforever/faf-telemetry-server:latest faforever/faf-telemetry-server:${TAG_OR_BRANCH}
docker push faforever/faf-telemetry-server:${TAG_OR_BRANCH}