From 9d729f16752299a754083f5d5d6e2a950d5e16d5 Mon Sep 17 00:00:00 2001 From: Jan Hohenheim Date: Fri, 9 Feb 2024 05:59:04 +0100 Subject: [PATCH 1/8] Add GitHub Action for newsletter tracking issue --- .github/newsletter-template.md | 135 +++++++++++++++++++++++ .github/workflows/create-newsletter.yaml | 31 ++++++ newsletter-template.md | 135 ----------------------- 3 files changed, 166 insertions(+), 135 deletions(-) create mode 100644 .github/newsletter-template.md create mode 100644 .github/workflows/create-newsletter.yaml delete mode 100644 newsletter-template.md diff --git a/.github/newsletter-template.md b/.github/newsletter-template.md new file mode 100644 index 000000000..280dd9698 --- /dev/null +++ b/.github/newsletter-template.md @@ -0,0 +1,135 @@ +--- +title: "N{{ env.NEWSLETTER_COUNTER}}: {{ env.NEWSLETTER_MONTH }} {{ env.NEWSLETTER_YEAR }}" +labels: coordination, help wanted +--- + +# Newsletter {{ env.NEWSLETTER_COUNTER}}: {{ env.NEWSLETTER_MONTH }} {{ env.NEWSLETTER_YEAR }} + +###### tags: `newsletter` + +**Editors:** + +Another month has gone by, so it's time to put together the Rust Gamedev newsletter with {{ env.NEWSLETTER_MONTH }}'s news! + +## Current Schedule + +**The deadline for all section PRs is the 03.{{ env.NEWSLETTER_DEADLINE }}** + +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! + +## Current Structure & Status + +Below is our current planned structure for the newsletter, and the status of each PR (which we'll try to keep updated). + +This is **not** an exhaustive list - if you have your own project that you want to write about, just make a comment on this issue and open a PR! + +#### Rust Gamedev Meetup + + * [ ] Details of this month's meetup - 🆓 **free** (@AngelOnFira @ozkriff?) + +#### Game Updates + +#### Learning Material Updates + +#### Engine Updates + +#### Tooling Updates + +#### Library Updates + +#### Other News + + * [ ] Bullet points of any interesting news that doesn't have its own section - by @ozkrif + +#### Discussions + +## Publishing Steps + + * [ ] Final review - by everyone + + * [ ] Publish - by @ozkriff + + * [ ] Post on /r/rust, /r/rust_gamedev, /r/gamedev, URLO, twitter.com/rust_gamedev - by @ozkriff + + * [ ] Pin thread on Twitter - by @ozkriff + + * [ ] Add comment links - by @ozkriff + + * [ ] Add a draft of next month's newsletter - by @ozkriff + +## How to Contribute + +If you want to help writing the newsletter: + + * **Read [CONTRIBUTING.md](https://github.com/rust-gamedev/rust-gamedev.github.io/blob/source/CONTRIBUTING.md?rgh-link-date=2023-09-12T16%3A17%3A34Z).** + + * Choose one or more of the "🆓 **free**" sections listed below, and leave a comment letting us know you want to work on them. + + * The links in brackets (like "[1](#), [2](#), [3](#)") are suggestions of links to include in the section. Feel free to add more! + * The username listed next to the section (like "@ozkriff?") is a suggestion of who may want to pick up the work (usually the project's developer, or someone who has expressed interest in the past). + * You are not obligated to write a section if you're tagged or your project is listed! You're welcome to ask someone else to write the section, or to ask for your project to be excluded from this month's post. + * Extra sections not listed in the plan are welcomed - just leave a comment and open a PR! + + * Write a short overview in the newsletter's Markdown file, making sure to follow the style guidelines (see below). + + * Send a PR _to the `source` branch_ (example: [N15: A/B Street #336](https://github.com/rust-gamedev/rust-gamedev.github.io/pull/336)). + + * Mention this issue in your PR's description to link it all together. + +## Style Guidelines + +The full style guide is in [CONTRIBUTING.md](https://github.com/rust-gamedev/rust-gamedev.github.io/blob/source/CONTRIBUTING.md?rgh-link-date=2023-09-12T16%3A17%3A34Z), but here are the most important rules: + + * Write in third-person perspective. + + * Each line must be 80 characters or less, for ease of reviewing/diffing. + + * Only one image per section is allowed. + + * The maximum size is 300kb for static images and 2.5mb for GIFs. + * The image should come before the text, and must have alt text for accessibility. + * Prefer static images to GIFs, to keep the page load times down. + + * Each section should be under 1000 characters, and under 6 paragraphs. + + * This only applies to the rendered text, not the markup. + + * Keep formatting minimal - no bold/italics/etc. + + * Avoid long/nested bullet point lists - no changelogs! + +Please use these templates as a starting point: + +**Games/apps/libraries:** + +``` +### [Game name] + +![alt text](img) +_optional image label_ + +[Game name] ([GitHub], [Discord], [Twitter]) by [@nickname] +is... {short project description in one sentence}. + +{An overview of the recent updates with links to more details}. + +_Discussions: [/r/rust_gamedev](link), [Twitter](link), [etc](link)_ + +[Game name]: http://example.com +``` + +**Articles/blog posts/videos/etc:** + +``` +### [Article name] + +![alt text](img) +_optional image label_ + +[@nickname] published an [article] about... +{overview what the resource is about}. + +_Discussions: [/r/rust_gamedev](link), [Twiter](link), [etc](link)_ + +[Article name]: http://example.com +``` diff --git a/.github/workflows/create-newsletter.yaml b/.github/workflows/create-newsletter.yaml new file mode 100644 index 000000000..5300de21b --- /dev/null +++ b/.github/workflows/create-newsletter.yaml @@ -0,0 +1,31 @@ +name: Create Newsletter Tracking Issue +on: + schedule: + # Run on the 5th of every month at 12pm + - cron: "0 12 5 * *" + workflow_dispatch: + inputs: {} +permissions: + contents: read + issues: write +jobs: + create-newsletter: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Set newsletter month + run: echo "NEWSLETTER_MONTH=$(date +'%B')" >> $GITHUB_ENV + - name: Set newsletter year + run: echo "NEWSLETTER_YEAR=$(date +'%Y')" >> $GITHUB_ENV + - name: Set newsletter deadline + run: echo "NEWSLETTER_DEADLINE=$(date -d' 1 month ' '+%m.%Y')" >> $GITHUB_ENV + - name: Set newsletter counter + # take the amount of months since feb 2024 and add 50 + run: echo "NEWSLETTER_COUNTER=$(( ( ( $(date +'%Y') - 2024 ) * 12 + $(date +'%m') - 2 ) + 50 ))" >> $GITHUB_ENV + - name: Create tracking issue + uses: JasonEtco/create-an-issue@v2 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + filename: .github/newsletter-template.md + diff --git a/newsletter-template.md b/newsletter-template.md deleted file mode 100644 index 831ecd123..000000000 --- a/newsletter-template.md +++ /dev/null @@ -1,135 +0,0 @@ -+++ -title = "This Month in Rust GameDev #{TODO} - {TODO} {TODO}" -transparent = true -date = TODO -draft = true -+++ - - - - - -Welcome to the {TODO}th issue of the Rust GameDev Workgroup's -monthly newsletter. -[Rust] is a systems language pursuing the trifecta: -safety, concurrency, and speed. -These goals are well-aligned with game development. -We hope to build an inviting ecosystem for anyone wishing -to use Rust in their development process! -Want to get involved? [Join the Rust GameDev working group!][join] - -You can follow the newsletter creation process -by watching [the coordination issues][coordination]. -Want something mentioned in the next newsletter? -[Send us a pull request][pr]. -Feel free to send PRs about your own projects! - -[Rust]: https://rust-lang.org -[join]: https://github.com/rust-gamedev/wg#join-the-fun -[pr]: https://github.com/rust-gamedev/rust-gamedev.github.io -[coordination]: https://github.com/rust-gamedev/rust-gamedev.github.io/issues?q=label%3Acoordination - -- [Announcements](#announcements) -- [Game Updates](#game-updates) -- [Engine Updates](#engine-updates) -- [Learning Material Updates](#learning-material-updates) -- [Tooling Updates](#tooling-updates) -- [Library Updates](#library-updates) -- [Other News](#other-news) -- [Popular Workgroup Issues in Github](#popular-workgroup-issues-in-github) -- [Meeting Minutes](#meeting-minutes) -- [Discussions](#discussions) -- [Requests for Contribution](#requests-for-contribution) -- [Jobs](#jobs) -- [Bonus](#bonus) - - - -## Announcements - -## Game Updates - -## Engine Updates - -## Learning Material Updates - -## Tooling Updates - -## Library Updates - -## Popular Workgroup Issues in Github - - - -## Other News - - - -## Meeting Minutes - - - -[See all meeting issues][label_meeting] including full text notes -or [join the next meeting][join]. - -[label_meeting]: https://github.com/rust-gamedev/wg/issues?q=label%3Ameeting - -## Discussions - - - -## Requests for Contribution - - - -## Jobs - - - -## Bonus - - - ------- - -That's all news for today, thanks for reading! - -Want something mentioned in the next newsletter? -[Send us a pull request][pr]. - -Also, subscribe to [@rust_gamedev on Twitter][@rust_gamedev] -or [/r/rust_gamedev subreddit][/r/rust_gamedev] if you want to receive fresh news! - - - -[/r/rust_gamedev]: https://reddit.com/r/rust_gamedev -[@rust_gamedev]: https://twitter.com/rust_gamedev From 8665ecec386c7e527fe6517e99263f450ee4a257 Mon Sep 17 00:00:00 2001 From: Jan Hohenheim Date: Sat, 10 Feb 2024 03:06:18 +0100 Subject: [PATCH 2/8] Restore newsletter template --- newsletter-template.md | 135 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 135 insertions(+) create mode 100644 newsletter-template.md diff --git a/newsletter-template.md b/newsletter-template.md new file mode 100644 index 000000000..831ecd123 --- /dev/null +++ b/newsletter-template.md @@ -0,0 +1,135 @@ ++++ +title = "This Month in Rust GameDev #{TODO} - {TODO} {TODO}" +transparent = true +date = TODO +draft = true ++++ + + + + + +Welcome to the {TODO}th issue of the Rust GameDev Workgroup's +monthly newsletter. +[Rust] is a systems language pursuing the trifecta: +safety, concurrency, and speed. +These goals are well-aligned with game development. +We hope to build an inviting ecosystem for anyone wishing +to use Rust in their development process! +Want to get involved? [Join the Rust GameDev working group!][join] + +You can follow the newsletter creation process +by watching [the coordination issues][coordination]. +Want something mentioned in the next newsletter? +[Send us a pull request][pr]. +Feel free to send PRs about your own projects! + +[Rust]: https://rust-lang.org +[join]: https://github.com/rust-gamedev/wg#join-the-fun +[pr]: https://github.com/rust-gamedev/rust-gamedev.github.io +[coordination]: https://github.com/rust-gamedev/rust-gamedev.github.io/issues?q=label%3Acoordination + +- [Announcements](#announcements) +- [Game Updates](#game-updates) +- [Engine Updates](#engine-updates) +- [Learning Material Updates](#learning-material-updates) +- [Tooling Updates](#tooling-updates) +- [Library Updates](#library-updates) +- [Other News](#other-news) +- [Popular Workgroup Issues in Github](#popular-workgroup-issues-in-github) +- [Meeting Minutes](#meeting-minutes) +- [Discussions](#discussions) +- [Requests for Contribution](#requests-for-contribution) +- [Jobs](#jobs) +- [Bonus](#bonus) + + + +## Announcements + +## Game Updates + +## Engine Updates + +## Learning Material Updates + +## Tooling Updates + +## Library Updates + +## Popular Workgroup Issues in Github + + + +## Other News + + + +## Meeting Minutes + + + +[See all meeting issues][label_meeting] including full text notes +or [join the next meeting][join]. + +[label_meeting]: https://github.com/rust-gamedev/wg/issues?q=label%3Ameeting + +## Discussions + + + +## Requests for Contribution + + + +## Jobs + + + +## Bonus + + + +------ + +That's all news for today, thanks for reading! + +Want something mentioned in the next newsletter? +[Send us a pull request][pr]. + +Also, subscribe to [@rust_gamedev on Twitter][@rust_gamedev] +or [/r/rust_gamedev subreddit][/r/rust_gamedev] if you want to receive fresh news! + + + +[/r/rust_gamedev]: https://reddit.com/r/rust_gamedev +[@rust_gamedev]: https://twitter.com/rust_gamedev From 6aeb385bf781157e351e606ea8a1e5578deef801 Mon Sep 17 00:00:00 2001 From: Jan Hohenheim Date: Sat, 10 Feb 2024 04:01:19 +0100 Subject: [PATCH 3/8] Create newsletter scaffold --- ...mplate.md => newsletter-issue-template.md} | 0 .github/workflows/create-newsletter.yaml | 36 ++++++++++++------- newsletter-template.md | 4 +-- 3 files changed, 26 insertions(+), 14 deletions(-) rename .github/{newsletter-template.md => newsletter-issue-template.md} (100%) diff --git a/.github/newsletter-template.md b/.github/newsletter-issue-template.md similarity index 100% rename from .github/newsletter-template.md rename to .github/newsletter-issue-template.md diff --git a/.github/workflows/create-newsletter.yaml b/.github/workflows/create-newsletter.yaml index 5300de21b..8115c9662 100644 --- a/.github/workflows/create-newsletter.yaml +++ b/.github/workflows/create-newsletter.yaml @@ -1,4 +1,4 @@ -name: Create Newsletter Tracking Issue +name: Create Newsletter on: schedule: # Run on the 5th of every month at 12pm @@ -6,26 +6,38 @@ on: workflow_dispatch: inputs: {} permissions: - contents: read + contents: write issues: write jobs: create-newsletter: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Set newsletter month - run: echo "NEWSLETTER_MONTH=$(date +'%B')" >> $GITHUB_ENV - - name: Set newsletter year - run: echo "NEWSLETTER_YEAR=$(date +'%Y')" >> $GITHUB_ENV - - name: Set newsletter deadline - run: echo "NEWSLETTER_DEADLINE=$(date -d' 1 month ' '+%m.%Y')" >> $GITHUB_ENV - - name: Set newsletter counter - # take the amount of months since feb 2024 and add 50 - run: echo "NEWSLETTER_COUNTER=$(( ( ( $(date +'%Y') - 2024 ) * 12 + $(date +'%m') - 2 ) + 50 ))" >> $GITHUB_ENV + - name: Set environment variables + run: | + echo "NEWSLETTER_MONTH=$(date +'%B')" >> $GITHUB_ENV + echo "NEWSLETTER_YEAR=$(date +'%Y')" >> $GITHUB_ENV + echo "NEWSLETTER_DEADLINE=$(date -d' 1 month ' '+%m.%Y')" >> $GITHUB_ENV + # take the amount of months since feb 2024 and add 50 + echo "NEWSLETTER_COUNTER=$(( ( ( $(date +'%Y') - 2024 ) * 12 + $(date +'%m') - 2 ) + 50 ))" >> $GITHUB_ENV + - name: Create newsletter scaffold + run: | + cp newsletter-template.md index.md + sed -i "s/{{\s*NEWSLETTER_MONTH\s*}}/${{ env.NEWSLETTER_MONTH }}/g" index.md + sed -i "s/{{\s*NEWSLETTER_YEAR\s*}}/${{ env.NEWSLETTER_YEAR }}/g" index.md + sed -i "s/{{\s*NEWSLETTER_DEADLINE\s*}}/${{ env.NEWSLETTER_DEADLINE }}/g" index.md + sed -i "s/{{\s*NEWSLETTER_COUNTER\s*}}/${{ env.NEWSLETTER_COUNTER }}/g" index.md + # Create a dir in content/news with the counter with 3 digits as name + mkdir -p content/news/$(printf "%03d" ${{ env.NEWSLETTER_COUNTER }}) + mv index.md content/news/$(printf "%03d" ${{ env.NEWSLETTER_COUNTER }}) + - name: Commit and push changes + uses: EndBug/add-and-commit@v9 + with: + message: "Create newsletter N${{ env.NEWSLETTER_COUNTER }} for ${{ env.NEWSLETTER_MONTH }} ${{ env.NEWSLETTER_YEAR }}" - name: Create tracking issue uses: JasonEtco/create-an-issue@v2 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: - filename: .github/newsletter-template.md + filename: .github/newsletter-issue-template.md diff --git a/newsletter-template.md b/newsletter-template.md index 831ecd123..0aa26e7f4 100644 --- a/newsletter-template.md +++ b/newsletter-template.md @@ -1,5 +1,5 @@ +++ -title = "This Month in Rust GameDev #{TODO} - {TODO} {TODO}" +title = "This Month in Rust GameDev #{{ NEWSLETTER_COUNTER }} - {{ NEWSLETTER_MONTH }} {{ NEWSLETTER_YEAR }}" transparent = true date = TODO draft = true @@ -9,7 +9,7 @@ draft = true -Welcome to the {TODO}th issue of the Rust GameDev Workgroup's +Welcome to the {{ NEWSLETTER_COUNTER }}th issue of the Rust GameDev Workgroup's monthly newsletter. [Rust] is a systems language pursuing the trifecta: safety, concurrency, and speed. From c6992dacaeab0a23740bd27fabffc2a0cb0dd2a4 Mon Sep 17 00:00:00 2001 From: Jan Hohenheim Date: Mon, 25 Mar 2024 20:48:53 +0100 Subject: [PATCH 4/8] Refactor issue template --- .github/newsletter-issue-template.md | 123 ++++++++++++++------------- 1 file changed, 63 insertions(+), 60 deletions(-) diff --git a/.github/newsletter-issue-template.md b/.github/newsletter-issue-template.md index 280dd9698..7f670d7ef 100644 --- a/.github/newsletter-issue-template.md +++ b/.github/newsletter-issue-template.md @@ -1,108 +1,111 @@ --- -title: "N{{ env.NEWSLETTER_COUNTER}}: {{ env.NEWSLETTER_MONTH }} {{ env.NEWSLETTER_YEAR }}" +title: "Newsletter {{ env.NEWSLETTER_COUNTER}}: {{ env.NEWSLETTER_MONTH }} {{ env.NEWSLETTER_YEAR }}" labels: coordination, help wanted +assignees: janhohenheim --- -# Newsletter {{ env.NEWSLETTER_COUNTER}}: {{ env.NEWSLETTER_MONTH }} {{ env.NEWSLETTER_YEAR }} - ###### tags: `newsletter` **Editors:** -Another month has gone by, so it's time to put together the Rust Gamedev newsletter with {{ env.NEWSLETTER_MONTH }}'s news! +Another month has gone by, so it's time to put together the Rust Gamedev +newsletter with {{ env.NEWSLETTER_MONTH }}'s news! ## Current Schedule -**The deadline for all section PRs is the 03.{{ env.NEWSLETTER_DEADLINE }}** +The deadline for all section PRs is the **03.{{ env.NEWSLETTER_DEADLINE }}** -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! +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! ## Current Structure & Status -Below is our current planned structure for the newsletter, and the status of each PR (which we'll try to keep updated). - -This is **not** an exhaustive list - if you have your own project that you want to write about, just make a comment on this issue and open a PR! +Below is our current planned structure for the newsletter, +and the status of each PR (which we'll try to keep updated). -#### Rust Gamedev Meetup +This is **not** an exhaustive list - if you have your own project that you want +to write about, just make a comment on this issue and open a PR! - * [ ] Details of this month's meetup - 🆓 **free** (@AngelOnFira @ozkriff?) +### Game Updates -#### Game Updates +- TODO -#### Learning Material Updates +### Learning Material Updates -#### Engine Updates +- TODO -#### Tooling Updates +### Engine Updates -#### Library Updates +- TODO -#### Other News +### Tooling Updates - * [ ] Bullet points of any interesting news that doesn't have its own section - by @ozkrif +- TODO -#### Discussions +### Library Updates -## Publishing Steps +- TODO - * [ ] Final review - by everyone +### Other News - * [ ] Publish - by @ozkriff +- TODO - * [ ] Post on /r/rust, /r/rust_gamedev, /r/gamedev, URLO, twitter.com/rust_gamedev - by @ozkriff +### Discussions - * [ ] Pin thread on Twitter - by @ozkriff +- TODO - * [ ] Add comment links - by @ozkriff +## Publishing Steps - * [ ] Add a draft of next month's newsletter - by @ozkriff +- [ ] Final review - by everyone +- [ ] Publish - by @janhohenheim +- [ ] Post on /r/rust, /r/rust_gamedev, /r/gamedev, URLO - by @janhohenheim +- [ ] Pin thread on Twitter - by @AngelOnFira +- [ ] Add comment links - by @AngelOnFira ## How to Contribute If you want to help writing the newsletter: - * **Read [CONTRIBUTING.md](https://github.com/rust-gamedev/rust-gamedev.github.io/blob/source/CONTRIBUTING.md?rgh-link-date=2023-09-12T16%3A17%3A34Z).** - - * Choose one or more of the "🆓 **free**" sections listed below, and leave a comment letting us know you want to work on them. - - * The links in brackets (like "[1](#), [2](#), [3](#)") are suggestions of links to include in the section. Feel free to add more! - * The username listed next to the section (like "@ozkriff?") is a suggestion of who may want to pick up the work (usually the project's developer, or someone who has expressed interest in the past). - * You are not obligated to write a section if you're tagged or your project is listed! You're welcome to ask someone else to write the section, or to ask for your project to be excluded from this month's post. - * Extra sections not listed in the plan are welcomed - just leave a comment and open a PR! - - * Write a short overview in the newsletter's Markdown file, making sure to follow the style guidelines (see below). - - * Send a PR _to the `source` branch_ (example: [N15: A/B Street #336](https://github.com/rust-gamedev/rust-gamedev.github.io/pull/336)). - - * Mention this issue in your PR's description to link it all together. +- **Read [CONTRIBUTING.md](https://github.com/rust-gamedev/rust-gamedev.github.io/blob/source/CONTRIBUTING.md?rgh-link-date=2023-09-12T16%3A17%3A34Z).** +- Choose one or more of the "🆓 **free**" sections listed below, and leave a +comment letting us know you want to work on them. + - The links in brackets (like `[1](#), [2](#), [3](#)`) are suggestions of + links to include in the section. Feel free to add more! + - The username listed next to the section (like `@janhohenheim?`) is a + suggestion of who may want to pick up the work (usually the project's + developer, or someone who has expressed interest in the past). + - You are not obligated to write a section if you're tagged or your project + is listed! You're welcome to ask someone else to write the section, + or to ask for your project to be excluded from this month's post. + - Extra sections not listed in the plan are welcomed - + just leave a comment and open a PR! +- Write a short overview in the newsletter's Markdown file, +making sure to follow the style guidelines (see below). +- Send a PR _to the `source` branch_ (example: [N15: A/B Street #336](https://github.com/rust-gamedev/rust-gamedev.github.io/pull/336)). +- Mention this issue in your PR's description to link it all together. ## Style Guidelines -The full style guide is in [CONTRIBUTING.md](https://github.com/rust-gamedev/rust-gamedev.github.io/blob/source/CONTRIBUTING.md?rgh-link-date=2023-09-12T16%3A17%3A34Z), but here are the most important rules: +The full style guide is in [CONTRIBUTING.md](https://github.com/rust-gamedev/rust-gamedev.github.io/blob/source/CONTRIBUTING.md?rgh-link-date=2023-09-12T16%3A17%3A34Z), +but here are the most important rules: - * Write in third-person perspective. - - * Each line must be 80 characters or less, for ease of reviewing/diffing. - - * Only one image per section is allowed. - - * The maximum size is 300kb for static images and 2.5mb for GIFs. - * The image should come before the text, and must have alt text for accessibility. - * Prefer static images to GIFs, to keep the page load times down. - - * Each section should be under 1000 characters, and under 6 paragraphs. - - * This only applies to the rendered text, not the markup. - - * Keep formatting minimal - no bold/italics/etc. - - * Avoid long/nested bullet point lists - no changelogs! +- Write in third-person perspective. +- Each line must be 80 characters or less, for ease of reviewing/diffing. +- Only one image per section is allowed. + - The maximum size is 300kb for static images and 2.5mb for GIFs. + - The image should come before the text, and must have alt text for accessibility. + - Prefer static images to GIFs, to keep the page load times down. +- Each section should be under 1000 characters, and under 6 paragraphs. + - This only applies to the rendered text, not the markup. +- Keep formatting minimal - no bold/italics/etc. +- Avoid long/nested bullet point lists - no changelogs! Please use these templates as a starting point: **Games/apps/libraries:** -``` +```md ### [Game name] ![alt text](img) @@ -120,7 +123,7 @@ _Discussions: [/r/rust_gamedev](link), [Twitter](link), [etc](link)_ **Articles/blog posts/videos/etc:** -``` +```md ### [Article name] ![alt text](img) From 8f0064ef00ba5f06a3e0fd2f92cd61c9ed4c9dbb Mon Sep 17 00:00:00 2001 From: Jan Hohenheim Date: Mon, 25 Mar 2024 20:49:39 +0100 Subject: [PATCH 5/8] Refactor issue action --- .github/workflows/create-newsletter.yaml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/create-newsletter.yaml b/.github/workflows/create-newsletter.yaml index 8115c9662..654b98a11 100644 --- a/.github/workflows/create-newsletter.yaml +++ b/.github/workflows/create-newsletter.yaml @@ -28,8 +28,10 @@ jobs: sed -i "s/{{\s*NEWSLETTER_DEADLINE\s*}}/${{ env.NEWSLETTER_DEADLINE }}/g" index.md sed -i "s/{{\s*NEWSLETTER_COUNTER\s*}}/${{ env.NEWSLETTER_COUNTER }}/g" index.md # Create a dir in content/news with the counter with 3 digits as name - mkdir -p content/news/$(printf "%03d" ${{ env.NEWSLETTER_COUNTER }}) - mv index.md content/news/$(printf "%03d" ${{ env.NEWSLETTER_COUNTER }}) + destination="content/news/$(printf "%03d" ${{ env.NEWSLETTER_COUNTER }})" + mkdir -p $destination + mv index.md $destination/index.md + git status - name: Commit and push changes uses: EndBug/add-and-commit@v9 with: From d642ea787c4bdf019a7d4c0a3ee0858fbbd3e5ac Mon Sep 17 00:00:00 2001 From: Jan Hohenheim Date: Mon, 25 Mar 2024 22:18:36 +0100 Subject: [PATCH 6/8] Incorporate feedback --- .github/create_newsletter_scaffold.sh | 34 ++++++++++++++++++++++++ .github/workflows/create-newsletter.yaml | 15 +++-------- 2 files changed, 38 insertions(+), 11 deletions(-) create mode 100755 .github/create_newsletter_scaffold.sh diff --git a/.github/create_newsletter_scaffold.sh b/.github/create_newsletter_scaffold.sh new file mode 100755 index 000000000..9cddc71b6 --- /dev/null +++ b/.github/create_newsletter_scaffold.sh @@ -0,0 +1,34 @@ +#!/usr/bin/env bash + +set -euo pipefail + +if [[ -z "${NEWSLETTER_MONTH}" ]]; then + echo "NEWSLETTER_MONTH is not set. Exiting..." + exit 1 +fi + +if [[ -z "${NEWSLETTER_YEAR}" ]]; then + echo "NEWSLETTER_YEAR is not set. Exiting..." + exit 1 +fi + +if [[ -z "${NEWSLETTER_DEADLINE}" ]]; then + echo "NEWSLETTER_DEADLINE is not set. Exiting..." + exit 1 +fi + +if [[ -z "${NEWSLETTER_COUNTER}" ]]; then + echo "NEWSLETTER_COUNTER is not set. Exiting..." + exit 1 +fi + +cp newsletter-template.md index.md +sed -i "s/{{\s*NEWSLETTER_MONTH\s*}}/${NEWSLETTER_MONTH}/g" index.md +sed -i "s/{{\s*NEWSLETTER_YEAR\s*}}/${NEWSLETTER_YEAR}/g" index.md +sed -i "s/{{\s*NEWSLETTER_DEADLINE\s*}}/${NEWSLETTER_DEADLINE}/g" index.md +sed -i "s/{{\s*NEWSLETTER_COUNTER\s*}}/${NEWSLETTER_COUNTER}/g" index.md +# Create a dir in content/news with the counter with 3 digits as name +destination="content/news/$(printf "%03d" ${NEWSLETTER_COUNTER})" +mkdir -p $destination +mv index.md $destination/index.md +git status \ No newline at end of file diff --git a/.github/workflows/create-newsletter.yaml b/.github/workflows/create-newsletter.yaml index 654b98a11..8e20ee866 100644 --- a/.github/workflows/create-newsletter.yaml +++ b/.github/workflows/create-newsletter.yaml @@ -13,6 +13,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 + with: + ref: source - name: Set environment variables run: | echo "NEWSLETTER_MONTH=$(date +'%B')" >> $GITHUB_ENV @@ -21,21 +23,12 @@ jobs: # take the amount of months since feb 2024 and add 50 echo "NEWSLETTER_COUNTER=$(( ( ( $(date +'%Y') - 2024 ) * 12 + $(date +'%m') - 2 ) + 50 ))" >> $GITHUB_ENV - name: Create newsletter scaffold - run: | - cp newsletter-template.md index.md - sed -i "s/{{\s*NEWSLETTER_MONTH\s*}}/${{ env.NEWSLETTER_MONTH }}/g" index.md - sed -i "s/{{\s*NEWSLETTER_YEAR\s*}}/${{ env.NEWSLETTER_YEAR }}/g" index.md - sed -i "s/{{\s*NEWSLETTER_DEADLINE\s*}}/${{ env.NEWSLETTER_DEADLINE }}/g" index.md - sed -i "s/{{\s*NEWSLETTER_COUNTER\s*}}/${{ env.NEWSLETTER_COUNTER }}/g" index.md - # Create a dir in content/news with the counter with 3 digits as name - destination="content/news/$(printf "%03d" ${{ env.NEWSLETTER_COUNTER }})" - mkdir -p $destination - mv index.md $destination/index.md - git status + run: ./.github/create_newsletter_scaffold.sh - name: Commit and push changes uses: EndBug/add-and-commit@v9 with: message: "Create newsletter N${{ env.NEWSLETTER_COUNTER }} for ${{ env.NEWSLETTER_MONTH }} ${{ env.NEWSLETTER_YEAR }}" + push: "origin HEAD:source" - name: Create tracking issue uses: JasonEtco/create-an-issue@v2 env: From 05c91f966d58cd8a78f8ffdb3ced9ae23ec3a1fe Mon Sep 17 00:00:00 2001 From: Jan Hohenheim Date: Mon, 25 Mar 2024 22:20:33 +0100 Subject: [PATCH 7/8] Add terminal newline --- .github/create_newsletter_scaffold.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/create_newsletter_scaffold.sh b/.github/create_newsletter_scaffold.sh index 9cddc71b6..307fa8012 100755 --- a/.github/create_newsletter_scaffold.sh +++ b/.github/create_newsletter_scaffold.sh @@ -31,4 +31,4 @@ sed -i "s/{{\s*NEWSLETTER_COUNTER\s*}}/${NEWSLETTER_COUNTER}/g" index.md destination="content/news/$(printf "%03d" ${NEWSLETTER_COUNTER})" mkdir -p $destination mv index.md $destination/index.md -git status \ No newline at end of file +git status From f1b2a8026f06a3a2b15ce50e775a0e005d42c019 Mon Sep 17 00:00:00 2001 From: Jan Hohenheim Date: Tue, 9 Apr 2024 10:14:14 +0200 Subject: [PATCH 8/8] Set target date --- newsletter-template.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/newsletter-template.md b/newsletter-template.md index 614e0c9e4..e6f93c37a 100644 --- a/newsletter-template.md +++ b/newsletter-template.md @@ -1,7 +1,7 @@ +++ title = "This Month in Rust GameDev #{{ NEWSLETTER_COUNTER }} - {{ NEWSLETTER_MONTH }} {{ NEWSLETTER_YEAR }}" transparent = true -date = TODO +date = {{ NEWSLETTER_DEADLINE }} draft = true +++