name: CI

on:
  push:
    branches: [ '*' ]
  pull_request:
    branches: [ '*' ]
  workflow_dispatch:

jobs:
  build:
    name: Test on Java ${{ matrix.java }} and ${{ matrix.os }}

    strategy:
      fail-fast: false
      matrix:
        java: [ 8, 11, 15 ]
        os: [ ubuntu-latest, windows-latest, macos-latest ]

    runs-on: ${{ matrix.os }}

    steps:
      - uses: actions/checkout@v2
      - name: Set up JDK ${{ matrix.java }}
        uses: actions/setup-java@v1
        with:
          java-version: ${{ matrix.java }}
      - uses: actions/cache@v2
        with:
          path: |
            ~/.gradle/caches
            ~/.gradle/wrapper
          key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
          restore-keys: |
            ${{ runner.os }}-gradle-
      - name: Grant execute permission for gradlew
        run: chmod +x gradlew
      - name: Build with Gradle
        run: ./gradlew build --stacktrace

Add GH Actions CI config.
Add GH Actions CI config.
