Skip to content

Commit

Permalink
Show kv help when run without params
Browse files Browse the repository at this point in the history
  • Loading branch information
lrapoport-cf committed Oct 9, 2024
1 parent 2e64968 commit d7fff8c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/wrangler/src/kv/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ export function registerKvSubcommands(
subHelp: SubHelp
) {
return kvYargs
.command(subHelp)
.command(
"namespace",
`Interact with your Workers KV Namespaces`,
Expand All @@ -63,6 +64,7 @@ export function registerKvSubcommands(

export function kvNamespace(kvYargs: CommonYargsArgv) {
return kvYargs
.demandCommand()
.command(
"create <namespace>",
"Create a new namespace",
Expand Down Expand Up @@ -201,6 +203,7 @@ export function kvNamespace(kvYargs: CommonYargsArgv) {

export const kvKey = (kvYargs: CommonYargsArgv) => {
return kvYargs
.demandCommand()
.command(
"put <key> [value]",
"Write a single key/value pair to the given namespace",
Expand Down Expand Up @@ -542,6 +545,7 @@ export const kvKey = (kvYargs: CommonYargsArgv) => {

export const kvBulk = (kvYargs: CommonYargsArgv) => {
return kvYargs
.demandCommand()
.command(
"put <filename>",
"Upload multiple key-value pairs to a namespace",
Expand Down

0 comments on commit d7fff8c

Please sign in to comment.