Skip to content
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
33 changes: 33 additions & 0 deletions airflow/cli/cli_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -857,6 +857,27 @@ def string_lower_type(val):
("option",),
help="The option name",
)

ARG_LINT_CONFIG_SECTION = Arg(
("--section",),
help="The section name(s) to lint in the airflow config.",
type=string_list_type,
)
ARG_LINT_CONFIG_OPTION = Arg(
("--option",),
help="The option name(s) to lint in the airflow config.",
type=string_list_type,
)
ARG_LINT_CONFIG_IGNORE_SECTION = Arg(
("--ignore-section",),
help="The section name(s) to ignore to lint in the airflow config.",
type=string_list_type,
)
ARG_LINT_CONFIG_IGNORE_OPTION = Arg(
("--ignore-option",),
help="The option name(s) to ignore to lint in the airflow config.",
type=string_list_type,
)
ARG_OPTIONAL_SECTION = Arg(
("--section",),
help="The section name",
Expand Down Expand Up @@ -1733,6 +1754,18 @@ class GroupCommand(NamedTuple):
ARG_VERBOSE,
),
),
ActionCommand(
name="lint",
help="lint options for the configuration changes while migrating from Airflow 2.x to Airflow 3.0",
func=lazy_load_command("airflow.cli.commands.remote_commands.config_command.lint_config"),
args=(
ARG_LINT_CONFIG_SECTION,
ARG_LINT_CONFIG_OPTION,
ARG_LINT_CONFIG_IGNORE_SECTION,
ARG_LINT_CONFIG_IGNORE_OPTION,
ARG_VERBOSE,
),
),
)

JOBS_COMMANDS = (
Expand Down
Loading