@@ -2,7 +2,7 @@ name: Create OCWM Monthly
22
33on :
44 schedule :
5- - cron : " 0 23 * * 1 " # Runs at 11:00 PM every Monday
5+ - cron : " 0 23 * * 2 " # Runs at 11:00 PM every Tuesday
66
77 repository_dispatch :
88 types : ocwm-creator
@@ -36,39 +36,39 @@ jobs:
3636 # Get the first day of the next month
3737 next_month=$(date -u -d "$(date +%Y-%m-01) +1 month" +%Y-%m-01)
3838
39- # Find the first Monday of the next month
40- first_monday =$(date -u -d "$next_month +$(( (8 - $(date -u -d "$next_month" +%u)) % 7 )) days" +%Y-%m-%d)
39+ # Find the first Tuesday of the next month
40+ first_tuesday =$(date -u -d "$next_month +$(( (9 - $(date -u -d "$next_month" +%u)) % 7 )) days" +%Y-%m-%d)
4141
42- # Calculate the third Monday by adding 14 days to the first Monday
43- third_monday =$(date -u -d "$first_monday +14 days" +%Y-%m-%d)
42+ # Calculate the third Tuesday by adding 14 days to the first Tuesday
43+ third_tuesday =$(date -u -d "$first_tuesday +14 days" +%Y-%m-%d)
4444
45- # Output the issue title with the third Monday 's date
46- echo "title=Open Community Working Meeting ${third_monday } - 12:00 PT" >> "$GITHUB_OUTPUT"
45+ # Output the issue title with the third Tuesday 's date
46+ echo "title=Open Community Working Meeting ${third_tuesday } - 12:00 PT" >> "$GITHUB_OUTPUT"
4747
4848 # Step to check if it's the third Tuesday of the month
4949 - name : Check if today is the third Tuesday
50- id : check-third-monday
50+ id : check-third-tuesday
5151 run : |
5252 day=$(date +%d)
5353 dow=$(date +%u) # Day of the week (1 = Monday, ..., 7 = Sunday)
54- # Check if the day is between 15th and 21st, and if it's Monday (1 )
55- if [ "$dow" -ne 1 ]; then
56- echo "Not a Monday , exiting..."
57- echo "::set-output name=is-third-monday ::false"
54+ # Check if the day is between 15th and 21st, and if it's Tuesday (2 )
55+ if [ "$dow" -ne 2 ]; then
56+ echo "Not a Tuesday , exiting..."
57+ echo "::set-output name=is-third-tuesday ::false"
5858 exit 0
5959 fi
6060 if [ "$day" -ge 15 ] && [ "$day" -le 21 ]; then
61- echo "This is the third Monday of the month!"
62- echo "::set-output name=is-third-monday ::true"
61+ echo "This is the third Tuesday of the month!"
62+ echo "::set-output name=is-third-tuesday ::true"
6363 else
64- echo "Not the third Monday , exiting..."
65- echo "::set-output name=is-third-monday ::false"
64+ echo "Not the third Tuesday , exiting..."
65+ echo "::set-output name=is-third-tuesday ::false"
6666 exit 0
6767 fi
6868
6969 - name : Create Issue using Template
7070 id : create-issue
71- if : steps.check-third-tuesday.outputs.is-third-monday == 'true'
71+ if : steps.check-third-tuesday.outputs.is-third-tuesday == 'true'
7272 uses : peter-evans/create-issue-from-file@v5
7373 with :
7474 title : ${{ steps.create-title.outputs.title }}
0 commit comments