Skip to content

Commit

Permalink
Fix formatting of array default values
Browse files Browse the repository at this point in the history
  • Loading branch information
nflaig committed Feb 13, 2024
1 parent 1528f93 commit f275565
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion packages/cli/src/cmds/bootnode/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ export const bootnodeExtraOptions: CliCommandOptions<BootnodeExtraArgs> = {
bootnodes: {
type: "array",
description: "Additional bootnodes for discv5 discovery",
defaultDescription: JSON.stringify([]),
// Each bootnode entry could be comma separated, just deserialize it into a single array
// as comma separated entries are generally most friendly in ansible kind of setups, i.e.
// [ "en1", "en2,en3" ] => [ 'en1', 'en2', 'en3' ]
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/src/options/beaconNodeOptions/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export const options: CliCommandOptions<ApiArgs> = {
type: "array",
choices: [...allNamespaces, enabledAll],
description: `Pick namespaces to expose for HTTP API. Set to '${enabledAll}' to enable all namespaces`,
defaultDescription: JSON.stringify(defaultOptions.api.rest.api),
defaultDescription: defaultOptions.api.rest.api.join(","),
group: "api",
coerce: (namespaces: string[]): string[] => {
// Enable all
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/src/options/beaconNodeOptions/network.ts
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ export const options: CliCommandOptions<NetworkArgs> = {
bootnodes: {
type: "array",
description: "Bootnodes for discv5 discovery",
defaultDescription: JSON.stringify((defaultOptions.network.discv5 || {}).bootEnrs || []),
defaultDescription: ((defaultOptions.network.discv5 || {}).bootEnrs || []).join(","),
group: "network",
// Each bootnode entry could be comma separated, just deserialize it into a single array
// as comma separated entries are generally most friendly in ansible kind of setups, i.e.
Expand Down

0 comments on commit f275565

Please sign in to comment.