## Summary * As raised by @ericchansen in #34, `pydantic-argparse` should be able to piggy-back off `pydantic` and support loading environment variables from `.env` files. * This can probably be accomplished by defining arguments as shown below: ```python class Args(pydantic.BaseSettings): my_arg: int = pydantic.Field(description="this is an int") class Config: env_file = ".env" env_file_encoding = "utf-8" ``` * See: https://docs.pydantic.dev/latest/usage/settings/#dotenv-env-support * If this does work, it might be nice to provide a `dotenv` extra for `pydantic-argparse` (similar to `pydantic`) so people can install it with: ```shell $ pip install pydantic-argparse[dotenv] ```
Summary
pydantic-argparseshould be able to piggy-back offpydanticand support loading environment variables from.envfiles.dotenvextra forpydantic-argparse(similar topydantic) so people can install it with: