Wrap the project in a Python package with a CLI command #9
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This makes Stacks installable with pip! Now you won't have to copy the source files into your Terraform repository, and instead of having to remember the correct number of
../../../
to use, you can just runstacks preinit
andstacks postinit
.The
preinit.py
andpostinit.py
files still support being run manually, for backwards compatibility. Currently the package isn't listed on PyPi, but that can be added in the future if desired. For now, you can install manually from GitHub, using the instructions in README.md.NOTE: The diff displayed in the PR makes it look like I deleted/rewrote
preinit.py
andpostinit.py
. For a better diff, see the changes between these two commits. I just added a bit of code to enable these files to work both as scripts and as dependencies tocli.py
.Type of Change
Checklist
All code style checks passNew code contribution is covered by automated testsAll new and existing tests pass