Skip to content

Commit 7ba5776

Browse files
committed
feat: Allow to use env variable FEATURE_STORE_YAML_PATH and FEATURE_REPO_DIR
Signed-off-by: ntkathole <nikhilkathole2683@gmail.com>
1 parent 9ba9ded commit 7ba5776

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

sdk/python/feast/cli/cli.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@
4747
from feast.cli.stream_feature_views import stream_feature_views_cmd
4848
from feast.cli.ui import ui
4949
from feast.cli.validation_references import validation_references_cmd
50+
from feast.constants import FEAST_FS_YAML_FILE_PATH_ENV_NAME
5051
from feast.errors import FeastProviderLoginError
5152
from feast.repo_config import load_repo_config
5253
from feast.repo_operations import (
@@ -81,7 +82,8 @@ def format_options(self, ctx: click.Context, formatter: click.HelpFormatter):
8182
@click.option(
8283
"--chdir",
8384
"-c",
84-
help="Switch to a different feature repository directory before executing the given subcommand.",
85+
envvar="FEATURE_REPO_DIR",
86+
help="Switch to a different feature repository directory before executing the given subcommand. Can also be set via the FEATURE_REPO_DIR environment variable.",
8587
)
8688
@click.option(
8789
"--log-level",
@@ -91,7 +93,8 @@ def format_options(self, ctx: click.Context, formatter: click.HelpFormatter):
9193
@click.option(
9294
"--feature-store-yaml",
9395
"-f",
94-
help="Override the directory where the CLI should look for the feature_store.yaml file.",
96+
envvar=FEAST_FS_YAML_FILE_PATH_ENV_NAME,
97+
help=f"Override the directory where the CLI should look for the feature_store.yaml file. Can also be set via the {FEAST_FS_YAML_FILE_PATH_ENV_NAME} environment variable.",
9598
)
9699
@click.pass_context
97100
def cli(

0 commit comments

Comments
 (0)