This repository has been archived by the owner on Jan 12, 2024. It is now read-only.
chore(deps): update plugin com.diffplug.spotless to v6.23.3 #402
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
# 🤹 common-utils: Common Kotlin utilities made for my personal usage. | |
# Copyright (c) 2021-2023 Noel <cutie@floofy.dev> | |
# | |
# Permission is hereby granted, free of charge, to any person obtaining a copy | |
# of this software and associated documentation files (the "Software"), to deal | |
# in the Software without restriction, including without limitation the rights | |
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
# copies of the Software, and to permit persons to whom the Software is | |
# furnished to do so, subject to the following conditions: | |
# | |
# The above copyright notice and this permission notice shall be included in all | |
# copies or substantial portions of the Software. | |
# | |
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | |
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | |
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | |
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | |
# SOFTWARE. | |
name: Linting & Unit Testing | |
on: | |
workflow_dispatch: | |
pull_request: | |
types: [opened, synchronize] | |
branches: | |
- 'feature/**' | |
- 'issue/gh-**' | |
- master | |
paths-ignore: | |
- '.husky/**' | |
- '.vscode/**' | |
- 'assets/**' | |
- 'locales/**' | |
- 'docker/**' | |
- '.dockerignore' | |
- '.eslintignore' | |
- '.gitignore' | |
- '**.md' | |
- 'LICENSE' | |
- 'renovate.json' | |
push: | |
branches: | |
- 'feature/**' | |
- 'issue/gh-**' | |
- master | |
paths-ignore: | |
- '.husky/**' | |
- '.vscode/**' | |
- 'assets/**' | |
- 'locales/**' | |
- 'docker/**' | |
- '.dockerignore' | |
- '.eslintignore' | |
- '.gitignore' | |
- '**.md' | |
- 'LICENSE' | |
- 'renovate.json' | |
jobs: | |
ktlint: | |
name: Linting & Unit Testing | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
java-version: [17, 19] | |
steps: | |
- name: Checks out the repository | |
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4 | |
- name: Sets up Java ${{ matrix.java-version }} | |
uses: actions/setup-java@v3 | |
with: | |
distribution: temurin | |
java-version: ${{ matrix.java-version }} | |
- name: Setup Gradle | |
uses: gradle/gradle-build-action@v2 | |
- name: Validate gradle-wrapper.jar | |
uses: gradle/wrapper-validation-action@v1 | |
- name: Lets ./gradlew be executable | |
run: chmod +x ./gradlew | |
- name: Lints the repository for any code errors | |
run: ./gradlew spotlessCheck --no-daemon --scan | |
- name: Builds the project for any errors | |
run: ./gradlew compileKotlin --no-daemon --scan | |
- name: Builds the project for any errors | |
run: ./gradlew compileJava --no-daemon --scan | |
- name: Runs all tests | |
run: ./gradlew test --no-daemon --scan |