From 75e5102ffd532a50604f6a95864fa6a13c32c235 Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Sat, 5 Mar 2022 01:29:05 +0330 Subject: rss, WIP --- views/index.ejs | 4 ++++ views/rss_feed.pug | 21 +++++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 views/rss_feed.pug (limited to 'views') diff --git a/views/index.ejs b/views/index.ejs index 4679e4a..529a5ed 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -5,6 +5,8 @@ Blog + + @@ -15,6 +17,8 @@
Archive About +     + RSS diff --git a/views/rss_feed.pug b/views/rss_feed.pug new file mode 100644 index 0000000..9bdd9bd --- /dev/null +++ b/views/rss_feed.pug @@ -0,0 +1,21 @@ +doctype xml +rss(version='2.0', xmlns:atom='http://www.w3.org/2005/Atom') + channel + title DevSmash + link http://devsmash.com + atom:link(href='http://devsmash.com/feed/rss', rel='self', type='application/rss+xml') + description Developers talking about stuff that developers like to talk about. + language en-US + if posts.length + lastBuildDate= new Date(posts[0].publishedAt).toUTCString() + each post in posts + item + title= post.title + link http://devsmash.com/blog/#{post.slug} + description + | http://devsmash.com/blog/#{post.slug}')!= 'Read more »' + | ]]> + pubDate= new Date(post.publishedAt).toUTCString() + guid(isPermaLink='false') Date: Fri, 25 Mar 2022 19:06:57 +0430 Subject: wip --- views/index.ejs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'views') diff --git a/views/index.ejs b/views/index.ejs index 529a5ed..6cc3a45 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -9,7 +9,7 @@ - +
<%- data.blogHttp %>
-- cgit v1.2.3 From 4eaa437c0a285c617e30a533d1ef369eaa8644a6 Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Tue, 5 Jul 2022 20:19:16 +0430 Subject: WIP, adding rss to the blog --- views/index.ejs | 8 +++++++- views/rss_feed.pug | 18 +++++++++--------- 2 files changed, 16 insertions(+), 10 deletions(-) (limited to 'views') diff --git a/views/index.ejs b/views/index.ejs index 6cc3a45..0e47f53 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -6,7 +6,7 @@ Blog - + @@ -15,6 +15,12 @@


+
Keywords: + <%- data.Keywords %> +
+
+
+
Archive About     diff --git a/views/rss_feed.pug b/views/rss_feed.pug index 9bdd9bd..0ae2b74 100644 --- a/views/rss_feed.pug +++ b/views/rss_feed.pug @@ -1,21 +1,21 @@ doctype xml rss(version='2.0', xmlns:atom='http://www.w3.org/2005/Atom') channel - title DevSmash - link http://devsmash.com - atom:link(href='http://devsmash.com/feed/rss', rel='self', type='application/rss+xml') - description Developers talking about stuff that developers like to talk about. + title deviblog + link https://blog.terminaldweller.com + atom:link(href='https://blog.terminaldweller.com/feed/rss', rel='self', type='application/rss+xml') + description I talk about software here. language en-US if posts.length - lastBuildDate= new Date(posts[0].publishedAt).toUTCString() + lastBuildDate= new Date(posts[0].lastUpdatedAt).toUTCString() each post in posts item title= post.title - link http://devsmash.com/blog/#{post.slug} + link https://terminaldweller.com/blog/#{post.slug} description | http://devsmash.com/blog/#{post.slug}')!= 'Read more »' + p: a(href='https://blog.terminaldweller.com/blog/#{post.slug}') 'Read more »' | ]]> - pubDate= new Date(post.publishedAt).toUTCString() - guid(isPermaLink='false') Date: Wed, 6 Jul 2022 14:31:50 +0430 Subject: now the blog uses the db for everything. now need to decide on how to populate the DB and prevent duplication --- views/archive.ejs | 4 ++-- views/index.ejs | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'views') diff --git a/views/archive.ejs b/views/archive.ejs index 36191de..72b963d 100644 --- a/views/archive.ejs +++ b/views/archive.ejs @@ -9,9 +9,9 @@
- <% data.mds.forEach(function(md) { %> + <% data.blogPosts.forEach(function(blogPost) { %> <% }) %>
diff --git a/views/index.ejs b/views/index.ejs index 0e47f53..fdd49cc 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -16,7 +16,8 @@

Keywords: - <%- data.Keywords %> + <%- data.keywords %> + <%- data.lastUpdated %>


-- cgit v1.2.3 From fc713bcbb320ff692cac6332f5aa587dc817305c Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Wed, 6 Jul 2022 15:54:39 +0430 Subject: WIP, we now have to fix the pug template which is not working --- views/rss_feed.pug | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'views') diff --git a/views/rss_feed.pug b/views/rss_feed.pug index 0ae2b74..e75225d 100644 --- a/views/rss_feed.pug +++ b/views/rss_feed.pug @@ -18,4 +18,4 @@ rss(version='2.0', xmlns:atom='https://blog.terminaldweller.com/blog/#{post.slug}') 'Read more »' | ]]> pubDate= new Date(post.lastUpdatedAt).toUTCString() - guid(isPermaLink='false') https://blog.terminaldweller.com/blog/#{post.slug} -- cgit v1.2.3 From c9f5b12ab281c8889364bfb2455dc97fdb92e9f9 Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Wed, 6 Jul 2022 16:23:42 +0430 Subject: a newer simpler template for the rss feed --- views/rss_feed_v2.pug | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 views/rss_feed_v2.pug (limited to 'views') diff --git a/views/rss_feed_v2.pug b/views/rss_feed_v2.pug new file mode 100644 index 0000000..92c9a87 --- /dev/null +++ b/views/rss_feed_v2.pug @@ -0,0 +1,21 @@ +doctype xml +rss(version='2.0') + channel + title deviblog + link https://blog.terminaldweller.com + description I talk about software here. + managingEditro devi@terminaldweller.com + webMaster devi@terminaldweller.com + language en-US + if posts.length + lastBuildDate= new Date(posts[0].lastUpdatedAt).toUTCString() + each post in posts + item + title= post.title + link https://blog.terminaldweller.com/posts/#{post.slug} + description + | + pubDate= new Date(post.lastUpdatedAt).toUTCString() + guid(isPermaLink='false') https://blog.terminaldweller.com/blog/#{post.slug} -- cgit v1.2.3 From 4302411fb080456ba5047a2b98700ae52a0fad29 Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Wed, 6 Jul 2022 16:58:04 +0430 Subject: fixed rss validator errors except atom error --- views/rss_feed_v2.pug | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'views') diff --git a/views/rss_feed_v2.pug b/views/rss_feed_v2.pug index 92c9a87..b680cb9 100644 --- a/views/rss_feed_v2.pug +++ b/views/rss_feed_v2.pug @@ -4,7 +4,7 @@ rss(version='2.0') title deviblog link https://blog.terminaldweller.com description I talk about software here. - managingEditro devi@terminaldweller.com + managingEditor devi@terminaldweller.com webMaster devi@terminaldweller.com language en-US if posts.length -- cgit v1.2.3 From 2c437f4ca76e107ce3eb3c93ae2fc183caf6caab Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Wed, 6 Jul 2022 17:05:17 +0430 Subject: more fixes for the rss feed --- views/rss_feed_v2.pug | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'views') diff --git a/views/rss_feed_v2.pug b/views/rss_feed_v2.pug index b680cb9..261f054 100644 --- a/views/rss_feed_v2.pug +++ b/views/rss_feed_v2.pug @@ -1,11 +1,12 @@ doctype xml -rss(version='2.0') +rss(version='2.0', xmlns:atom='http://www.w3.org/2005/Atom') channel title deviblog - link https://blog.terminaldweller.com + link https://blog.terminaldweller.com + atom:link(href='https://blog.terminaldweller.com/feed/rss', rel='self', type='application/rss+xml') description I talk about software here. - managingEditor devi@terminaldweller.com - webMaster devi@terminaldweller.com + managingEditor devi@terminaldweller.com (Farzad Sadeghi) + webMaster devi@terminaldweller.com (Farzad Sadeghi) language en-US if posts.length lastBuildDate= new Date(posts[0].lastUpdatedAt).toUTCString() -- cgit v1.2.3 From 07234ee01b79e5123a4718679da1467d1dc669ea Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Wed, 6 Jul 2022 17:10:17 +0430 Subject: fixes for atom --- views/rss_feed_v2.pug | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'views') diff --git a/views/rss_feed_v2.pug b/views/rss_feed_v2.pug index 261f054..76a928d 100644 --- a/views/rss_feed_v2.pug +++ b/views/rss_feed_v2.pug @@ -1,5 +1,5 @@ doctype xml -rss(version='2.0', xmlns:atom='http://www.w3.org/2005/Atom') +rss(version='2.0', xmlns:atom="http://www.w3.org/2005/Atom") channel title deviblog link https://blog.terminaldweller.com -- cgit v1.2.3 From b50e31f75ff62da85539dba72998853a34b9d6ae Mon Sep 17 00:00:00 2001 From: terminaldweller Date: Wed, 6 Jul 2022 17:44:19 +0430 Subject: fix for atom --- views/rss_feed_v2.pug | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'views') diff --git a/views/rss_feed_v2.pug b/views/rss_feed_v2.pug index 76a928d..d04297d 100644 --- a/views/rss_feed_v2.pug +++ b/views/rss_feed_v2.pug @@ -1,9 +1,9 @@ doctype xml -rss(version='2.0', xmlns:atom="http://www.w3.org/2005/Atom") +rss(version='2.0', xmlns:atom='http://www.w3.org/2005/Atom') channel title deviblog - link https://blog.terminaldweller.com - atom:link(href='https://blog.terminaldweller.com/feed/rss', rel='self', type='application/rss+xml') + link https://blog.terminaldweller.com + atom:link(href='https://blog.terminaldweller.com/rss/feed', rel='self', type='application/rss+xml') description I talk about software here. managingEditor devi@terminaldweller.com (Farzad Sadeghi) webMaster devi@terminaldweller.com (Farzad Sadeghi) -- cgit v1.2.3