Skip to content

Merge pull request #37 from wadakatu/feature/migrate-to-anthropic #129

Merge pull request #37 from wadakatu/feature/migrate-to-anthropic

Merge pull request #37 from wadakatu/feature/migrate-to-anthropic #129

Workflow file for this run

name: CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
install:
runs-on: ubuntu-latest
outputs:
cache-key: ${{ steps.cache-key.outputs.key }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install mise
uses: jdx/mise-action@v2
with:
cache: 'true'
install: 'true'
- name: Setup tools with mise
run: mise install
- name: Generate cache key
id: cache-key
run: echo "key=${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}" >> $GITHUB_OUTPUT
- name: Cache pnpm store
uses: actions/cache@v4
id: pnpm-cache
with:
path: ~/.local/share/pnpm/store
key: ${{ steps.cache-key.outputs.key }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
if: steps.pnpm-cache.outputs.cache-hit != 'true'
run: pnpm install --frozen-lockfile
# GitLyte Core (メインアプリケーション) のCI
core-lint:
runs-on: ubuntu-latest
needs: install
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install mise
uses: jdx/mise-action@v2
with:
cache: 'true'
install: 'true'
- name: Cache pnpm store
uses: actions/cache@v4
id: pnpm-cache
with:
path: ~/.local/share/pnpm/store
key: ${{ needs.install.outputs.cache-key }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
if: steps.pnpm-cache.outputs.cache-hit != 'true'
run: pnpm install --frozen-lockfile
- name: Run Core lint check
run: pnpm --filter @gitlyte/core lint
core-format:
runs-on: ubuntu-latest
needs: install
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install mise
uses: jdx/mise-action@v2
with:
cache: 'true'
install: 'true'
- name: Cache pnpm store
uses: actions/cache@v4
id: pnpm-cache
with:
path: ~/.local/share/pnpm/store
key: ${{ needs.install.outputs.cache-key }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
if: steps.pnpm-cache.outputs.cache-hit != 'true'
run: pnpm install --frozen-lockfile
- name: Run Core format check
run: pnpm --filter @gitlyte/core format
core-build:
runs-on: ubuntu-latest
needs: install
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install mise
uses: jdx/mise-action@v2
with:
cache: 'true'
install: 'true'
- name: Cache pnpm store
uses: actions/cache@v4
id: pnpm-cache
with:
path: ~/.local/share/pnpm/store
key: ${{ needs.install.outputs.cache-key }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
if: steps.pnpm-cache.outputs.cache-hit != 'true'
run: pnpm install --frozen-lockfile
- name: Run Core TypeScript build check
run: pnpm --filter @gitlyte/core build
core-test:
runs-on: ubuntu-latest
needs: install
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install mise
uses: jdx/mise-action@v2
with:
cache: 'true'
install: 'true'
- name: Cache pnpm store
uses: actions/cache@v4
id: pnpm-cache
with:
path: ~/.local/share/pnpm/store
key: ${{ needs.install.outputs.cache-key }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
if: steps.pnpm-cache.outputs.cache-hit != 'true'
run: pnpm install --frozen-lockfile
- name: Run Core tests
run: pnpm --filter @gitlyte/core test
# 最終的な統合チェック
ci-success:
runs-on: ubuntu-latest
needs:
- core-lint
- core-format
- core-build
- core-test
steps:
- name: CI Success
run: echo "✅ All CI checks passed successfully!"