diff --git a/.github/workflows/feedbot.yml b/.github/workflows/feedbot.yml index d3bcb97..d09ce3c 100644 --- a/.github/workflows/feedbot.yml +++ b/.github/workflows/feedbot.yml @@ -19,11 +19,11 @@ jobs: rss: 'https://www.latimes.com/rss2.0.xml' slack_webhook: ${{ secrets.SLACK_WEBHOOK }} interval: 5 - unfurl: true + unfurl: false - name: WaPo uses: 'selfagency/feedbot@main' with: rss: 'https://feeds.washingtonpost.com/rss/homepage' slack_webhook: ${{ secrets.SLACK_WEBHOOK }} interval: 5 - unfurl: true \ No newline at end of file + unfurl: false \ No newline at end of file diff --git a/action.js b/action.js index 23f036d..979095c 100644 --- a/action.js +++ b/action.js @@ -64,7 +64,13 @@ const run = async () => { text = `<${item.link}|${item.title}> · ${date}`; } else { if (item.title) text += `*${item.title}* · ${date}\n`; - if (item.description) text += `${item.description}\n`; + if (item.description) { + if (item.description.length > 255) { + text += `${item.description.substring(0, 254)}...\n`; + } else { + text += `${item.description}\n`; + } + } if (item.link) text += `<${item.link}|Read more>`; } diff --git a/package.json b/package.json index 4da4e90..298555d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "feedbot", - "version": "1.0.6", + "version": "1.0.7", "main": "action.js", "author": "Daniel Sieradski ", "license": "MIT",