Skip to content

Commit

Permalink
refactor secret commands
Browse files Browse the repository at this point in the history
  • Loading branch information
RamIdeas committed Sep 10, 2024
1 parent 4085fab commit 9e0d39f
Show file tree
Hide file tree
Showing 3 changed files with 374 additions and 370 deletions.
1 change: 1 addition & 0 deletions packages/wrangler/src/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ import "./hyperdrive/commands";
import "./queues/cli/commands";
import "./r2/commands";
import "./d1/commands";
import "./secret";
17 changes: 1 addition & 16 deletions packages/wrangler/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ import { writeOutput } from "./output";
import { pages } from "./pages";
import { APIError, formatMessage, ParseError } from "./parse";
import { pubSubCommands } from "./pubsub/pubsub-commands";
import { secret, secretBulkHandler, secretBulkOptions } from "./secret";
import {
addBreadcrumb,
captureGlobalException,
Expand Down Expand Up @@ -493,13 +492,7 @@ export function createCLIParser(argv: string[]) {
);

// secret
wrangler.command(
"secret",
"🤫 Generate a secret that can be referenced in a Worker",
(secretYargs) => {
return secret(secretYargs.command(subHelp));
}
);
register.registerNamespace("secret");

// types
wrangler.command(
Expand Down Expand Up @@ -625,14 +618,6 @@ export function createCLIParser(argv: string[]) {
subdomainHandler
);

// [DEPRECATED] secret:bulk
wrangler.command(
"secret:bulk [json]",
false,
secretBulkOptions,
secretBulkHandler
);

// [DEPRECATED] generate
wrangler.command(
"generate [name] [template]",
Expand Down
Loading

0 comments on commit 9e0d39f

Please sign in to comment.