From f38c5d1a28ecadb51596de2b5c65f3247e382a91 Mon Sep 17 00:00:00 2001 From: Gianluca Frediani Date: Tue, 8 Aug 2023 17:10:10 +0200 Subject: [PATCH] fix: fixed imports for getAccount and getProfileAccount --- packages/zcli-core/src/index.ts | 1 + packages/zcli/src/commands/login.ts | 3 +-- packages/zcli/src/commands/profiles/list.ts | 3 +-- packages/zcli/src/commands/profiles/use.ts | 3 +-- 4 files changed, 4 insertions(+), 6 deletions(-) diff --git a/packages/zcli-core/src/index.ts b/packages/zcli-core/src/index.ts index f5bbc981..046fc8d2 100644 --- a/packages/zcli-core/src/index.ts +++ b/packages/zcli-core/src/index.ts @@ -1,4 +1,5 @@ export { default as Auth } from './lib/auth' +export { getAccount, getProfileFromAccount } from './lib/authUtils' export { default as Config } from './lib/config' export { default as SecureStore } from './lib/secureStore' export { getBaseUrl } from './lib/requestUtils' diff --git a/packages/zcli/src/commands/login.ts b/packages/zcli/src/commands/login.ts index fdfee892..ed47bddb 100644 --- a/packages/zcli/src/commands/login.ts +++ b/packages/zcli/src/commands/login.ts @@ -1,8 +1,7 @@ import { Command, Flags } from '@oclif/core' import * as chalk from 'chalk' -import { SecureStore, Auth } from '@zendesk/zcli-core' +import { SecureStore, Auth, getAccount } from '@zendesk/zcli-core' import { HELP_ENV_VARS } from '../utils/helpMessage' -import { getAccount } from '@zendesk/zcli-core/src/lib/authUtils' export default class Login extends Command { static description = 'creates and/or saves an authentication token for the specified subdomain' diff --git a/packages/zcli/src/commands/profiles/list.ts b/packages/zcli/src/commands/profiles/list.ts index 81de504d..183e0ee3 100644 --- a/packages/zcli/src/commands/profiles/list.ts +++ b/packages/zcli/src/commands/profiles/list.ts @@ -1,9 +1,8 @@ import { Command, CliUx } from '@oclif/core' import * as chalk from 'chalk' -import { Auth, SecureStore } from '@zendesk/zcli-core' +import { Auth, SecureStore, getAccount } from '@zendesk/zcli-core' import { Credential, Profile } from '@zendesk/zcli-core/src/types' import { HELP_ENV_VARS } from '../../utils/helpMessage' -import { getAccount } from '@zendesk/zcli-core/src/lib/authUtils' export default class List extends Command { static description = 'lists all the profiles' diff --git a/packages/zcli/src/commands/profiles/use.ts b/packages/zcli/src/commands/profiles/use.ts index 45f304f5..1fb294aa 100644 --- a/packages/zcli/src/commands/profiles/use.ts +++ b/packages/zcli/src/commands/profiles/use.ts @@ -1,8 +1,7 @@ import { Command } from '@oclif/core' import * as chalk from 'chalk' -import { SecureStore, Auth } from '@zendesk/zcli-core' +import { SecureStore, Auth, getProfileFromAccount } from '@zendesk/zcli-core' import { HELP_ENV_VARS } from '../../utils/helpMessage' -import { getProfileFromAccount } from '@zendesk/zcli-core/src/lib/authUtils' export default class Remove extends Command { static description = 'switches to a profile'