chore: use yarn to publish module

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
CrazyMax 2023-02-01 01:51:34 +01:00
parent e218647127
commit 104c7babf8
No known key found for this signature in database
GPG Key ID: 3248E46B6BB8C7F7
2 changed files with 3 additions and 6 deletions

View File

@ -1,5 +1,7 @@
nodeLinker: node-modules
npmAuthToken: "${NODE_AUTH_TOKEN:-fallback}"
plugins:
- path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
spec: "@yarnpkg/plugin-interactive-tools"

View File

@ -83,10 +83,5 @@ RUN --mount=type=bind,target=.,rw \
fi
yarn install
yarn run build
npm config set //registry.npmjs.org/:_authToken $(cat /run/secrets/NODE_AUTH_TOKEN)
npm version --no-git-tag-version ${GITHUB_REF#refs/tags/v}
npm publish --access public
# FIXME: Can't publish with yarn berry atm: https://github.com/changesets/changesets/pull/674
#NODE_AUTH_TOKEN=$(cat /run/secrets/NODE_AUTH_TOKEN) yarn publish --no-git-tag-version --new-version ${GITHUB_REF#refs/tags/v}
NODE_AUTH_TOKEN=$(cat /run/secrets/NODE_AUTH_TOKEN) yarn npm publish --access public --tag ${GITHUB_REF#refs/tags/v}
EOT