From 104c7babf8608c905718e0c6a31e2d6b1b144e70 Mon Sep 17 00:00:00 2001 From: CrazyMax Date: Wed, 1 Feb 2023 01:51:34 +0100 Subject: [PATCH] chore: use yarn to publish module Signed-off-by: CrazyMax --- .yarnrc.yml | 2 ++ dev.Dockerfile | 7 +------ 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/.yarnrc.yml b/.yarnrc.yml index a568a96..fc0ab7f 100644 --- a/.yarnrc.yml +++ b/.yarnrc.yml @@ -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" diff --git a/dev.Dockerfile b/dev.Dockerfile index 581bdf1..1644982 100644 --- a/dev.Dockerfile +++ b/dev.Dockerfile @@ -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