Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: move CLI exp setup to exp setup-opentelemetry #8256

Merged
merged 6 commits into from
May 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 3 additions & 8 deletions docs/docs/cli-commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ You can pass any flags to the command and use them within your script:

See [this how to](how-to/background-worker.md) for an example of using exec to run a background worker.

## experimental
## experimental (alias exp)

Set up and run experimental features.

Expand All @@ -414,11 +414,6 @@ For more information, including details about specific features, see this Redwoo
**Available Experimental Features**
View all that can be _set up_:
```
yarn redwood experimental setup --help
```

View all that can be _run_:
```
yarn redwood experimental --help
```

Expand Down Expand Up @@ -1462,7 +1457,7 @@ yarn redwood lint

## prisma

Run Prisma CLI with experimental features.
Run Prisma CLI within the context of a Redwood project.

```
yarn redwood prisma
Expand All @@ -1474,7 +1469,7 @@ Redwood's `prisma` command is a lightweight wrapper around the Prisma CLI. It's
>
> By lightweight wrapper, we mean that we're handling some flags under the hood for you.
> You can use the Prisma CLI directly (`yarn prisma`), but letting Redwood act as a proxy (`yarn redwood prisma`) saves you a lot of keystrokes.
> For example, Redwood adds the `--preview-feature` and `--schema=api/db/schema.prisma` flags automatically.
> For example, Redwood adds the `--schema=api/db/schema.prisma` flags automatically.
>
> If you want to know exactly what `yarn redwood prisma <command>` runs, which flags it's passing, etc., it's right at the top:
>
Expand Down
28 changes: 0 additions & 28 deletions packages/cli/src/commands/experimental/setup.js

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
export const command = 'opentelemetry'
export const command = 'setup-opentelemetry'

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

export const builder = (yargs) => {
yargs.option('force', {
Expand All @@ -18,6 +18,6 @@ export const builder = (yargs) => {
}

export const handler = async (options) => {
const { handler } = await import('./opentelemetryHandler')
const { handler } = await import('./setupOpentelemetryHandler')
return handler(options)
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ import { addApiPackages } from '@redwoodjs/cli-helpers'
import { getConfigPath } from '@redwoodjs/project-config'
import { errorTelemetry } from '@redwoodjs/telemetry'

import { getPaths, transformTSToJS, writeFile } from '../../../../lib'
import c from '../../../../lib/colors'
import { isTypeScriptProject } from '../../../../lib/project'
import { getPaths, transformTSToJS, writeFile } from '../../lib'
import c from '../../lib/colors'
import { isTypeScriptProject } from '../../lib/project'

export const handler = async ({ force, verbose }) => {
const ts = isTypeScriptProject()
Expand Down