Skip to content

Commit

Permalink
Update GitHub workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
rygine committed Oct 9, 2024
1 parent d2a733b commit 8a7f085
Show file tree
Hide file tree
Showing 5 changed files with 122 additions and 62 deletions.
94 changes: 94 additions & 0 deletions .github/workflows/content-types.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
name: Content types

on:
push:
branches:
- main

pull_request:
paths:
- "content-types/**"
- ".github/workflows/content-types.yml"
- "dev/**"
- ".node-version"
- ".nvmrc"
- ".yarnrc.yml"
- "turbo.json"
- "yarn.lock"

jobs:
typecheck:
name: Typecheck
runs-on: warp-ubuntu-latest-x64-8x
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "yarn"
env:
SKIP_YARN_COREPACK_CHECK: "1"
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: yarn
- name: Typecheck
run: yarn turbo run typecheck --filter='./content-types/*'

lint:
name: Lint
runs-on: warp-ubuntu-latest-x64-8x
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "yarn"
env:
SKIP_YARN_COREPACK_CHECK: "1"
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: yarn
- name: Lint
run: yarn turbo run lint --filter='./content-types/*'

test:
name: Test
runs-on: warp-ubuntu-latest-x64-8x
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "yarn"
env:
SKIP_YARN_COREPACK_CHECK: "1"
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: yarn
- name: Start dev environment
run: ./dev/up
- name: Sleep for 5 seconds
run: sleep 5s
- name: Run tests
run: yarn turbo run test --filter='./content-types/*'

build:
name: Build
runs-on: warp-ubuntu-latest-x64-8x
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "yarn"
env:
SKIP_YARN_COREPACK_CHECK: "1"
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: yarn
- name: Build
run: yarn turbo run build --filter='./content-types/*'
22 changes: 0 additions & 22 deletions .github/workflows/js-sdk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ on:
- "dev/**"
- ".node-version"
- ".nvmrc"
- ".prettierignore"
- ".prettierrc.cjs"
- ".yarnrc.yml"
- "turbo.json"
- "yarn.lock"
Expand Down Expand Up @@ -59,26 +57,6 @@ jobs:
cd packages/js-sdk
yarn lint
prettier:
name: Prettier
runs-on: warp-ubuntu-latest-x64-8x
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "yarn"
env:
SKIP_YARN_COREPACK_CHECK: "1"
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: yarn
- name: Format check
run: |
cd packages/js-sdk
yarn format:check
test:
name: Test
runs-on: warp-ubuntu-latest-x64-8x
Expand Down
22 changes: 0 additions & 22 deletions .github/workflows/mls-client.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ on:
- "dev/**"
- ".node-version"
- ".nvmrc"
- ".prettierignore"
- ".prettierrc.cjs"
- ".yarnrc.yml"
- "turbo.json"
- "yarn.lock"
Expand Down Expand Up @@ -59,26 +57,6 @@ jobs:
cd packages/mls-client
yarn lint
prettier:
name: Prettier
runs-on: warp-ubuntu-latest-x64-8x
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "yarn"
env:
SKIP_YARN_COREPACK_CHECK: "1"
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: yarn
- name: Format check
run: |
cd packages/mls-client
yarn format:check
test:
name: Test
runs-on: warp-ubuntu-latest-x64-8x
Expand Down
19 changes: 1 addition & 18 deletions .github/workflows/noop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ on:
- ".github/**"
- "!.github/workflows/js-sdk.yml"
- "!.github/workflows/mls-client.yml"
- "!.github/workflows/content-types.yml"
- ".vscode/**"
- ".yarn/**"
- "*"
Expand All @@ -35,24 +36,6 @@ jobs:
steps:
- run: echo "Nothing to lint"

prettier:
name: Prettier
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "yarn"
env:
SKIP_YARN_COREPACK_CHECK: "1"
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: yarn
- name: Format check
run: yarn prettier -c .

test:
name: Test
runs-on: ubuntu-latest
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/prettier.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Format check

on:
push:
branches:
- main

pull_request:

jobs:
prettier:
name: Prettier
runs-on: warp-ubuntu-latest-x64-8x
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "yarn"
env:
SKIP_YARN_COREPACK_CHECK: "1"
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: yarn
- name: Format check
run: yarn format:check

0 comments on commit 8a7f085

Please sign in to comment.