From 84e069930156b1fabb2e2cd9261d58fcd6eff6b1 Mon Sep 17 00:00:00 2001 From: Nico Flaig Date: Tue, 3 Dec 2024 15:44:29 +0100 Subject: [PATCH] docs: display rcConfig flag on CLI reference page (#7270) * docs: display rcConfig flag on CLI reference page * Update word list --- .wordlist.txt | 2 ++ packages/cli/src/options/globalOptions.ts | 8 +++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.wordlist.txt b/.wordlist.txt index 2c28fc784061..5070aafcf9a5 100644 --- a/.wordlist.txt +++ b/.wordlist.txt @@ -110,6 +110,7 @@ Vitalik Vitest Wagyu api +args async backfill beaconcha @@ -244,3 +245,4 @@ xRelayPubKey xcode yaml yamux +yml diff --git a/packages/cli/src/options/globalOptions.ts b/packages/cli/src/options/globalOptions.ts index 58ae396b67d1..6a6998dc76cc 100644 --- a/packages/cli/src/options/globalOptions.ts +++ b/packages/cli/src/options/globalOptions.ts @@ -10,6 +10,7 @@ type GlobalSingleArgs = { paramsFile?: string; preset: string; presetFile?: string; + rcConfig?: string; }; export const defaultNetwork: NetworkName = "mainnet"; @@ -44,11 +45,16 @@ const globalSingleOptions: CliCommandOptions = { description: "Preset configuration file to override the active preset with custom values", type: "string", }, + + rcConfig: { + description: "RC file to supplement command line args, accepted formats: .yml, .yaml, .json", + type: "string", + }, }; export const rcConfigOption: [string, string, (configPath: string) => Record] = [ "rcConfig", - "RC file to supplement command line args, accepted formats: .yml, .yaml, .json", + globalSingleOptions.rcConfig.description as string, (configPath: string): Record => readFile(configPath, ["json", "yml", "yaml"]), ];