now-updater/config.js

60 lines
1.4 KiB
JavaScript

import {
getJsonFeedItemContent,
getJsonFeedItemTitle,
getLetterboxdActivity,
getMalojaScrobble,
getMastodonPost,
getReadingBooklogr,
getRSSItemTitle,
getTraktEpisode,
getTraktMovie,
htmlLinkRegex,
} from './utils.js'
// Set to 'html' for HTML links or 'markdown' for markdown links
export const linkFormat = 'html'
export const items = [
{
id: 'blog',
regex: htmlLinkRegex('dylan.weblog.lol'),
getLatest: async () =>
getJsonFeedItemTitle('https://dylan.weblog.lol/feed.json'),
},
{
id: 'pics',
regex: htmlLinkRegex('dylan.some.pics'),
getLatest: async () =>
getRSSItemTitle('https://dylan.some.pics/rss'),
},
{
id: 'lastfm',
regex: htmlLinkRegex('www.last.fm/user/lookathimthere'),
getLatest: async () =>
getRSSItemTitle('https://lfm.xiffy.nl/lookathimthere'),
},
{
id: 'mastodon',
regex: htmlLinkRegex('social.lol/@dylan'),
getLatest: async () =>
getMastodonPost('https://social.lol/@dylan.rss'),
},
{
id: 'letterboxd',
regex: htmlLinkRegex('letterboxd.com/STFUDonny'),
getLatest: async () =>
getLetterboxdActivity('stfudonny', false),
},
{
id: 'trakt-episode',
regex: htmlLinkRegex('trakt.tv/episodes'),
getLatest: async () =>
getTraktEpisode('crankle', '78e1e87b446901f7e4f0883dd4995cec', false),
},
{
id: 'trakt-movie',
regex: htmlLinkRegex('trakt.tv/movies'),
getLatest: async () =>
getTraktMovie('crankle', '78e1e87b446901f7e4f0883dd4995cec', false),
},
]