Skip to content

Commit

Permalink
Add epilogue to builders (#8285)
Browse files Browse the repository at this point in the history
  • Loading branch information
Josh-Walker-GM authored and jtoar committed May 11, 2023
1 parent d96ef0d commit b68101e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 19 deletions.
28 changes: 16 additions & 12 deletions packages/cli/src/commands/experimental/setupOpentelemetry.js
Original file line number Diff line number Diff line change
@@ -1,22 +1,26 @@
import { getEpilogue } from './util'

export const command = 'setup-opentelemetry'

export const description = 'Setup OpenTelemetry within the API side'

export const EXPERIMENTAL_TOPIC_ID = 4772

export const builder = (yargs) => {
yargs.option('force', {
alias: 'f',
default: false,
description: 'Overwrite existing configuration',
type: 'boolean',
})
yargs.option('verbose', {
alias: 'v',
default: false,
description: 'Print more logs',
type: 'boolean',
})
yargs
.option('force', {
alias: 'f',
default: false,
description: 'Overwrite existing configuration',
type: 'boolean',
})
.option('verbose', {
alias: 'v',
default: false,
description: 'Print more logs',
type: 'boolean',
})
.epilogue(getEpilogue(command, description, EXPERIMENTAL_TOPIC_ID, true))
}

export const handler = async (options) => {
Expand Down
9 changes: 2 additions & 7 deletions packages/cli/src/commands/experimental/studio.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import terminalLink from 'terminal-link'
import { getEpilogue } from './util'

export const command = 'studio'
export const description = 'Run the Redwood development studio'
Expand All @@ -11,12 +11,7 @@ export function builder(yargs) {
default: true,
description: 'Open the studio in your browser',
})
.epilogue(
`Also see the ${terminalLink(
'Redwood CLI Reference',
'https://redwoodjs.com/docs/cli-commands#studio'
)}`
)
.epilogue(getEpilogue(command, description, EXPERIMENTAL_TOPIC_ID, true))
}

export async function handler(options) {
Expand Down

0 comments on commit b68101e

Please sign in to comment.