Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(sqlite-storage): scaffold workspace #1071

Merged
merged 15 commits into from
Apr 8, 2024
Merged
9 changes: 9 additions & 0 deletions .github/actions/setup-project/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,18 @@ inputs:
required: false
description: node version to install
default: 20.10.0 # is already cached in Ubuntu 22.04 runner
windows-fix:
required: false
description: https://github.com/actions/setup-node/issues/899#issuecomment-1837381044
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If corepack randomly fails on Windows, maybe we shouldn't enable it?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GH action failed because it was not enabled in first place - that issue came from setup-node itself. Running it first without the cache enables corepack properly (probably not doing checks for yarn versions behind the scene). So the fix here is simply setting node + corepack then enable cache

default: "false"
runs:
using: composite
steps:
- uses: actions/setup-node@v4
if: ${{ inputs.windows-fix == 'true' }}
name: (Windows fix) Setup node without cache
with:
node-version: ${{ inputs.node-version }}
- name: Enable corepack
shell: bash
run: |
Expand Down
15 changes: 15 additions & 0 deletions .github/workflows/default-storage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,21 @@ jobs:
uses: actions/checkout@v4
- name: Setup project
uses: ./.github/actions/setup-project
with:
windows-fix: true
- uses: actions/setup-node@v4
with:
node-version: ${{ inputs.node-version }}
cache: "yarn"
- name: Enable corepack
shell: bash
run: |
corepack enable
yarn --version
- uses: actions/setup-node@v4
with:
node-version: ${{ inputs.node-version }}
cache: "yarn"
- name: Set up MSBuild
uses: microsoft/setup-msbuild@v1.3
- name: Setup VSTest.console.exe
Expand Down
2 changes: 0 additions & 2 deletions packages/sqlite-storage/tests/index.test.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
it.todo("write a test");

function x(_: number) {}