Skip to content

Commit 40c4b1f

Browse files
authored
chore: Allow dirty for jsr publish. (#443)
The root cause is .yarnrc.yml being modified because of the addition of npmRegistryServer: ```shell Publishing jsr: @launchdarkly/cloudflare-server-sdk diff --git a/.yarnrc.yml b/.yarnrc.yml index 5a857be..7cbcb75 100644 --- a/.yarnrc.yml +++ b/.yarnrc.yml @@ -4,10 +4,14 @@ npmPublishAccess: public npmScopes: jsr: - npmRegistryServer: 'https://npm.jsr.io/' + npmRegistryServer: "https://npm.jsr.io/" + launchdarkly: + npmAlwaysAuth: true + npmAuthToken: *** + npmRegistryServer: "https://registry.npmjs.org/" plugins: - path: .yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs - spec: '@yarnpkg/plugin-workspace-tools' + spec: "@yarnpkg/plugin-workspace-tools" ```
1 parent 1587216 commit 40c4b1f

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

.github/workflows/manual-publish.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ jobs:
8181
aws_assume_role: ${{ vars.AWS_ROLE_ARN }}
8282
ssm_parameter_pairs: '/production/common/releasing/npm/token = NODE_AUTH_TOKEN'
8383
- name: Setup .yarnrc.yml
84+
if: ${{ inputs.package_registry == 'npm' }}
8485
shell: bash
8586
run: |
8687
yarn config set npmScopes.launchdarkly.npmRegistryServer "https://registry.npmjs.org"

scripts/publish-jsr.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ if [ -f "./$WORKSPACE_PATH/jsr.json" ]; then
55

66
if $LD_RELEASE_IS_DRYRUN ; then
77
echo "Doing a dry run of jsr publishing."
8-
npx jsr publish --dry-run || { echo "jsr publish failed" >&2; exit 1; }
8+
npx jsr publish --dry-run --allow-dirty || { echo "jsr publish failed" >&2; exit 1; }
99
elif [ -f "./$WORKSPACE_PATH/jsr.json" ]; then
1010
echo "Publishing to jsr."
11-
npx jsr publish || { echo "jsr publish failed" >&2; exit 1; }
11+
npx jsr publish --allow-dirty || { echo "jsr publish failed" >&2; exit 1; }
1212
fi
1313
else
1414
echo "Skipping jsr."

0 commit comments

Comments
 (0)