mirror of
https://github.com/vectorize-io/hindsight.git
synced 2026-09-14 19:31:49 +08:00
cb0e1dea40
The api.star-history.com embed in the README was broken. Replace it with nicoloboschi/gh-stars, which backfills stargazer data via a scheduled GitHub Action and commits a self-hosted SVG chart into the repo, so the README image no longer depends on a third-party service.
30 lines
786 B
YAML
30 lines
786 B
YAML
name: Update star history
|
|
|
|
on:
|
|
schedule:
|
|
- cron: '17 3 * * *'
|
|
workflow_dispatch:
|
|
|
|
permissions:
|
|
contents: write
|
|
|
|
jobs:
|
|
update:
|
|
concurrency:
|
|
group: star-history
|
|
cancel-in-progress: false
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: nicoloboschi/gh-stars@v1
|
|
with:
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
line-color: '#14b8a6'
|
|
- name: Commit chart
|
|
run: |
|
|
git config user.name 'github-actions[bot]'
|
|
git config user.email '41898282+github-actions[bot]@users.noreply.github.com'
|
|
git add .github/star-history/data.json .github/star-history/chart.svg
|
|
git diff --cached --quiet || git commit -m 'chore: update star history'
|
|
git push
|