From fa3b00480e84fb0461c97ae6653854addebe9b11 Mon Sep 17 00:00:00 2001 From: ZN-Ice Date: Thu, 4 Jun 2026 23:36:17 +0800 Subject: [PATCH] fix(ci): use ./ prefix for npm publish paths npm treats `packages/cli-box-darwin-arm64` as a git reference instead of a local directory path. Adding `./` prefix forces npm to resolve it as a relative path, fixing the "git ls-remote ssh://git@github.com/" error. Co-Authored-By: Claude Opus 4.7 --- .github/workflows/release.yml | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f93627e..65bdee1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -170,10 +170,6 @@ jobs: run: | echo "//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}" > ~/.npmrc - # Configure git to use HTTPS instead of SSH - git config --global url."https://github.com/".insteadOf "ssh://git@github.com/" - git config --global url."https://github.com/".insteadOf "git@github.com:" - # Set version from git tag VERSION="${GITHUB_REF_NAME#v}" @@ -200,6 +196,7 @@ jobs: " # Publish platform packages first, then main package - npm publish packages/cli-box-darwin-arm64 --access public --registry https://registry.npmjs.org - npm publish packages/cli-box-electron-darwin-arm64 --access public --registry https://registry.npmjs.org - npm publish packages/cli-box-skill --access public --registry https://registry.npmjs.org + # Note: must use ./ prefix to prevent npm from treating path as git reference + npm publish ./packages/cli-box-darwin-arm64 --access public + npm publish ./packages/cli-box-electron-darwin-arm64 --access public + npm publish ./packages/cli-box-skill --access public