Skip to content

Commit 0f99dd5

Browse files
committed
Fix dates
1 parent 7590722 commit 0f99dd5

File tree

4 files changed

+13
-20
lines changed

4 files changed

+13
-20
lines changed

.github/create_newsletter_scaffold.sh

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,6 @@ if [[ -z "${NEWSLETTER_YEAR}" ]]; then
1212
exit 1
1313
fi
1414

15-
if [[ -z "${NEWSLETTER_DEADLINE}" ]]; then
16-
echo "NEWSLETTER_DEADLINE is not set. Exiting..."
17-
exit 1
18-
fi
19-
2015
if [[ -z "${NEWSLETTER_COUNTER}" ]]; then
2116
echo "NEWSLETTER_COUNTER is not set. Exiting..."
2217
exit 1
@@ -25,7 +20,6 @@ fi
2520
cp .github/newsletter-template.md index.md
2621
sed -i "s/{{\s*NEWSLETTER_MONTH\s*}}/${NEWSLETTER_MONTH}/g" index.md
2722
sed -i "s/{{\s*NEWSLETTER_YEAR\s*}}/${NEWSLETTER_YEAR}/g" index.md
28-
sed -i "s/{{\s*NEWSLETTER_DEADLINE\s*}}/${NEWSLETTER_DEADLINE}/g" index.md
2923
sed -i "s/{{\s*NEWSLETTER_COUNTER\s*}}/${NEWSLETTER_COUNTER}/g" index.md
3024
# Create a dir in content/news with the counter with 3 digits as name
3125
destination="content/news/$(printf "%03d" ${NEWSLETTER_COUNTER})"

.github/newsletter-issue-template.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ newsletter with {{ env.NEWSLETTER_MONTH }}'s news!
1313

1414
## Current Schedule
1515

16-
The deadline for all section PRs is the **3rd of {{ env.NEWSLETTER_MONTH_NAME}}, {{ env.NEWSLETTER_YEAR }}**
16+
The deadline for all section PRs is the **3rd of {{ env.NEWSLETTER_NEXT_MONTH}}, {{ env.NEWSLETTER_YEAR }}**
1717

1818
We _may_ still accept PRs that are submitted later than this, as long as they're ready before the newsletter's release, but this isn't guaranteed. If you want your section to be included, don't leave it till the last minute!
1919

@@ -53,11 +53,11 @@ This is **not** an exhaustive list - if you have your own project that you want
5353

5454
## Publishing Steps
5555

56-
- [ ] Final review - by everyone
57-
- [ ] Publish - by @janhohenheim
58-
- [ ] Post on /r/rust, /r/rust_gamedev, /r/gamedev, URLO - by @janhohenheim
59-
- [ ] Pin thread on Twitter - by @AngelOnFira
60-
- [ ] Add comment links - by @AngelOnFira
56+
- [ ] Final review - by everyone
57+
- [ ] Publish - by @janhohenheim
58+
- [ ] Post on /r/rust, /r/rust_gamedev, /r/gamedev, URLO - by @janhohenheim
59+
- [ ] Pin thread on Twitter - by @AngelOnFira
60+
- [ ] Add comment links - by @AngelOnFira
6161

6262
## How to Contribute
6363

.github/newsletter-template.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
+++
22
title = "This Month in Rust GameDev #{{ NEWSLETTER_COUNTER }} - {{ NEWSLETTER_MONTH }} {{ NEWSLETTER_YEAR }}"
33
transparent = true
4-
date = {{ NEWSLETTER_YEAR }}-{{ NEWSLETTER_MONTH }}-03
4+
date = {{ NEWSLETTER_YEAR }}-{{ NEWSLETTER_NEXT_MONTH }}-03
55
draft = true
66
+++
77

@@ -112,7 +112,7 @@ useful information -->
112112
<!-- Bonus section to make the newsletter more interesting
113113
and highlight events from the past. -->
114114

115-
------
115+
---
116116

117117
That's all news for today, thanks for reading!
118118

.github/workflows/create-newsletter.yaml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77
inputs: {}
88
permissions:
99
contents: write
10-
issues: write
10+
issues: write
1111
jobs:
1212
create-newsletter:
1313
runs-on: ubuntu-latest
@@ -18,9 +18,8 @@ jobs:
1818
- name: Set environment variables
1919
run: |
2020
echo "NEWSLETTER_MONTH=$(date +'%B')" >> $GITHUB_ENV
21-
echo "NEWSLETTER_MONTH_NAME=$(date +'%b')" >> $GITHUB_ENV
21+
echo "NEWSLETTER_NEXT_MONTH=$(date -d' 1 month ' +'%B')" >> $GITHUB_ENV
2222
echo "NEWSLETTER_YEAR=$(date +'%Y')" >> $GITHUB_ENV
23-
echo "NEWSLETTER_DEADLINE=$(date -d' 1 month ' '+%m.%Y')" >> $GITHUB_ENV
2423
# take the amount of months since feb 2024 and add 50
2524
echo "NEWSLETTER_COUNTER=$(( ( ( $(date +'%Y') - 2024 ) * 12 + $(date +'%m') - 4 ) + 50 ))" >> $GITHUB_ENV
2625
- name: Create newsletter scaffold
@@ -33,9 +32,9 @@ jobs:
3332
title: "Newsletter N${{ env.NEWSLETTER_COUNTER }} for ${{ env.NEWSLETTER_MONTH }} ${{ env.NEWSLETTER_YEAR }}"
3433
body: "This PR adds the initial newsletter source file for ${{ env.NEWSLETTER_MONTH }} ${{ env.NEWSLETTER_YEAR }}."
3534
assignees: |
36-
AngelOnFira
37-
janhohenheim
38-
mamaicode
35+
AngelOnFira
36+
janhohenheim
37+
mamaicode
3938
- name: Create tracking issue
4039
uses: JasonEtco/create-an-issue@v2
4140
env:

0 commit comments

Comments
 (0)