Skip to content

Commit 4ea3106

Browse files
josephperrottalan-agius4
authored andcommitted
refactor(ng-dev): properly check if wombot proxy is logged in when checking npm login state
Wombot proxy now supports whoami lookups, so we can now actually check if our token is valid instead of always assuming its not.
1 parent a8b9cca commit 4ea3106

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

ng-dev/release/publish/index.ts

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -205,17 +205,6 @@ export class ReleaseTool {
205205
*/
206206
private async _verifyNpmLoginState(): Promise<boolean> {
207207
const registry = `NPM at the ${this._config.publishRegistry ?? 'default NPM'} registry`;
208-
// TODO(josephperrott): remove wombat specific block once wombot allows `npm whoami` check to
209-
// check the status of the local token in the .npmrc file.
210-
if (this._config.publishRegistry?.includes('wombat-dressing-room.appspot.com')) {
211-
Log.info('Unable to determine NPM login state for wombat proxy, requiring login now.');
212-
try {
213-
await NpmCommand.startInteractiveLogin(this._config.publishRegistry);
214-
} catch {
215-
return false;
216-
}
217-
return true;
218-
}
219208
if (await NpmCommand.checkIsLoggedIn(this._config.publishRegistry)) {
220209
Log.debug(`Already logged into ${registry}.`);
221210
return true;

0 commit comments

Comments
 (0)