-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor(ci): Use setup-node cache instead of bahmutov/npm-install
* it appears that the caching ability of the library is broken * @see: bahmutov/npm-install#146
- Loading branch information
Showing
1 changed file
with
16 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -32,22 +32,28 @@ jobs: | |
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Enable Corepack | ||
run: corepack enable | ||
|
||
- name: Set up Node | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
|
||
- name: Enable Corepack | ||
run: corepack enable | ||
|
||
- name: Fetch Git history | ||
run: git fetch --no-tags --depth=50 origin main | ||
cache: 'yarn' | ||
|
||
- name: Install dependencies | ||
uses: bahmutov/[email protected] | ||
with: | ||
useRollingCache: true | ||
install-command: yarn --immutable | ||
run: yarn --immutable | ||
|
||
- name: Check node_modules or .yarn/cache | ||
run: | | ||
ls -la | ||
if [ -d "node_modules" ]; then | ||
echo "node_modules exists" | ||
elif [ -d ".yarn/cache" ]; then | ||
echo ".yarn/cache exists" | ||
else | ||
echo "Dependency directory not found" | ||
fi | ||
- name: Build packages | ||
run: yarn build |