️️⚡️ BUMP ⚡️
sources.config.json 1(+)
#5952
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
# eslint-disable yml/no-empty-mapping-value | |
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node | |
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions | |
name: Node.js CI | |
on: | |
workflow_dispatch: | |
inputs: | |
debug_enabled: | |
type: boolean | |
description: Enable debugging | |
required: false | |
default: false | |
push: | |
branches: [main] | |
pull_request: | |
# https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#schedule | |
schedule: | |
- cron: '5 */2 * * *' | |
jobs: | |
# Job ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ | |
build: | |
name: job ❯ build & run | |
runs-on: ubuntu-22.04 | |
steps: | |
# ───────────────────────────────────────────────────── | |
- name: Github ❯ actions/checkout@v3 | |
uses: actions/checkout@v3 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
fetch-depth: 1 | |
# ───────────────────────────────────────────────────── | |
- name: Bootstrap ❯ Set env variables | |
run: | | |
.github/scripts/helpers set-env-variables | |
# ───────────────────────────────────────────────────── | |
- name: Bootstrap ❯ Prepare Environment | |
run: | | |
. .github/scripts/helpers | |
mkdir -p ~/.local/bin | |
show-system-information | |
dump-env | |
___ | |
helpers create-directories | |
helpers optimize-ubuntu & | |
helpers install-pnpm-binary & | |
helpers install-static-binaries & | |
wait | |
git config user.name github-actions | |
git config user.email [email protected] | |
# ───────────────────────────────────────────────────── | |
# - uses: actions/cache@v3 | |
# name: Bootstrap ❯ Restore Cache | |
# with: | |
# path: ${{ env.ACTIONS_CACHE_DIR }} | |
# key: ${{ runner.os }}-v1-pnpm-store-${{ env.CACHE_PREFIX }}-${{ hashFiles('**/pnpm-lock.yaml') }}-${{ hashFiles('.github/scripts/deps') }} | |
# restore-keys: | | |
# ${{ runner.os }}-v1-pnpm-store-${{ env.CACHE_PREFIX }}- | |
# ───────────────────────────────────────────────────── | |
- name: Bootstrap ❯ Install dependencies | |
run: pstats .github/scripts/deps | |
# ───────────────────────────────────────────────────── | |
- name: Just ❯ cron/download-static-binaries | |
env: | |
GITHUB_TOKEN: ${{ github.token }} | |
run: ./cron/download | |
# ───────────────────────────────────────────────────── | |
- name: Post hooks ❯ Commit to repository | |
if: github.ref == 'refs/heads/main' | |
run: | | |
git add . --verbose | |
stats=$(git diff --cached --shortstat | sed -E 's/ (insertions|deletions)//g') | |
git commit -m "⚡️ CI: $stats [skip ci]" -a || true | |
git push | |
# # ───────────────────────────────────────────────────── | |
# - name: "Debug: Context Information" | |
# id: github_context_step | |
# if: github.ref == 'refs/heads/main' | |
# run: | | |
# helpers show-cache-folders | |
# helpers show-cache-structure | |
# mkdir -p $CONTEXT_DIR &> /dev/null | |
# echo '${{ toJSON(github) }}' >> $CONTEXT_DIR/github.json & | |
# echo '${{ toJSON(job) }}' >> $CONTEXT_DIR/job.json & | |
# echo '${{ toJSON(steps) }}' >> $CONTEXT_DIR/steps.json & | |
# echo '${{ toJSON(runner) }}' >> $CONTEXT_DIR/runner.json & | |
# echo '${{ toJSON(strategy) }}' >> $CONTEXT_DIR/strategy.json & | |
# echo '${{ toJSON(matrix) }}' >> $CONTEXT_DIR/matrix.json & | |
# wait | |
# pstats helpers 'dump-context' |