Skip to content

Commit

Permalink
New version using feed-extractor
Browse files Browse the repository at this point in the history
  • Loading branch information
chriscarrollsmith committed Oct 1, 2023
1 parent ae03edb commit ea202da
Show file tree
Hide file tree
Showing 8 changed files with 462 additions and 467 deletions.
15 changes: 4 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,20 +42,13 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Test Local Action with JSON
- name: Test Github Action with JSON
uses: ./
with:
feed_url: "https://modelingmarkets.substack.com/feed"
file_path: "temp.json"
file_path: "./feed.json"
parser_options: "{\"useISODateFormat\": false, \"getExtraEntryFields\": \"(feedEntry) => { return { 'content:encoded': feedEntry['content:encoded'] || '' }; }\"}"
fetch_options: "{}"

- name: Validate JSON
run: node -e "const fs = require('fs'); const data = fs.readFileSync('temp.json', 'utf8'); const obj = JSON.parse(data); if (!obj || !obj.rss || !obj.rss.$) { console.error('Invalid object'); process.exit(1); }"

- name: Test Local Action with XML
uses: ./
with:
feed_url: "https://modelingmarkets.substack.com/feed"
file_path: "temp.xml"

- name: Validate XML
run: node -e "const fs = require('fs'); const data = fs.readFileSync('temp.xml', 'utf8'); if (!data.includes('<rss') || !data.includes('</rss>')) { console.error('Invalid XML'); process.exit(1); }"
Loading

0 comments on commit ea202da

Please sign in to comment.