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

Add cli tool #2

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from
Draft

Add cli tool #2

wants to merge 4 commits into from

Conversation

alukach
Copy link
Member

@alukach alukach commented Feb 16, 2022

What I am changing

This adds an optional CLI util to populate SSM parameters from a .env file.

How I did it

  • Add executable script to ./
  • Add an extras_require to allow people to optionally install CLI requirements
  • Add an entry_point.console_scripts to install CLI. It should only install the script if the extra CLI flag is present (source), however this does not seem to work as advertised (I see it installed even if the [cli] extra flag is not provided)

How you can test it

git clone [email protected]:developmentseed/pydantic-ssm-settings.git
cd pydantic-ssm-settings
python3 -m venv .venv
source .venv/bin/activate
pip install -e ".[cli]"
dotenv-to-ssm

Bug: We should only be installing dotenv-to-ssm if the [cli] extra
arg is provided.  For whatever reason, it is always being installed.
https://setuptools.pypa.io/en/latest/userguide/entry_point.html#dependency-management
@alukach alukach requested a review from markdboyd February 16, 2022 20:46
@alukach alukach force-pushed the main branch 6 times, most recently from 31cf8f7 to 230aa1a Compare April 22, 2022 04:45
@alukach alukach force-pushed the main branch 3 times, most recently from 0fe90c6 to 2365def Compare June 21, 2022 00:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant