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

docs: display rcConfig flag on CLI reference page #7270

Merged
merged 2 commits into from
Dec 3, 2024
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
2 changes: 2 additions & 0 deletions .wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ Vitalik
Vitest
Wagyu
api
args
async
backfill
beaconcha
Expand Down Expand Up @@ -244,3 +245,4 @@ xRelayPubKey
xcode
yaml
yamux
yml
8 changes: 7 additions & 1 deletion packages/cli/src/options/globalOptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ type GlobalSingleArgs = {
paramsFile?: string;
preset: string;
presetFile?: string;
rcConfig?: string;
};

export const defaultNetwork: NetworkName = "mainnet";
Expand Down Expand Up @@ -44,11 +45,16 @@ const globalSingleOptions: CliCommandOptions<GlobalSingleArgs> = {
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<string, unknown>] = [
"rcConfig",
"RC file to supplement command line args, accepted formats: .yml, .yaml, .json",
globalSingleOptions.rcConfig.description as string,
(configPath: string): Record<string, unknown> => readFile(configPath, ["json", "yml", "yaml"]),
];

Expand Down
Loading