chore: misc updates
This commit is contained in:
parent
1746f8803a
commit
86b4a96a9e
16 changed files with 32 additions and 37 deletions
|
@ -1,20 +1,26 @@
|
|||
const EleventyFetch = require('@11ty/eleventy-fetch')
|
||||
|
||||
module.exports = async function () {
|
||||
const API_TOKEN_PINBOARD = process.env.API_TOKEN_PINBOARD
|
||||
const url = `https://api.pinboard.in/v1/posts/recent?auth_token=${API_TOKEN_PINBOARD}&format=json&tag=share`
|
||||
const API_TOKEN_READWISE = process.env.API_TOKEN_READWISE
|
||||
const url = 'https://readwise.io/api/v3/list?location=archive'
|
||||
const res = EleventyFetch(url, {
|
||||
duration: '1h',
|
||||
type: 'json',
|
||||
fetchOptions: {
|
||||
headers: {
|
||||
Authorization: `Token ${API_TOKEN_READWISE}`,
|
||||
},
|
||||
},
|
||||
}).catch()
|
||||
const links = await res
|
||||
return links['posts'].map((link) => {
|
||||
const data = await res
|
||||
const links = data['results'].map((link) => {
|
||||
return {
|
||||
title: link['description'],
|
||||
url: link['href'],
|
||||
tags: [...new Set(link['tags'].split(' '))],
|
||||
date: link['time'],
|
||||
description: `${link['extended']}<br/><br/>`,
|
||||
title: link['title'],
|
||||
url: link['source_url'],
|
||||
tags: [...new Set(Object.keys(link['tags']))],
|
||||
date: link['created_at'],
|
||||
description: `${link['summary']}<br/><br/>`,
|
||||
}
|
||||
})
|
||||
return links.filter((link) => link.tags.includes('share'))
|
||||
}
|
||||
|
|
|
@ -10,8 +10,7 @@ module.exports = async function () {
|
|||
{ name: 'Webrings', icon: 'heart-handshake' },
|
||||
],
|
||||
social: [
|
||||
{ name: 'Email', url: 'mailto:coryd@fastmail.com', icon: 'at' },
|
||||
{ name: 'Calendar', url: 'https://savvycal.com/ced/', icon: 'calendar-plus' },
|
||||
{ name: 'Email', url: 'mailto:cory.dransfeldt@gmail.com', icon: 'brand-gmail' },
|
||||
{ name: 'GitHub', url: 'https://github.com/cdransf', icon: 'brand-github' },
|
||||
{ name: 'Mastodon', url: 'https://social.lol/@cory', icon: 'brand-mastodon' },
|
||||
{
|
||||
|
@ -21,17 +20,7 @@ module.exports = async function () {
|
|||
},
|
||||
{ name: 'Trakt', url: 'https://trakt.tv/users/cdransf', icon: 'device-tv' },
|
||||
{ name: 'The StoryGraph', url: 'https://app.thestorygraph.com/profile/coryd', icon: 'books' },
|
||||
{ name: 'Pinboard', url: 'http://pinboard.in/u:cdme', icon: 'pin' },
|
||||
{ name: 'Buy Me a Coffee', url: 'https://www.buymeacoffee.com/cory', icon: 'cup' },
|
||||
],
|
||||
resume: [
|
||||
{ name: 'GitHub', url: 'https://github.com/cdransf', icon: 'brand-github' },
|
||||
{ name: 'LinkedIn', url: 'https://www.linkedin.com/in/cdransf/', icon: 'brand-linkedin' },
|
||||
{
|
||||
name: 'Calendar',
|
||||
url: 'https://coryd.dev/calendar',
|
||||
icon: 'calendar-plus',
|
||||
},
|
||||
],
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
module.exports = async function () {
|
||||
return {
|
||||
name: 'Cory Dransfeldt',
|
||||
email: 'coryd@fastmail.com',
|
||||
email: 'cory.dransfeldt@gmail.com',
|
||||
url: 'https://coryd.dev',
|
||||
logo: 'https://coryd.dev/assets/img/logo.webp',
|
||||
title: 'Cory Dransfeldt',
|
||||
|
|
Reference in a new issue