From a0bdfa8b8e24ce31610eb55977ac4096bbd31e96 Mon Sep 17 00:00:00 2001 From: Pavel Borisov Date: Tue, 10 Jan 2023 11:50:54 +0300 Subject: [PATCH 1/6] Split planetpg rss into separate feed by author --- apps/www/pages/blog.tsx | 36 ++++++- apps/www/public/planetpg-rss.xml | 159 ------------------------------- 2 files changed, 33 insertions(+), 162 deletions(-) delete mode 100644 apps/www/public/planetpg-rss.xml diff --git a/apps/www/pages/blog.tsx b/apps/www/pages/blog.tsx index 49eb7c8351f..5b81312706b 100644 --- a/apps/www/pages/blog.tsx +++ b/apps/www/pages/blog.tsx @@ -21,14 +21,44 @@ export async function getStaticProps() { const rss = generateRss(allPostsData) // @ts-ignore const planetPgPosts = allPostsData.filter((post) => post.tags.includes('planetpg')) - const planetPgrss = generateRss(planetPgPosts) + + const planetPgPavel = planetPgPosts.filter((post) => post.author.includes('pavel')) + const planetPgAlexander = planetPgPosts.filter((post) => post.author.includes('alexander')) + const planetPgMichel = planetPgPosts.filter((post) => post.author.includes('michel')) + const planetPgSteve = planetPgPosts.filter((post) => post.author.includes('steve_chavez')) + const planetPgAngelico = planetPgPosts.filter((post) => post.author.includes('angelico_de_los_reyes')) + const planetPgOli = planetPgPosts.filter((post) => post.author.includes('oli_rice')) + const planetPgMark = planetPgPosts.filter((post) => post.author.includes('burggraf')) + const planetPgVictor = planetPgPosts.filter((post) => post.author.includes('victor')) + const planetPgPaul = planetPgPosts.filter((post) => post.author.includes('paul_copplestone')) + const planetPgAnt = planetPgPosts.filter((post) => post.author.includes('ant_wilson')) + + const planetPgrssPavel = generateRss(planetPgPavel) + const planetPgrssAlexander = generateRss(planetPgAlexander) + const planetPgrssMichel = generateRss(planetPgMichel) + const planetPgrssSteve = generateRss(planetPgSteve) + const planetPgrssAngelico = generateRss(planetPgAngelico) + const planetPgrssOli = generateRss(planetPgOli) + const planetPgrssMark = generateRss(planetPgMark) + const planetPgrssVictor = generateRss(planetPgVictor) + const planetPgrssPaul = generateRss(planetPgPaul) + const planetPgrssAnt = generateRss(planetPgAnt) // create a rss feed in public directory // rss feed is added via component in render return fs.writeFileSync('./public/rss.xml', rss) - // create separate feed for just posts promoted in PlanetPG - fs.writeFileSync('./public/planetpg-rss.xml', planetPgrss) + // create separate feed for posts to promote in PlanetPG for each author + fs.writeFileSync('./public/planetpg-pavel-rss.xml', planetPgrssPavel) + fs.writeFileSync('./public/planetpg-alexander-rss.xml', planetPgrssAlexander) + fs.writeFileSync('./public/planetpg-michel-rss.xml', planetPgrssMichel) + fs.writeFileSync('./public/planetpg-steve-rss.xml', planetPgrssSteve) + fs.writeFileSync('./public/planetpg-angelico-rss.xml', planetPgrssAngelico) + fs.writeFileSync('./public/planetpg-oli-rss.xml', planetPgrssOli) + fs.writeFileSync('./public/planetpg-mark-rss.xml', planetPgrssMark) + fs.writeFileSync('./public/planetpg-victor-rss.xml', planetPgrssVictor) + fs.writeFileSync('./public/planetpg-paul-rss.xml', planetPgrssPaul) + fs.writeFileSync('./public/planetpg-ant-rss.xml', planetPgrssAnt) return { props: { diff --git a/apps/www/public/planetpg-rss.xml b/apps/www/public/planetpg-rss.xml deleted file mode 100644 index 9a980d87cea..00000000000 --- a/apps/www/public/planetpg-rss.xml +++ /dev/null @@ -1,159 +0,0 @@ - - - - Blog - Supabase - https://supabase.com - Latest news from Supabase - en - Thu, 15 Dec 2022 03:03:30 +0000 - - - https://supabase.com/blog/vault-now-in-beta - Supabase Vault is now in Beta - https://supabase.com/blog/vault-now-in-beta - A Postgres extension to store encrypted secrets and encrypt data. - Thu, 15 Dec 2022 03:03:30 +0000 - - - https://supabase.com/blog/postgrest-11-prerelease - PostgREST 11 pre-release - https://supabase.com/blog/postgrest-11-prerelease - Describes new features of PostgREST 11 pre-release - Thu, 15 Dec 2022 03:03:30 +0000 - - - https://supabase.com/blog/postgres-point-in-time-recovery - Point in Time Recovery is now available for Pro projects - https://supabase.com/blog/postgres-point-in-time-recovery - We're making PITR available for more projects, with a new Dashboard UI that makes it simple to use. - Thu, 15 Dec 2022 03:03:30 +0000 - - - https://supabase.com/blog/pg-graphql-v1 - pg_graphql v1.0 - https://supabase.com/blog/pg-graphql-v1 - Announcing the v1.0 release of pg_graphql - Thu, 15 Dec 2022 03:03:30 +0000 - - - https://supabase.com/blog/new-in-postgres-15 - What's new in Postgres 15? - https://supabase.com/blog/new-in-postgres-15 - Describes the release of Postgres 15, new features and reasons to use it - Thu, 15 Dec 2022 03:03:30 +0000 - - - https://supabase.com/blog/transparent-column-encryption-with-postgres - Transparent Column Encryption with Postgres - https://supabase.com/blog/transparent-column-encryption-with-postgres - Using pgsodium's Transparent Column Encryption to encrypt data and provide your users with row-level encryption. - Wed, 30 Nov 2022 03:03:30 +0000 - - - https://supabase.com/blog/sql-or-nosql-both-with-postgresql - SQL or NoSQL? Why not use both (with PostgreSQL)? - https://supabase.com/blog/sql-or-nosql-both-with-postgresql - How to turn Postgres into an easy-to-use NoSQL database that retains all the power of SQL - Wed, 23 Nov 2022 03:03:30 +0000 - - - https://supabase.com/blog/postgresql-commitfest - What is PostgreSQL commitfest and how to contribute - https://supabase.com/blog/postgresql-commitfest - A time-tested method for contributing to the core Postgres code - Wed, 26 Oct 2022 02:02:30 +0000 - - - https://supabase.com/blog/postgres-full-text-search-vs-the-rest - Postgres Full Text Search vs the rest - https://supabase.com/blog/postgres-full-text-search-vs-the-rest - Comparing one of the most popular Postgres features against alternatives - Thu, 13 Oct 2022 02:02:30 +0000 - - - https://supabase.com/blog/postgres-wasm - Postgres WASM by Snaplet and Supabase - https://supabase.com/blog/postgres-wasm - We're open sourcing postgres-wasm, a PostgresQL server that runs inside a browser, with our friends at Snaplet. - Sun, 02 Oct 2022 02:02:30 +0000 - - - https://supabase.com/blog/choosing-a-postgres-primary-key - Choosing a Postgres Primary Key - https://supabase.com/blog/choosing-a-postgres-primary-key - Turns out the question of which identifier to use as a Primary Key is complicated -- we're going to dive into some of the complexity and inherent trade-offs, and figure things out - Wed, 07 Sep 2022 02:02:30 +0000 - - - https://supabase.com/blog/seen-by-in-postgresql - Implementing "seen by" functionality with Postgres - https://supabase.com/blog/seen-by-in-postgresql - Different approaches for tracking visitor counts with PostgreSQL. - Sun, 17 Jul 2022 02:02:30 +0000 - - - https://supabase.com/blog/partial-postgresql-data-dumps-with-rls - Partial data dumps using Postgres Row Level Security - https://supabase.com/blog/partial-postgresql-data-dumps-with-rls - Using RLS to create seed files for local PostgreSQL testing. - Mon, 27 Jun 2022 02:02:30 +0000 - - - https://supabase.com/blog/audit - Postgres Auditing in 150 lines of SQL - https://supabase.com/blog/audit - PostgreSQL has a robust set of features which we can leverage to create a generic auditing solution in 150 lines of SQL. - Mon, 07 Mar 2022 03:03:30 +0000 - - - https://supabase.com/blog/roles-postgres-hooks - Protecting reserved roles with PostgreSQL Hooks - https://supabase.com/blog/roles-postgres-hooks - Using Postgres Hooks to protect functionality in your Postgres database. - Thu, 01 Jul 2021 02:02:30 +0000 - - - https://supabase.com/blog/postgres-as-a-cron-server - Postgres as a CRON Server - https://supabase.com/blog/postgres-as-a-cron-server - Running repetitive tasks with your Postgres database. - Fri, 05 Mar 2021 03:03:30 +0000 - - - https://supabase.com/blog/cracking-postgres-interview - Cracking PostgreSQL Interview Questions - https://supabase.com/blog/cracking-postgres-interview - Understand the top PostgreSQL Interview Questions - Sat, 27 Feb 2021 03:03:30 +0000 - - - https://supabase.com/blog/postgresql-views - Postgres Views - https://supabase.com/blog/postgresql-views - Creating and using a view in PostgreSQL. - Wed, 18 Nov 2020 03:03:30 +0000 - - - https://supabase.com/blog/continuous-postgresql-backup-walg - Continuous PostgreSQL Backups using WAL-G - https://supabase.com/blog/continuous-postgresql-backup-walg - Have you ever wanted to restore your database's state to a particular moment in time? This post explains how, using WAL-G. - Sun, 02 Aug 2020 02:02:30 +0000 - - - https://supabase.com/blog/postgresql-templates - What are PostgreSQL Templates? - https://supabase.com/blog/postgresql-templates - What are PostgreSQL templates and what are they used for? - Thu, 09 Jul 2020 02:02:30 +0000 - - - https://supabase.com/blog/postgresql-physical-logical-backups - Physical vs Logical Backups in PostgreSQL - https://supabase.com/blog/postgresql-physical-logical-backups - What are physical and logical backups in Postgres? - Tue, 07 Jul 2020 02:02:30 +0000 - - - - From 90a568ffebf0c2797ed1ff80035af69ddc32b66b Mon Sep 17 00:00:00 2001 From: Pavel Borisov <63344111+pashkinelfe@users.noreply.github.com> Date: Tue, 10 Jan 2023 13:12:00 +0400 Subject: [PATCH 2/6] Update apps/www/pages/blog.tsx line formatting Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- apps/www/pages/blog.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/www/pages/blog.tsx b/apps/www/pages/blog.tsx index 5b81312706b..470a94ee476 100644 --- a/apps/www/pages/blog.tsx +++ b/apps/www/pages/blog.tsx @@ -26,7 +26,9 @@ export async function getStaticProps() { const planetPgAlexander = planetPgPosts.filter((post) => post.author.includes('alexander')) const planetPgMichel = planetPgPosts.filter((post) => post.author.includes('michel')) const planetPgSteve = planetPgPosts.filter((post) => post.author.includes('steve_chavez')) - const planetPgAngelico = planetPgPosts.filter((post) => post.author.includes('angelico_de_los_reyes')) + const planetPgAngelico = planetPgPosts.filter((post) => + post.author.includes('angelico_de_los_reyes') + ) const planetPgOli = planetPgPosts.filter((post) => post.author.includes('oli_rice')) const planetPgMark = planetPgPosts.filter((post) => post.author.includes('burggraf')) const planetPgVictor = planetPgPosts.filter((post) => post.author.includes('victor')) From 77cc9ec5fc54fd5c4d0457e65c65dd081582c463 Mon Sep 17 00:00:00 2001 From: Terry Sutton Date: Tue, 10 Jan 2023 09:17:14 -0330 Subject: [PATCH 3/6] Fix ts and no-posts-found errors --- apps/www/pages/blog.tsx | 59 +++++++------------ .../planetpg-angelico_de_los_reyes-rss.xml | 40 +++++++++++++ apps/www/public/planetpg-ant_wilson-rss.xml | 19 ++++++ apps/www/public/planetpg-burggraf-rss.xml | 26 ++++++++ apps/www/public/planetpg-michel-rss.xml | 26 ++++++++ apps/www/public/planetpg-oli_rice-rss.xml | 26 ++++++++ .../public/planetpg-paul_copplestone-rss.xml | 33 +++++++++++ apps/www/public/planetpg-steve_chavez-rss.xml | 26 ++++++++ apps/www/public/planetpg-victor-rss.xml | 33 +++++++++++ 9 files changed, 251 insertions(+), 37 deletions(-) create mode 100644 apps/www/public/planetpg-angelico_de_los_reyes-rss.xml create mode 100644 apps/www/public/planetpg-ant_wilson-rss.xml create mode 100644 apps/www/public/planetpg-burggraf-rss.xml create mode 100644 apps/www/public/planetpg-michel-rss.xml create mode 100644 apps/www/public/planetpg-oli_rice-rss.xml create mode 100644 apps/www/public/planetpg-paul_copplestone-rss.xml create mode 100644 apps/www/public/planetpg-steve_chavez-rss.xml create mode 100644 apps/www/public/planetpg-victor-rss.xml diff --git a/apps/www/pages/blog.tsx b/apps/www/pages/blog.tsx index 470a94ee476..91382f96787 100644 --- a/apps/www/pages/blog.tsx +++ b/apps/www/pages/blog.tsx @@ -19,48 +19,33 @@ export async function getStaticProps() { const allPostsData = getSortedPosts('_blog', undefined, undefined, '** BLOG PAGE **') const categories = getAllCategories('_blog') const rss = generateRss(allPostsData) - // @ts-ignore - const planetPgPosts = allPostsData.filter((post) => post.tags.includes('planetpg')) - - const planetPgPavel = planetPgPosts.filter((post) => post.author.includes('pavel')) - const planetPgAlexander = planetPgPosts.filter((post) => post.author.includes('alexander')) - const planetPgMichel = planetPgPosts.filter((post) => post.author.includes('michel')) - const planetPgSteve = planetPgPosts.filter((post) => post.author.includes('steve_chavez')) - const planetPgAngelico = planetPgPosts.filter((post) => - post.author.includes('angelico_de_los_reyes') - ) - const planetPgOli = planetPgPosts.filter((post) => post.author.includes('oli_rice')) - const planetPgMark = planetPgPosts.filter((post) => post.author.includes('burggraf')) - const planetPgVictor = planetPgPosts.filter((post) => post.author.includes('victor')) - const planetPgPaul = planetPgPosts.filter((post) => post.author.includes('paul_copplestone')) - const planetPgAnt = planetPgPosts.filter((post) => post.author.includes('ant_wilson')) - - const planetPgrssPavel = generateRss(planetPgPavel) - const planetPgrssAlexander = generateRss(planetPgAlexander) - const planetPgrssMichel = generateRss(planetPgMichel) - const planetPgrssSteve = generateRss(planetPgSteve) - const planetPgrssAngelico = generateRss(planetPgAngelico) - const planetPgrssOli = generateRss(planetPgOli) - const planetPgrssMark = generateRss(planetPgMark) - const planetPgrssVictor = generateRss(planetPgVictor) - const planetPgrssPaul = generateRss(planetPgPaul) - const planetPgrssAnt = generateRss(planetPgAnt) // create a rss feed in public directory // rss feed is added via component in render return fs.writeFileSync('./public/rss.xml', rss) - // create separate feed for posts to promote in PlanetPG for each author - fs.writeFileSync('./public/planetpg-pavel-rss.xml', planetPgrssPavel) - fs.writeFileSync('./public/planetpg-alexander-rss.xml', planetPgrssAlexander) - fs.writeFileSync('./public/planetpg-michel-rss.xml', planetPgrssMichel) - fs.writeFileSync('./public/planetpg-steve-rss.xml', planetPgrssSteve) - fs.writeFileSync('./public/planetpg-angelico-rss.xml', planetPgrssAngelico) - fs.writeFileSync('./public/planetpg-oli-rss.xml', planetPgrssOli) - fs.writeFileSync('./public/planetpg-mark-rss.xml', planetPgrssMark) - fs.writeFileSync('./public/planetpg-victor-rss.xml', planetPgrssVictor) - fs.writeFileSync('./public/planetpg-paul-rss.xml', planetPgrssPaul) - fs.writeFileSync('./public/planetpg-ant-rss.xml', planetPgrssAnt) + // generate a series of rss feeds for each author (for PlanetPG) + const planetPgPosts = allPostsData.filter((post: any) => post.tags.includes('planetpg')) + + const authors = [ + 'alexander', + 'michel', + 'steve_chavez', + 'angelico_de_los_reyes', + 'oli_rice', + 'burggraf', + 'victor', + 'paul_copplestone', + 'ant_wilson', + ] + + authors.forEach((author) => { + const authorPosts = planetPgPosts.filter((post: any) => post.author.includes(author)) + if (authorPosts.length > 0) { + const authorRss = generateRss(authorPosts) + fs.writeFileSync(`./public/planetpg-${author}-rss.xml`, authorRss) + } + }) return { props: { diff --git a/apps/www/public/planetpg-angelico_de_los_reyes-rss.xml b/apps/www/public/planetpg-angelico_de_los_reyes-rss.xml new file mode 100644 index 00000000000..280497b278e --- /dev/null +++ b/apps/www/public/planetpg-angelico_de_los_reyes-rss.xml @@ -0,0 +1,40 @@ + + + + Blog - Supabase + https://supabase.com + Latest news from Supabase + en + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/postgres-point-in-time-recovery + Point in Time Recovery is now available for Pro projects + https://supabase.com/blog/postgres-point-in-time-recovery + We're making PITR available for more projects, with a new Dashboard UI that makes it simple to use. + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/continuous-postgresql-backup-walg + Continuous PostgreSQL Backups using WAL-G + https://supabase.com/blog/continuous-postgresql-backup-walg + Have you ever wanted to restore your database's state to a particular moment in time? This post explains how, using WAL-G. + Sun, 02 Aug 2020 02:02:30 +0000 + + + https://supabase.com/blog/postgresql-templates + What are PostgreSQL Templates? + https://supabase.com/blog/postgresql-templates + What are PostgreSQL templates and what are they used for? + Thu, 09 Jul 2020 02:02:30 +0000 + + + https://supabase.com/blog/postgresql-physical-logical-backups + Physical vs Logical Backups in PostgreSQL + https://supabase.com/blog/postgresql-physical-logical-backups + What are physical and logical backups in Postgres? + Tue, 07 Jul 2020 02:02:30 +0000 + + + + diff --git a/apps/www/public/planetpg-ant_wilson-rss.xml b/apps/www/public/planetpg-ant_wilson-rss.xml new file mode 100644 index 00000000000..b0afb8913f2 --- /dev/null +++ b/apps/www/public/planetpg-ant_wilson-rss.xml @@ -0,0 +1,19 @@ + + + + Blog - Supabase + https://supabase.com + Latest news from Supabase + en + Sat, 27 Feb 2021 03:03:30 +0000 + + + https://supabase.com/blog/cracking-postgres-interview + Cracking PostgreSQL Interview Questions + https://supabase.com/blog/cracking-postgres-interview + Understand the top PostgreSQL Interview Questions + Sat, 27 Feb 2021 03:03:30 +0000 + + + + diff --git a/apps/www/public/planetpg-burggraf-rss.xml b/apps/www/public/planetpg-burggraf-rss.xml new file mode 100644 index 00000000000..3f3db745b40 --- /dev/null +++ b/apps/www/public/planetpg-burggraf-rss.xml @@ -0,0 +1,26 @@ + + + + Blog - Supabase + https://supabase.com + Latest news from Supabase + en + Wed, 23 Nov 2022 03:03:30 +0000 + + + https://supabase.com/blog/sql-or-nosql-both-with-postgresql + SQL or NoSQL? Why not use both (with PostgreSQL)? + https://supabase.com/blog/sql-or-nosql-both-with-postgresql + How to turn Postgres into an easy-to-use NoSQL database that retains all the power of SQL + Wed, 23 Nov 2022 03:03:30 +0000 + + + https://supabase.com/blog/postgres-wasm + Postgres WASM by Snaplet and Supabase + https://supabase.com/blog/postgres-wasm + We're open sourcing postgres-wasm, a PostgresQL server that runs inside a browser, with our friends at Snaplet. + Sun, 02 Oct 2022 02:02:30 +0000 + + + + diff --git a/apps/www/public/planetpg-michel-rss.xml b/apps/www/public/planetpg-michel-rss.xml new file mode 100644 index 00000000000..8df9cc5a91c --- /dev/null +++ b/apps/www/public/planetpg-michel-rss.xml @@ -0,0 +1,26 @@ + + + + Blog - Supabase + https://supabase.com + Latest news from Supabase + en + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/vault-now-in-beta + Supabase Vault is now in Beta + https://supabase.com/blog/vault-now-in-beta + A Postgres extension to store encrypted secrets and encrypt data. + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/transparent-column-encryption-with-postgres + Transparent Column Encryption with Postgres + https://supabase.com/blog/transparent-column-encryption-with-postgres + Using pgsodium's Transparent Column Encryption to encrypt data and provide your users with row-level encryption. + Wed, 30 Nov 2022 03:03:30 +0000 + + + + diff --git a/apps/www/public/planetpg-oli_rice-rss.xml b/apps/www/public/planetpg-oli_rice-rss.xml new file mode 100644 index 00000000000..da3f0ad119b --- /dev/null +++ b/apps/www/public/planetpg-oli_rice-rss.xml @@ -0,0 +1,26 @@ + + + + Blog - Supabase + https://supabase.com + Latest news from Supabase + en + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/pg-graphql-v1 + pg_graphql v1.0 + https://supabase.com/blog/pg-graphql-v1 + Announcing the v1.0 release of pg_graphql + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/audit + Postgres Auditing in 150 lines of SQL + https://supabase.com/blog/audit + PostgreSQL has a robust set of features which we can leverage to create a generic auditing solution in 150 lines of SQL. + Mon, 07 Mar 2022 03:03:30 +0000 + + + + diff --git a/apps/www/public/planetpg-paul_copplestone-rss.xml b/apps/www/public/planetpg-paul_copplestone-rss.xml new file mode 100644 index 00000000000..784975b7a6f --- /dev/null +++ b/apps/www/public/planetpg-paul_copplestone-rss.xml @@ -0,0 +1,33 @@ + + + + Blog - Supabase + https://supabase.com + Latest news from Supabase + en + Mon, 27 Jun 2022 02:02:30 +0000 + + + https://supabase.com/blog/partial-postgresql-data-dumps-with-rls + Partial data dumps using Postgres Row Level Security + https://supabase.com/blog/partial-postgresql-data-dumps-with-rls + Using RLS to create seed files for local PostgreSQL testing. + Mon, 27 Jun 2022 02:02:30 +0000 + + + https://supabase.com/blog/postgres-as-a-cron-server + Postgres as a CRON Server + https://supabase.com/blog/postgres-as-a-cron-server + Running repetitive tasks with your Postgres database. + Fri, 05 Mar 2021 03:03:30 +0000 + + + https://supabase.com/blog/postgresql-views + Postgres Views + https://supabase.com/blog/postgresql-views + Creating and using a view in PostgreSQL. + Wed, 18 Nov 2020 03:03:30 +0000 + + + + diff --git a/apps/www/public/planetpg-steve_chavez-rss.xml b/apps/www/public/planetpg-steve_chavez-rss.xml new file mode 100644 index 00000000000..0b47a94b124 --- /dev/null +++ b/apps/www/public/planetpg-steve_chavez-rss.xml @@ -0,0 +1,26 @@ + + + + Blog - Supabase + https://supabase.com + Latest news from Supabase + en + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/postgrest-11-prerelease + PostgREST 11 pre-release + https://supabase.com/blog/postgrest-11-prerelease + Describes new features of PostgREST 11 pre-release + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/roles-postgres-hooks + Protecting reserved roles with PostgreSQL Hooks + https://supabase.com/blog/roles-postgres-hooks + Using Postgres Hooks to protect functionality in your Postgres database. + Thu, 01 Jul 2021 02:02:30 +0000 + + + + diff --git a/apps/www/public/planetpg-victor-rss.xml b/apps/www/public/planetpg-victor-rss.xml new file mode 100644 index 00000000000..f3fbdfd181f --- /dev/null +++ b/apps/www/public/planetpg-victor-rss.xml @@ -0,0 +1,33 @@ + + + + Blog - Supabase + https://supabase.com + Latest news from Supabase + en + Thu, 13 Oct 2022 02:02:30 +0000 + + + https://supabase.com/blog/postgres-full-text-search-vs-the-rest + Postgres Full Text Search vs the rest + https://supabase.com/blog/postgres-full-text-search-vs-the-rest + Comparing one of the most popular Postgres features against alternatives + Thu, 13 Oct 2022 02:02:30 +0000 + + + https://supabase.com/blog/choosing-a-postgres-primary-key + Choosing a Postgres Primary Key + https://supabase.com/blog/choosing-a-postgres-primary-key + Turns out the question of which identifier to use as a Primary Key is complicated -- we're going to dive into some of the complexity and inherent trade-offs, and figure things out + Wed, 07 Sep 2022 02:02:30 +0000 + + + https://supabase.com/blog/seen-by-in-postgresql + Implementing "seen by" functionality with Postgres + https://supabase.com/blog/seen-by-in-postgresql + Different approaches for tracking visitor counts with PostgreSQL. + Sun, 17 Jul 2022 02:02:30 +0000 + + + + From ea441c7e7cc051813a633361f595966bd6c71920 Mon Sep 17 00:00:00 2001 From: Terry Sutton Date: Tue, 10 Jan 2023 09:47:31 -0330 Subject: [PATCH 4/6] Add pavel back --- apps/www/pages/blog.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/apps/www/pages/blog.tsx b/apps/www/pages/blog.tsx index 91382f96787..8e2a55c3c44 100644 --- a/apps/www/pages/blog.tsx +++ b/apps/www/pages/blog.tsx @@ -30,6 +30,7 @@ export async function getStaticProps() { const authors = [ 'alexander', 'michel', + 'pavel', 'steve_chavez', 'angelico_de_los_reyes', 'oli_rice', From 0d5156c7ed6a170a855b208e6cb89eca2443d1d3 Mon Sep 17 00:00:00 2001 From: Terry Sutton Date: Tue, 10 Jan 2023 09:50:54 -0330 Subject: [PATCH 5/6] Add Pavels rss file --- apps/www/public/planetpg-pavel-rss.xml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 apps/www/public/planetpg-pavel-rss.xml diff --git a/apps/www/public/planetpg-pavel-rss.xml b/apps/www/public/planetpg-pavel-rss.xml new file mode 100644 index 00000000000..22153485707 --- /dev/null +++ b/apps/www/public/planetpg-pavel-rss.xml @@ -0,0 +1,26 @@ + + + + Blog - Supabase + https://supabase.com + Latest news from Supabase + en + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/new-in-postgres-15 + What's new in Postgres 15? + https://supabase.com/blog/new-in-postgres-15 + Describes the release of Postgres 15, new features and reasons to use it + Thu, 15 Dec 2022 03:03:30 +0000 + + + https://supabase.com/blog/postgresql-commitfest + What is PostgreSQL commitfest and how to contribute + https://supabase.com/blog/postgresql-commitfest + A time-tested method for contributing to the core Postgres code + Wed, 26 Oct 2022 02:02:30 +0000 + + + + From d8c02d80f913f9fa862205832b58c3d8f9c3d9fc Mon Sep 17 00:00:00 2001 From: Terry Sutton Date: Tue, 10 Jan 2023 10:54:48 -0330 Subject: [PATCH 6/6] Updates --- apps/www/lib/rss.tsx | 27 +++++++++++++++++-- apps/www/pages/blog.tsx | 19 +++---------- .../planetpg-angelico_de_los_reyes-rss.xml | 8 +++--- apps/www/public/planetpg-ant_wilson-rss.xml | 8 +++--- apps/www/public/planetpg-burggraf-rss.xml | 8 +++--- apps/www/public/planetpg-michel-rss.xml | 8 +++--- apps/www/public/planetpg-oli_rice-rss.xml | 8 +++--- .../public/planetpg-paul_copplestone-rss.xml | 8 +++--- apps/www/public/planetpg-pavel-rss.xml | 8 +++--- apps/www/public/planetpg-steve_chavez-rss.xml | 8 +++--- apps/www/public/planetpg-victor-rss.xml | 8 +++--- 11 files changed, 65 insertions(+), 53 deletions(-) diff --git a/apps/www/lib/rss.tsx b/apps/www/lib/rss.tsx index 36fb38f5825..c0409f8393d 100644 --- a/apps/www/lib/rss.tsx +++ b/apps/www/lib/rss.tsx @@ -1,3 +1,4 @@ +import authors from 'lib/authors.json' const dayjs = require('dayjs') var utc = require('dayjs/plugin/utc') var advancedFormat = require('dayjs/plugin/advancedFormat') @@ -17,8 +18,29 @@ const generateRssItem = (post: any): string => { ` } -export const generateRss = (posts: any[]): string => { - return ` +// we generate a main rss.xml flie as well as individual files for +// authors who publish under the `planetpg` tag +export const generateRss = (posts: any[], authorID?: string): string => { + const authorInfo = authors.find((item) => item.author_id === authorID) + + if (authorID) { + return ` + + + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from ${authorInfo?.author} at Supabase + en + ${dayjs(posts[0].date) + .utc() + .format('ddd, DD MMM YYYY HH:hh:mm ZZ')} + + ${posts.map(generateRssItem).join('')} + + +` + } else { + return ` Blog - Supabase @@ -33,4 +55,5 @@ export const generateRss = (posts: any[]): string => { ` + } } diff --git a/apps/www/pages/blog.tsx b/apps/www/pages/blog.tsx index 8e2a55c3c44..a14bbd8feef 100644 --- a/apps/www/pages/blog.tsx +++ b/apps/www/pages/blog.tsx @@ -26,24 +26,13 @@ export async function getStaticProps() { // generate a series of rss feeds for each author (for PlanetPG) const planetPgPosts = allPostsData.filter((post: any) => post.tags.includes('planetpg')) + const planetPgAuthors = planetPgPosts.map((post: any) => post.author.split(',')) + const uniquePlanetPgAuthors = new Set([].concat(...planetPgAuthors)) - const authors = [ - 'alexander', - 'michel', - 'pavel', - 'steve_chavez', - 'angelico_de_los_reyes', - 'oli_rice', - 'burggraf', - 'victor', - 'paul_copplestone', - 'ant_wilson', - ] - - authors.forEach((author) => { + uniquePlanetPgAuthors.forEach((author) => { const authorPosts = planetPgPosts.filter((post: any) => post.author.includes(author)) if (authorPosts.length > 0) { - const authorRss = generateRss(authorPosts) + const authorRss = generateRss(authorPosts, author) fs.writeFileSync(`./public/planetpg-${author}-rss.xml`, authorRss) } }) diff --git a/apps/www/public/planetpg-angelico_de_los_reyes-rss.xml b/apps/www/public/planetpg-angelico_de_los_reyes-rss.xml index 280497b278e..84fe8fab257 100644 --- a/apps/www/public/planetpg-angelico_de_los_reyes-rss.xml +++ b/apps/www/public/planetpg-angelico_de_los_reyes-rss.xml @@ -1,12 +1,12 @@ - Blog - Supabase - https://supabase.com - Latest news from Supabase + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from Angelico de los Reyes at Supabase en Thu, 15 Dec 2022 03:03:30 +0000 - + https://supabase.com/blog/postgres-point-in-time-recovery Point in Time Recovery is now available for Pro projects diff --git a/apps/www/public/planetpg-ant_wilson-rss.xml b/apps/www/public/planetpg-ant_wilson-rss.xml index b0afb8913f2..07cfe4056b8 100644 --- a/apps/www/public/planetpg-ant_wilson-rss.xml +++ b/apps/www/public/planetpg-ant_wilson-rss.xml @@ -1,12 +1,12 @@ - Blog - Supabase - https://supabase.com - Latest news from Supabase + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from Ant Wilson at Supabase en Sat, 27 Feb 2021 03:03:30 +0000 - + https://supabase.com/blog/cracking-postgres-interview Cracking PostgreSQL Interview Questions diff --git a/apps/www/public/planetpg-burggraf-rss.xml b/apps/www/public/planetpg-burggraf-rss.xml index 3f3db745b40..26233a86f1e 100644 --- a/apps/www/public/planetpg-burggraf-rss.xml +++ b/apps/www/public/planetpg-burggraf-rss.xml @@ -1,12 +1,12 @@ - Blog - Supabase - https://supabase.com - Latest news from Supabase + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from Mark Burggraf at Supabase en Wed, 23 Nov 2022 03:03:30 +0000 - + https://supabase.com/blog/sql-or-nosql-both-with-postgresql SQL or NoSQL? Why not use both (with PostgreSQL)? diff --git a/apps/www/public/planetpg-michel-rss.xml b/apps/www/public/planetpg-michel-rss.xml index 8df9cc5a91c..3bcd14a76b8 100644 --- a/apps/www/public/planetpg-michel-rss.xml +++ b/apps/www/public/planetpg-michel-rss.xml @@ -1,12 +1,12 @@ - Blog - Supabase - https://supabase.com - Latest news from Supabase + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from Michel Pelletier at Supabase en Thu, 15 Dec 2022 03:03:30 +0000 - + https://supabase.com/blog/vault-now-in-beta Supabase Vault is now in Beta diff --git a/apps/www/public/planetpg-oli_rice-rss.xml b/apps/www/public/planetpg-oli_rice-rss.xml index da3f0ad119b..77f01e50bdf 100644 --- a/apps/www/public/planetpg-oli_rice-rss.xml +++ b/apps/www/public/planetpg-oli_rice-rss.xml @@ -1,12 +1,12 @@ - Blog - Supabase - https://supabase.com - Latest news from Supabase + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from Oliver Rice at Supabase en Thu, 15 Dec 2022 03:03:30 +0000 - + https://supabase.com/blog/pg-graphql-v1 pg_graphql v1.0 diff --git a/apps/www/public/planetpg-paul_copplestone-rss.xml b/apps/www/public/planetpg-paul_copplestone-rss.xml index 784975b7a6f..bc3d31ea3d3 100644 --- a/apps/www/public/planetpg-paul_copplestone-rss.xml +++ b/apps/www/public/planetpg-paul_copplestone-rss.xml @@ -1,12 +1,12 @@ - Blog - Supabase - https://supabase.com - Latest news from Supabase + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from Paul Copplestone at Supabase en Mon, 27 Jun 2022 02:02:30 +0000 - + https://supabase.com/blog/partial-postgresql-data-dumps-with-rls Partial data dumps using Postgres Row Level Security diff --git a/apps/www/public/planetpg-pavel-rss.xml b/apps/www/public/planetpg-pavel-rss.xml index 22153485707..e6dbbb4c1fe 100644 --- a/apps/www/public/planetpg-pavel-rss.xml +++ b/apps/www/public/planetpg-pavel-rss.xml @@ -1,12 +1,12 @@ - Blog - Supabase - https://supabase.com - Latest news from Supabase + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from Pavel Borisov at Supabase en Thu, 15 Dec 2022 03:03:30 +0000 - + https://supabase.com/blog/new-in-postgres-15 What's new in Postgres 15? diff --git a/apps/www/public/planetpg-steve_chavez-rss.xml b/apps/www/public/planetpg-steve_chavez-rss.xml index 0b47a94b124..575cafb6b06 100644 --- a/apps/www/public/planetpg-steve_chavez-rss.xml +++ b/apps/www/public/planetpg-steve_chavez-rss.xml @@ -1,12 +1,12 @@ - Blog - Supabase - https://supabase.com - Latest news from Supabase + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from Steve Chavez at Supabase en Thu, 15 Dec 2022 03:03:30 +0000 - + https://supabase.com/blog/postgrest-11-prerelease PostgREST 11 pre-release diff --git a/apps/www/public/planetpg-victor-rss.xml b/apps/www/public/planetpg-victor-rss.xml index f3fbdfd181f..e742fb6eec8 100644 --- a/apps/www/public/planetpg-victor-rss.xml +++ b/apps/www/public/planetpg-victor-rss.xml @@ -1,12 +1,12 @@ - Blog - Supabase - https://supabase.com - Latest news from Supabase + 'Postgres | Supabase Blog + https://supabase.com/blog + Latest Postgres news from Victor at Supabase en Thu, 13 Oct 2022 02:02:30 +0000 - + https://supabase.com/blog/postgres-full-text-search-vs-the-rest Postgres Full Text Search vs the rest