name: Java SDK

on:
  push:
    branches: ["main"]
  pull_request:
    types:
      - opened
      - synchronize
      - reopened
      - ready_for_review
  # Enable manual trigger for easier debugging
  workflow_dispatch:

permissions:
  contents: read
  pull-requests: write

jobs:
  lint:
    uses: ./.github/workflows/_hack_make.yml
    secrets: inherit
    with:
      mage-targets: sdk:java:lint

  test:
    uses: ./.github/workflows/_hack_make.yml
    secrets: inherit
    with:
      mage-targets: sdk:java:test
