2022-07-28 17:46:12 +00:00
|
|
|
name: Tipi CI
|
|
|
|
on:
|
2023-06-20 17:34:42 +00:00
|
|
|
pull_request:
|
2023-07-05 22:27:57 +00:00
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
2023-06-20 20:52:42 +00:00
|
|
|
|
2022-07-28 17:46:12 +00:00
|
|
|
jobs:
|
|
|
|
ci:
|
2023-07-05 22:27:57 +00:00
|
|
|
if: "!contains(github.head_ref, 'renovate/')"
|
2022-07-28 17:46:12 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2024-06-19 05:28:01 +00:00
|
|
|
uses: actions/checkout@v4.1.7
|
2022-07-28 17:46:12 +00:00
|
|
|
|
|
|
|
- name: Install Node.js
|
2024-03-04 19:36:08 +00:00
|
|
|
uses: actions/setup-node@v4
|
2022-07-28 17:46:12 +00:00
|
|
|
with:
|
2023-06-21 19:11:50 +00:00
|
|
|
node-version: 18
|
2022-07-28 17:46:12 +00:00
|
|
|
|
2024-05-19 12:07:46 +00:00
|
|
|
- uses: pnpm/action-setup@v4.0.0
|
2022-07-28 17:46:12 +00:00
|
|
|
name: Install pnpm
|
|
|
|
id: pnpm-install
|
|
|
|
with:
|
2023-06-21 19:11:50 +00:00
|
|
|
version: 8
|
2022-07-28 17:46:12 +00:00
|
|
|
run_install: false
|
|
|
|
|
|
|
|
- name: Get pnpm store directory
|
|
|
|
id: pnpm-cache
|
|
|
|
run: |
|
2023-06-20 20:52:42 +00:00
|
|
|
echo "pnpm_cache_dir=$(pnpm store path)" >> $GITHUB_OUTPUT
|
2022-07-28 17:46:12 +00:00
|
|
|
|
2024-03-04 07:39:31 +00:00
|
|
|
- uses: actions/cache@v4
|
2022-07-28 17:46:12 +00:00
|
|
|
name: Setup pnpm cache
|
|
|
|
with:
|
|
|
|
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }}
|
|
|
|
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
|
|
|
|
restore-keys: |
|
|
|
|
${{ runner.os }}-pnpm-store-
|
|
|
|
|
|
|
|
- name: Install dependencies
|
|
|
|
run: pnpm install
|
|
|
|
|
|
|
|
- name: Run global tests
|
2022-08-24 09:37:18 +00:00
|
|
|
run: pnpm test
|
|
|
|
|
|
|
|
- name: Run linter
|
2023-06-20 17:34:42 +00:00
|
|
|
run: pnpm run lint
|