Skip to content

Commit a007ece

Browse files
committed
fix: force clean install when yalc fallback is triggered
When switching from yalc link to file link, remove yarn.lock and cached node_modules to ensure yarn install picks up the new link. Add --force flag to yarn install to bypass cache completely.
1 parent 76397d0 commit a007ece

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

.github/workflows/tests.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,12 @@ jobs:
4646
if [ ! -d ".yalc/strapi-plugin-config-sync" ]; then
4747
echo "Yalc link failed, using file link as fallback"
4848
sed -i 's|"strapi-plugin-config-sync": "link:.yalc/strapi-plugin-config-sync"|"strapi-plugin-config-sync": "file:.."|' package.json
49+
# Remove lock and cache to ensure fresh install
50+
rm -f yarn.lock
51+
rm -rf node_modules/strapi-plugin-config-sync
4952
fi
5053
- name: Install dependencies playground
51-
run: cd playground && yarn install --unsafe-perm
54+
run: cd playground && yarn install --unsafe-perm --force
5255
- name: Build playground
5356
run: yarn playground:build
5457
# - name: Run unit tests

0 commit comments

Comments
 (0)