Skip to content

Commit

Permalink
chore: remove leftovers of netrc
Browse files Browse the repository at this point in the history
  • Loading branch information
alvarosabu committed Jan 14, 2025
1 parent 27f97da commit 561fd1d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/commands/user/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import chalk from 'chalk'
import type { NetrcMachine } from '../../creds'
import { colorPalette, commands } from '../../constants'
import { getProgram } from '../../program'
import { CommandError, handleError, konsola } from '../../utils'
Expand All @@ -21,7 +20,10 @@ export const userCommand = program
return
}
try {
const { password, region } = state as NetrcMachine
const { password, region } = state
if (!password || !region) {
throw new Error('No password or region found')
}
const { user } = await getUser(password, region)
konsola.ok(`Hi ${chalk.bold(user.friendly_name)}, you are currently logged in with ${chalk.hex(colorPalette.PRIMARY)(user.email)} on ${chalk.bold(region)} region`)
}
Expand Down

0 comments on commit 561fd1d

Please sign in to comment.