DEV Community

loading...

HackerNews action

jun
A dev enthusiast 👩🏻‍💻 and a pianist 🎹 Love to create things and help others to achieve their goals with web development ✨
・1 min read

My Workflow

Get top 5 hackernews daily with GitHub action 🗞

name: 🗞 Daily Top HackerNews

on:
  schedule:
    - cron: '0 9 * * *' # Every day at 9am
  push:
    branches: [ master ]

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - name: checkout
      uses: actions/checkout@v2

    - name: daily-top-hackernews
      id: hackernews
      uses: ./ # Uses an action in the root directory
      with:
        run: echo "${{ steps.hackernews.outputs.msg }}"
        news: 5
Enter fullscreen mode Exit fullscreen mode

Submission Category:

Wacky Wildcards

Yaml File or Link to Code

GitHub logo jun-low / hackernews-action

🗞 Get daily top 5 hacker news with GitHub action

🗞 hackernews-action

Get top 5 daily hacker news with GitHub action.

Usage

Get top 5 hacker news everyday.

name: 🗞 Daily Top HackerNews

on:
  schedule:
    - cron: '0 9 * * *' # Every day at 9am
  push:
    branches: [ master ]

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - name: checkout
      uses: actions/checkout@v2

    - name: daily-top-hackernews
      id: hackernews
      uses: ./ # Uses an action in the root directory
      with:
        run: echo "${{ steps.hackernews.outputs.msg }}"
        news: 5

License

MIT

Discussion (0)

Forem Open with the Forem app