Open
Conversation
Kami
reviewed
Sep 23, 2019
Kami
reviewed
Sep 23, 2019
Kami
reviewed
Sep 23, 2019
Contributor
|
I'm fine with that change. Definitely much better than convoluted Makefile. As mentioned in my other PR, it perhaps wouldn't be a bad idea to document some of that behavior, etc. since in theory, users could also use this Makefile for CI for their custom packs. |
30 tasks
Contributor
|
I'm good with this too! Much easier to debug than Make. +1 |
nmaludy
suggested changes
May 19, 2020
Contributor
nmaludy
left a comment
There was a problem hiding this comment.
Need to fix merge conflicts, otherwise this looks great!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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 PR converts almost all of the targets in the
Makefileinto Invoke tasks. TheMakefileis kept and vastly simplified into just setting up the environment for invoke, then passing all targets to it. Invoke handles everything else.This PR isn't strictly 100% necessary, but since the
Makefilewas fairly simple and straightforward it was a good target to illustrate how aMakefilecan be broken up into multiple different modules and run with Invoke with full reverse compatibility for any scripts that still callmake. Some of the scripts in this repo do call make with thisMakefile, and those were intentionally left alone as a sentinel for reverse compatibility. This PR is a good baby step towards replacing the (very complex/convoluted)Makefilein st2, since thisMakefilewas 100% composed of targets marked with.PHONY, so it was just a centralized way to run scripts and didn't actually build anything or cache any build artifacts, which is the entire purpose of make to begin with.I also simplified some of the behavior in
.circle/dependencies, for the sake of sanity:requirementsandrequirements-citargets both had the exact same recipe (verified with diff), so I also changed the call tomake requirements-cito justmake requirements.Makefile:.install-runners(dotted) target, so I replaced them to just call theinstall-runners(non-dotted) target.I explicitly relatively import the task modules since implicit relative imports have been phased out in Python 3. Do note that in
tasks/utils.py, there is still animport git- this is not an implicit relative import of a tasks module, it is an absolute import for the GitPython module in the virtualenv.Tested with the AWS pack:
Please review this thoroughly, since this is used for all pack CI runs, including the 130+ runs over the weekend.