Skip to content

Commit d6c3438

Browse files
authored
Merge pull request #24 from pie-framework/fix/PIE-447-wip
fix: wire npm auth correctly in release workflow; exclude math-inline…
2 parents a5f8b9b + 852dd27 commit d6c3438

3 files changed

Lines changed: 14 additions & 4 deletions

File tree

.changeset/config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@
77
"access": "public",
88
"baseBranch": "master",
99
"updateInternalDependencies": "patch",
10-
"ignore": ["esm-player-test"]
10+
"ignore": ["esm-player-test", "@pie-element/math-inline", "@pie-element/math-templated"]
1111
}

.github/workflows/release.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ jobs:
9090
uses: actions/setup-node@v4
9191
with:
9292
node-version: 20.x
93+
registry-url: 'https://registry.npmjs.org'
9394

9495
- name: Setup Bun
9596
uses: oven-sh/setup-bun@v2
@@ -319,8 +320,8 @@ jobs:
319320
commit: 'chore(release): version packages'
320321
env:
321322
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
322-
NPM_TOKEN: ${{ env.PUBLISH_NPM_TOKEN }}
323-
NODE_AUTH_TOKEN: ${{ env.PUBLISH_NODE_AUTH_TOKEN }}
323+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
324+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
324325
NPM_CONFIG_REGISTRY: https://registry.npmjs.org/
325326
RELEASE_CHANNEL: ${{ steps.release_channel.outputs.channel }}
326327

scripts/changeset-publish-resolved-workspaces.mjs

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -563,7 +563,16 @@ const collectRuntimeWorkspaceDependencyClosure = (targetPackages) => {
563563
});
564564
}
565565

566-
stack.push(dependency.dependencyName);
566+
// Only recurse into a workspace dep if it is also being published in this
567+
// run. If it is already on npm at the correct version, its published
568+
// manifest has already-resolved (non-workspace) deps — there is no need
569+
// to walk its local workspace package.json, and doing so would
570+
// incorrectly flag transitive workspace:* refs that are irrelevant to
571+
// the consumer (e.g. @pie-lib/render-ui@6.1.0 on npm having a local
572+
// workspace:* on @pie-lib/math-rendering which hasn't been republished).
573+
if (targetPackages.has(dependency.dependencyName)) {
574+
stack.push(dependency.dependencyName);
575+
}
567576
}
568577
}
569578

0 commit comments

Comments
 (0)