chore: organization

This commit is contained in:
Cory Dransfeldt 2024-05-17 13:22:24 -07:00
parent 2ce9d35578
commit 532772fc55
No known key found for this signature in database
9 changed files with 26 additions and 25 deletions

View file

@ -9,7 +9,7 @@ import htmlmin from 'html-minifier-terser'
import filters from './config/filters/index.js'
import { minifyJsComponents } from './config/events/index.js'
import { followContent, searchIndex, tagList, tagsSortedByCount, links, tagMap, booksToRead } from './config/collections/index.js'
import { allContent, searchIndex, tagList, tagsSortedByCount, links, tagMap, booksToRead } from './config/collections/index.js'
import { DateTime } from 'luxon'
// load .env
@ -74,7 +74,7 @@ export default async function (eleventyConfig) {
})
// collections
eleventyConfig.addCollection('followContent', followContent)
eleventyConfig.addCollection('allContent', allContent)
eleventyConfig.addCollection('searchIndex', searchIndex)
eleventyConfig.addCollection('tagList', tagList)
eleventyConfig.addCollection('tagsSortedByCount', tagsSortedByCount)

View file

@ -12,7 +12,7 @@ jobs:
- name: Feed to Mastodon
uses: nhoizey/github-action-feed-to-mastodon@v2
with:
feedUrl: "https://coryd.dev/feeds/follow.json"
feedUrl: "https://coryd.dev/feeds/all.json"
mastodonInstance: "https://social.lol"
mastodonToken: ${{ secrets.MASTODON_TOKEN }}
globalDelayToots: 0

View file

@ -27,7 +27,7 @@ export const searchIndex = (collection) => {
return searchIndex
}
export const followContent = (collection) => {
export const allContent = (collection) => {
const aggregateContent = []
const collectionData = collection.getAll()[0]
const { data } = collectionData

4
package-lock.json generated
View file

@ -1,12 +1,12 @@
{
"name": "coryd.dev",
"version": "15.4.1",
"version": "15.4.2",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "coryd.dev",
"version": "15.4.1",
"version": "15.4.2",
"license": "MIT",
"dependencies": {
"@cdransf/api-text": "^1.2.2",

View file

@ -1,6 +1,6 @@
{
"name": "coryd.dev",
"version": "15.4.1",
"version": "15.4.2",
"description": "The source for my personal site. Built using 11ty.",
"type": "module",
"scripts": {

View file

@ -1,13 +1,13 @@
---
layout: null
eleventyExcludeFromCollections: true
permalink: /feeds/follow.json
permalink: /feeds/all.json
---
{% render "partials/feeds/json.liquid"
permalink:'/feeds/follow.json'
permalink:'/feeds/all.json'
title:'Follow • Cory Dransfeldt'
data:collections.followContent
updated:collections.followContent[0].date
data:collections.allContent
updated:collections.allContent[0].date
site:site
tagMap:collections.tagMap
%}

13
src/feeds/all.liquid Normal file
View file

@ -0,0 +1,13 @@
---
layout: null
eleventyExcludeFromCollections: true
permalink: /feeds/all
---
{% render "partials/feeds/rss.liquid"
permalink:"/feeds/all"
title:"Follow • Cory Dransfeldt"
description:"All of the posts and activity from my site."
data:collections.allContent
updated:collections.allContent[0].date
site:site
%}

View file

@ -1,13 +0,0 @@
---
layout: null
eleventyExcludeFromCollections: true
permalink: /feeds/follow
---
{% render "partials/feeds/rss.liquid"
permalink:"/feeds/follow"
title:"Follow • Cory Dransfeldt"
description:"My activity from around the web (ok, mainly this site)."
data:collections.followContent
updated:collections.followContent[0].date
site:site
%}

View file

@ -13,4 +13,5 @@ These are web feeds, also known as [RSS](https://en.wikipedia.org/wiki/RSS) or [
- Links ([RSS](https://feedpress.me/coryd-links) • [JSON](https://feedpress.me/coryd-links.json)): links I've liked.
- Books ([RSS](https://feedpress.me/coryd-books) • [JSON](https://feedpress.me/coryd-books.json)): books I'm currently reading.
- Movies ([RSS](https://feedpress.me/coryd-movies) • [JSON](https://feedpress.me/coryd-books.json)): movies I've watched recently.
- Artist charts ([RSS](https://feedpress.me/coryd-artist-charts) • [JSON](https://feedpress.me/coryd-artist-charts.json)): charts of the artists I've listened to each week.
- Artist charts ([RSS](https://feedpress.me/coryd-artist-charts) • [JSON](https://feedpress.me/coryd-artist-charts.json)): charts of the artists I've listened to each week.
- All ([RSS](https://feedpress.me/coryd-all) • [JSON](https://feedpress.me/coryd-all.json)): all of the posts and activity from my site.