Skip to content

Commit

Permalink
Fix 2fa check (#128)
Browse files Browse the repository at this point in the history
* Fix 2fa check

* Add a ci check too
  • Loading branch information
emmatown authored and Noviny committed Jul 18, 2019
1 parent 6d11989 commit 5b28c52
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions .changeset/happy-llamas-speak/changes.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"releases": [{ "name": "@changesets/cli", "type": "patch" }],
"dependents": []
}
1 change: 1 addition & 0 deletions .changeset/happy-llamas-speak/changes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix 2FA check on release
2 changes: 1 addition & 1 deletion packages/cli/src/commands/release/npm-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ async function internalPublish(
twoFactorState: TwoFactorState
): Promise<{ published: boolean }> {
let publishFlags = opts.access ? ["--access", opts.access] : [];
if (twoFactorState.isRequired) {
if ((await twoFactorState.isRequired) && !isCI) {
let otpCode = await getOtpCode(twoFactorState);
publishFlags.push("--otp", otpCode);
}
Expand Down

0 comments on commit 5b28c52

Please sign in to comment.