Skip to content

Generate Badges

Generate Badges #1011

Workflow file for this run

name: Generate Badges
on:
push:
branches:
- master
schedule:
- cron: "0 0 * * *"
jobs:
get-badges:
runs-on: ubuntu-latest
env:
YARN_NODE_LINKER: node-modules
steps:
- uses: actions/checkout@v3.0.2
- name: Use Node.js
uses: actions/setup-node@v3.2.0
with:
node-version: 16
- run: corepack enable
- run: yarn install
env:
YARN_ENABLE_IMMUTABLE_INSTALLS: false
- id: libyear
uses: s0/libyear-node-action@v0.1.2
- run: mkdir badges
- uses: emibcn/badge-action@v1.2.4
with:
label: "libyear drift"
status: ${{ steps.libyear.outputs.drift }} year(s) behind
color: "blue"
path: "badges/drift.svg"
- uses: emibcn/badge-action@v1.2.4
with:
label: "libyear pulse"
status: ${{ steps.libyear.outputs.pulse }} year(s) behind
color: "blue"
path: "badges/pulse.svg"
- uses: emibcn/badge-action@v1.2.4
with:
label: "libyear"
status: ${{ steps.libyear.outputs.releases }} release(s) behind
color: "blue"
path: "badges/releases.svg"
- uses: emibcn/badge-action@v1.2.4
with:
label: "libyear"
status: ${{ steps.libyear.outputs.major }} major release(s) behind
color: "blue"
path: "badges/major.svg"
- uses: emibcn/badge-action@v1.2.4
with:
label: "libyear"
status: ${{ steps.libyear.outputs.minor }} minor release(s) behind
color: "blue"
path: "badges/minor.svg"
- uses: emibcn/badge-action@v1.2.4
with:
label: "libyear"
status: ${{ steps.libyear.outputs.patch }} patch release(s) behind
color: "blue"
path: "badges/patch.svg"
- name: Push badges to gh-badges directory
uses: s0/git-publish-subdir-action@v2.5.1
env:
REPO: self
BRANCH: gh-badges
FOLDER: badges
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SQUASH_HISTORY: true