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.
As per discussion in #144 would be nice to support
automatic_pack_namespace
.I tried to make a stab at this but think I've hit my limits for now.
The changes here seem to produce the correct output with
pks list-definitions
but the test I added that uses the resolver ie failing... not sure why.Also I don't know how best to implement the pack configuration parsing to actually parse out the configuration under a nested hash, ie
automatic_pack_namespace
is actually defined undermetadata
normally. At the moment I just added theautomatic_pack_namespace
boolean to the root of thepackage.yml
so I could continue.I also wasn't sure where to get the packs root path info from while determining the pack namespace name.
Finally I ran into an issue with wanting but go from a String value to a &String in a condition branch, but simply adding a & at the start of the expression resulted in errors about lifetimes of temporary values. So I added a
let
outside of the conditional but that just feels wrong!Anyway the diff attached includes TODOs describing the above!