# Copyright 2022 The Knative Authors.
# SPDX-License-Identifier: Apache-2.0

# This file is automagically synced here from github.com/knative-sandbox/knobots

name: 'Releasability'

on:
  schedule:
    - cron: '0 1 * * 1-5' # 6am Pacific, weekdays.

  workflow_dispatch:      # Manual trigger.
    inputs:
      releaseFamily:
        description: 'Release? (vX.Y)'
        required: false
      moduleReleaseFamily:
        description: 'Module Release? (vX.Y)'
        required: false
      slackChannel:
        description: 'Slack Channel? (release-#)'
        required: false

jobs:
  releasability:
    uses: knative/actions/.github/workflows/releasability.yaml@main
    with:
      releaseFamily: ${{ github.event.inputs.releaseFamily || 'v1.9' }}
      moduleReleaseFamily: ${{ github.event.inputs.moduleReleaseFamily || 'v0.36' }}
      slackChannel: ${{ github.event.inputs.slackChannel || 'release' }}
    secrets:
      SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
