Skip to content

Commit 001dda7

Browse files
fix: skip all caching in publish CI
TICKET: WP-6096
1 parent 3e3b453 commit 001dda7

File tree

1 file changed

+25
-10
lines changed

1 file changed

+25
-10
lines changed

.github/workflows/publish.yml

Lines changed: 25 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
name: Publish @bitgo-beta
22
on:
33
workflow_dispatch:
4-
# push:
5-
# branches:
6-
# - master
74

85
permissions:
96
contents: write
@@ -14,6 +11,10 @@ concurrency:
1411
env:
1512
NX_NO_CLOUD: true
1613
NX_SKIP_NX_CACHE: true
14+
NX_DISABLE_NX_CACHE: true
15+
NX_SKIP_REMOTE_CACHE: true
16+
NX_DISABLE_REMOTE_CACHE: true
17+
NX_CACHE: false
1718

1819
jobs:
1920
publish:
@@ -29,9 +30,6 @@ jobs:
2930
with:
3031
node-version-file: .nvmrc
3132

32-
- name: Install BitGoJS
33-
run: yarn install --with-frozen-lockfile
34-
3533
- name: Set Environment Variable for Alpha
3634
if: github.ref != 'refs/heads/master' # only publish changes if on feature branches
3735
run: |
@@ -52,16 +50,33 @@ jobs:
5250
echo "@bitgo-beta:registry=https://registry.npmjs.org" >> .npmrc
5351
echo "//registry.npmjs.org/:_authToken=${{ secrets.BETA_TOKEN }}" >> .npmrc
5452
echo "//registry.npmjs.org/:always-auth=true" >> .npmrc
53+
54+
- name: Clean all caches
55+
run: |
56+
# Clean NX cache
57+
npx nx reset
58+
# Clean TypeScript incremental build cache
59+
find . -name "tsconfig.tsbuildinfo" -delete
60+
# Clean dist directories to force full rebuild
61+
find ./modules -name "dist" -type d -exec rm -rf {} + 2>/dev/null || true
62+
# Clean node_modules/.cache
63+
find ./modules -path "*/node_modules/.cache" -type d -exec rm -rf {} + 2>/dev/null || true
64+
65+
- name: Rebuild packages
66+
env:
67+
NOYARNPOSTINSTALL: true
68+
run: |
69+
# Install packages without cache
70+
yarn install --with-frozen-lockfile --ignore-scripts
71+
# Rebuild packages without cache - ensure all packages are built
72+
yarn lerna run build --stream --no-cache
5573
5674
- name: Prepare Release
5775
run: |
5876
rm -rfd ./modules/web-demo
5977
rm -rfd ./modules/express
6078
npx tsx ./scripts/prepare-release.ts ${{ env.preid }}
61-
62-
- name: Rebuild packages
63-
run: yarn
64-
79+
6580
- name: Commit Local Changes
6681
run: git commit -am "Auto updated ${{ env.preid }} branch" --no-verify || echo "No changes to commit"
6782

0 commit comments

Comments
 (0)