README build #8998
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Visit https://github.com/lowlighter/metrics#-documentation for full reference | |
# name: Metrics | |
# on: | |
# # Schedule updates (each hour) | |
# schedule: [{cron: "0 * * * *"}] | |
# # Lines below let you run workflow manually and on each commit | |
# workflow_dispatch: | |
# push: {branches: ["main"]} | |
# jobs: | |
# github-metrics: | |
# runs-on: ubuntu-latest | |
# permissions: | |
# contents: write | |
# steps: | |
# - uses: lowlighter/metrics@latest | |
# with: | |
# token: ${{ secrets.GITHUB_TOKEN }} | |
# # Options | |
# user: wibus-wee | |
# template: classic | |
# base: header, activity, community, repositories, metadata | |
# config_display: columns | |
# config_timezone: Asia/Shanghai | |
# config_twemoji: yes | |
# plugin_achievements: yes | |
# plugin_achievements_display: compact | |
# plugin_achievements_secrets: yes | |
# plugin_achievements_threshold: C | |
# plugin_activity: yes | |
# plugin_activity_days: 14 | |
# plugin_activity_filter: all | |
# plugin_activity_limit: 5 | |
# plugin_activity_load: 300 | |
# plugin_activity_visibility: all | |
# plugin_introduction: yes | |
# plugin_introduction_title: yes | |
# plugin_isocalendar: yes | |
# plugin_isocalendar_duration: half-year | |
# plugin_languages: yes | |
# plugin_languages_analysis_timeout: 15 | |
# plugin_languages_categories: markup, programming | |
# plugin_languages_colors: github | |
# plugin_languages_ignored: html | |
# plugin_languages_limit: 8 | |
# plugin_languages_recent_categories: markup, programming | |
# plugin_languages_recent_days: 14 | |
# plugin_languages_recent_load: 300 | |
# plugin_languages_sections: most-used | |
# plugin_languages_threshold: 0% | |
# plugin_notable: yes | |
# plugin_notable_from: organization | |
# plugin_notable_types: commit | |
# plugin_repositories: no | |
# plugin_stars: yes | |
# plugin_stars_limit: 4 | |
# plugin_wakatime: yes | |
# plugin_wakatime_days: 7 | |
# plugin_wakatime_limit: 5 | |
# plugin_wakatime_sections: time, languages-graphs, os-graphs | |
# plugin_wakatime_url: https://wakatime.com | |
# plugin_wakatime_token: ${{ secrets.WAKATIME_API_KEY }} | |
# plugin_wakatime_languages_other: yes | |
# plugin_wakatime_languages_ignored: Other | |
name: README build | |
on: | |
push: | |
branches: | |
- main | |
schedule: | |
- cron: '0 */3 * * *' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [16.x] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Cache pnpm modules | |
uses: actions/cache@v2 | |
env: | |
cache-name: cache-pnpm-modules | |
with: | |
path: ~/.pnpm-store | |
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ matrix.node-version }}-${{ hashFiles('**/pnpm-lock.yaml') }} | |
restore-keys: | | |
${{ runner.os }}-build-${{ env.cache-name }}-${{ matrix.node-version }}- | |
- uses: pnpm/[email protected] | |
with: | |
version: 6.0.2 | |
run_install: true | |
- name: Build project | |
run: | | |
npm run build | |
- name: Push new README.md | |
uses: mikeal/publish-to-github-action@master | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
BRANCH_NAME: 'main' |