Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
eegli committed Jan 2, 2024
1 parent 8a4df3e commit a2ffe73
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
11 changes: 6 additions & 5 deletions packages/cli/src/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,16 @@ const subCommands = `Available subcommands: ${c.green(`
* auth
* library
* profiles
`)}`;
const optionalFlags = `Optional global flags:
`)}
Optional global flags:
${c.yellow('* --profile')} [string]
The profile in your Spotifly config file to use for authentication.
Defaults to 'default'.
In order to see a list of available profiles, run ${c.green(
- In order to get help for a specific subcommand, run ${c.green(
'spotifly <subcommand> --help',
)}
- In order to see a list of available profiles, run ${c.green(
'spotifly profiles',
)}`;

Expand All @@ -74,8 +77,6 @@ export default {
`- ${pkg.description}` +
lblb +
subCommands +
lb +
optionalFlags +
lblb +
helpFooter(pkg.homepage)
);
Expand Down
1 change: 1 addition & 0 deletions packages/cli/src/invoke.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ export const invokePackage = async (
if (!spotiflyConfig) return callback(argv);

const profile = profileFromArgv(argv);
console.info(`Using profile "${profile}"`);
try {
const credentials = credentialsFromConfig(spotiflyConfig, profile);
const { access_token } = await getAccessToken(credentials);
Expand Down

0 comments on commit a2ffe73

Please sign in to comment.