Skip to content

Commit

Permalink
Merge pull request #10 from nigeljamesstevenson/update/workflow-for-r…
Browse files Browse the repository at this point in the history
…est-api-slack-notifications

Update/workflow for rest api slack notifications
  • Loading branch information
nigeljamesstevenson authored May 8, 2024
2 parents 8c976b5 + d46c99b commit c53a939
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 49 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/test-assistant-api-rest-change-tracker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ jobs:
run: sleep 2m
shell: bash

- name: Checkout repository
uses: actions/checkout@v2

- name: Calculate test date
id: calculate_date
run: |
Expand Down
56 changes: 7 additions & 49 deletions .github/workflows/test-assistant-release-highlight-tracker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ jobs:
run: sleep 2m
shell: bash

- name: Checkout repository
uses: actions/checkout@v2

- name: Calculate test date
id: calculate_date
run: |
Expand All @@ -40,55 +43,10 @@ jobs:
- name: Determine Milestone Date
id: get_milestone_date
run: |
#!/bin/bash
MILESTONE_TITLE="${{ github.event.pull_request.milestone.title }}"
MILESTONE_DATE="Undefined"
# Mapping of milestone titles to release dates
declare -A MILESTONE_DATES
MILESTONE_DATES=(
["8.0.0"]="2023-08-08"
["8.1.0"]="2023-09-12"
["8.2.0"]="2023-10-10"
["8.3.0"]="2023-11-14"
["8.4.0"]="2023-12-12"
["8.5.0"]="2024-01-09"
["8.6.0"]="2024-02-13"
["8.7.0"]="2024-03-12"
["8.8.0"]="2024-04-09"
["8.9.0"]="2024-05-14"
["9.0.0"]="2024-06-11"
["9.1.0"]="2024-07-09"
["9.2.0"]="2024-08-13"
["9.3.0"]="2024-09-10"
["9.4.0"]="2024-10-08"
["9.5.0"]="2024-11-12"
["9.6.0"]="2024-12-10"
["9.7.0"]="2025-01-14"
["9.8.0"]="2025-02-11"
["9.9.0"]="2025-03-11"
["10.0.0"]="2025-04-08"
["10.1.0"]="2025-05-13"
["10.2.0"]="2025-06-10"
["10.3.0"]="2025-07-08"
["10.4.0"]="2025-08-12"
["10.5.0"]="2025-09-09"
["10.6.0"]="2025-10-14"
["10.7.0"]="2025-11-11"
["10.8.0"]="2025-12-09"
["10.9.0"]="2026-01-13"
["11.0.0"]="2026-02-10"
)
# Check if the milestone title exists in our predefined list and get the date
if [[ -v "MILESTONE_DATES[${MILESTONE_TITLE}]" ]]; then
MILESTONE_DATE=${MILESTONE_DATES[${MILESTONE_TITLE}]}
fi
# Export for later steps
echo "MILESTONE_DATE=${MILESTONE_DATE}" >> $GITHUB_ENV
working-directory: .github/workflows/scripts
run: bash determine_milestone_date.sh
env:
GITHUB_EVENT_PATH_PULL_REQUEST_MILESTONE_TITLE: ${{ github.event.pull_request.milestone.title }}

# Notify Slack Step
- name: Notify Slack
Expand Down

0 comments on commit c53a939

Please sign in to comment.