Skip to content

Commit 8cbc21c

Browse files
committed
chore: add ci
1 parent 55a8132 commit 8cbc21c

File tree

5 files changed

+129
-0
lines changed

5 files changed

+129
-0
lines changed
+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Turbo build
2+
inputs:
3+
node-version:
4+
description: Node version
5+
required: true
6+
default: 22.x
7+
runs:
8+
using: composite
9+
steps:
10+
- name: Cache turbo build setup
11+
uses: actions/cache@v3
12+
with:
13+
path: .turbo
14+
key: ${{ runner.os }}-turbo-${{ inputs.node-version }}-build-${{ github.sha }}
15+
restore-keys: |
16+
${{ runner.os }}-turbo-${{ inputs.node-version }}-build-
17+
- uses: pnpm/action-setup@v2
18+
- name: Use Node.js ${{ inputs.node-version }}
19+
uses: actions/setup-node@v4
20+
with:
21+
node-version: ${{ inputs.node-version }}
22+
cache: pnpm
23+
- run: pnpm install
24+
shell: bash
25+
- run: pnpm turbo build --cache-dir=.turbo
26+
shell: bash

.github/dependabot.yml

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
version: 2
2+
3+
updates:
4+
- package-ecosystem: npm
5+
directory: "/"
6+
labels:
7+
- "automerge"
8+
schedule:
9+
interval: daily
10+
open-pull-requests-limit: 25
11+
groups:
12+
drizzle:
13+
patterns:
14+
- "drizzle-kit"
15+
- "drizzle-orm"
16+
effect:
17+
patterns:
18+
- "@effect/*"
19+
- "effect"
20+
otel:
21+
patterns:
22+
- "@opentelemetry/*"
23+
tooling:
24+
patterns:
25+
- "turbo"
26+
- "tsx"
27+
- "dprint"
28+
- "@microsoft/api-extractor"
29+
- package-ecosystem: github-actions
30+
directory: "/"
31+
schedule:
32+
interval: weekly

.github/workflows/ci.yml

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Continuous Integration and Deployment
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
7+
permissions:
8+
contents: write
9+
pages: write
10+
id-token: write
11+
pull-requests: write
12+
13+
jobs:
14+
run-ci:
15+
uses: ./.github/workflows/reusable-ci.yml
16+
17+
all:
18+
needs: [run-ci]
19+
runs-on: ubuntu-latest
20+
if: always()
21+
steps:
22+
- name: Check job status
23+
if: contains(needs.*.result, 'failure')
24+
run: exit 1
25+
- name: All jobs completed successfully
26+
if: success()
27+
run: echo "All jobs completed successfully!"

.github/workflows/pr-ci.yml

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
name: Pull Request CI
2+
3+
on:
4+
pull_request:
5+
branches: [ master ]
6+
7+
permissions: read-all
8+
9+
jobs:
10+
run-ci:
11+
uses: ./.github/workflows/reusable-ci.yml

.github/workflows/reusable-ci.yml

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Reusable CI Workflow
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
upload-artifacts:
7+
type: boolean
8+
default: false
9+
required: false
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
strategy:
15+
matrix:
16+
node-version: [22.x]
17+
steps:
18+
- uses: actions/checkout@v4.1.7
19+
- uses: ./.github/actions/turbo-build
20+
with:
21+
node-version: ${{ matrix.node-version }}
22+
23+
all:
24+
needs: [build]
25+
runs-on: ubuntu-latest
26+
if: always()
27+
steps:
28+
- name: Check job status
29+
if: contains(needs.*.result, 'failure')
30+
run: exit 1
31+
- name: All jobs completed successfully
32+
if: success()
33+
run: echo "All jobs completed successfully!"

0 commit comments

Comments
 (0)