This GitHub Action generates a README.md
summary for your events repository. You can use the repository as a source of truth for the events you participate it.
First, setup your repository with this file structure:
βββ README.md
βββ .github
β βββ workflows
β βββ readme.yml
βββ events
βββ 2019
β βββ event-name.md
β βββ another-event-name.md
βββ 2020
βββ a-third-event-name.md
Add the following comment in your README.md
file. This will be replaced with a summary of the events you've participated it:
<!--events--><!--/events-->
Finally, create the GitHub Actions workflow in .github/workflows/readme.yml
:
name: Readme CI
on:
push:
branches: [main]
schedule:
- cron: "0 0 * * *"
jobs:
release:
name: Update README
runs-on: ubuntu-18.04
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Update event summary
uses: AnandChowdhary/events-summary@main
with:
token: "${{ secrets.GITHUB_TOKEN }}"
- name: Publish package
uses: stefanzweifel/git-auto-commit-action@v4.9.2
with:
commit_message: ":pencil: Generate README summary [skip ci]"
Your README.md
file should then contains a summary of the events in the events
directory:
- Code: MIT Β© Anand Chowdhary
- "GitHub" is a trademark of GitHub, Inc.