Skip to content

Commit

Permalink
GHA for TOC review reminder (#1502)
Browse files Browse the repository at this point in the history
* new format

* TOC review reminder GHA
  • Loading branch information
krsna-m authored Feb 1, 2024
1 parent 541c409 commit fa4340e
Show file tree
Hide file tree
Showing 2 changed files with 74 additions and 28 deletions.
59 changes: 59 additions & 0 deletions .github/workflows/toc-review-reminder.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# Copyright 2024 The Knative Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

name: 'TOC review reminder'

on:
workflow_dispatch:
schedule: ## At 09:00 on Mondays
- cron: 0 9 * * MON

jobs:
remind:
name: toc-review-reminder
runs-on: 'ubuntu-latest'

steps:
- name: checkout TOC-REVIEW.schedule
uses: actions/checkout@v4
with:
repository: knative/community
sparse-checkout: |
mechanics/TOC-REVIEW.schedule
sparse-checkout-cone-mode: false

- name: check who is scheduled this week
id: schedule
run: |
SLACK_MSG="NONE"
SCHED=$(cat mechanics/TOC-REVIEW.schedule | grep $(date --date="next wednesday" +%F) || true)
if [[ $SCHED ]]; then
DATE=$(echo $SCHED | cut -d '|' -f 1 | xargs)
WG=$(echo $SCHED | cut -d '|' -f 2 | xargs)
MEMBERS=$(echo $SCHED | cut -d '|' -f 3 | xargs)
SLACK_MSG="The $WG is up for TOC review on $DATE. $MEMBERS"
fi
echo "result=${SLACK_MSG}" >> "$GITHUB_OUTPUT"
- name: Post reminder to Slack
if: steps.schedule.outputs.result != 'NONE'
uses: rtCamp/[email protected]
env:
SLACK_ICON: http://github.com/knative.png?size=48
SLACK_USERNAME: github-actions
SLACK_TITLE: TOC review reminder
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
MSG_MINIMAL: 'true'
SLACK_CHANNEL: 'knative-contributors'
SLACK_MESSAGE: ${{ steps.schedule.outputs.result }}
43 changes: 15 additions & 28 deletions mechanics/TOC-REVIEW.schedule
Original file line number Diff line number Diff line change
@@ -1,28 +1,15 @@
#@ title: ToC Working Group Update
#@ duration: 45m

# To generate reminders (on a mac):
# awk -F \| '/^[0-9]/ {cmd "/bin/date -j -f %FT%T " substr($1, 0, 19) " +%e\\ %b" | getline date; cmd "/bin/date -j -f %FT%T -v-4d " substr($1, 0, 19) " +%b\\ %e" | getline reminder; print "/remind #knative-leads " $2 " is presenting at TOC on " date " (this week) :heart: " reminder}' mechanics/TOC-REVIEW.schedule

# Start | Group
2023-10-26T08:30:00-07:00 | Functions WG
# 2023-11-09T08:30:00-07:00 | skip - KubeCon Eventing WG
# 2023-11-23T08:30:00-07:00 | skip - US holiday
2023-12-07T08:30:00-07:00 | Eventing WG
# 2023-12-21T08:30:00-07:00 | skip
# 2024-01-04T08:30:00-07:00 | skip - moving to Wednesdays
2024-01-17T10:00:00-04:00 | skip
2024-01-31T10:00:00-04:00 | Security WG
2024-02-14T10:00:00-04:00 | Productivity WG
2024-02-28T10:00:00-04:00 | UX WG
2024-03-13T10:00:00-04:00 | Client WG
2024-03-27T10:00:00-04:00 | Serving API WG
2024-04-10T10:00:00-04:00 | Operations WG
2024-04-24T10:00:00-04:00 | Functions WG
2024-05-08T10:00:00-04:00 | Eventing WG
2024-05-22T10:00:00-04:00 | Security WG
2024-06-05T10:00:00-04:00 | Productivity WG
2024-06-19T10:00:00-04:00 | UX WG
2024-07-03T10:00:00-04:00 | Client WG
2024-07-17T10:00:00-04:00 | Serving API WG
2024-07-31T10:00:00-04:00 | Operations WG
# Date in %F format ie: YYYY-DD-MM | Working Group | Members to be notified
2024-02-14 | Security WG | @Evan Anderson @David Hadas
2024-02-28 | Productivity WG | @Krsna Mahapatra @Mahamed Ali
2024-03-13 | UX WG | @cali0707 @leo6leo @mmejia02 @zainabhusain227
2024-03-27 | Client WG | @dsimansk @Navid Shaikh @Roland Huss
2024-04-10 | Serving API WG | @dprotaso
2024-04-24 | Operations WG | @houshengbo
2024-05-08 | Functions WG | @lkingland @salaboy
2024-05-22 | Eventing WG | @pierDipi
2024-06-05 | Security WG | @Evan Anderson @David Hadas
2024-06-19 | Productivity WG | @Krsna Mahapatra @Mahamed Ali
2024-07-03 | UX WG | @cali0707 @leo6leo @mmejia02 @zainabhusain227
2024-07-17 | Client WG | @dsimansk @Navid Shaikh @Roland Huss
2024-07-31 | Serving API WG | @dprotaso
2024-08-14 | Operations WG | @houshengbo

0 comments on commit fa4340e

Please sign in to comment.