Closed phil-opp closed 4 years ago
@ascjones This changes the code that you introduced in #57. Could you test whether your use case still works with this PR?
Thanks for verifying that it still works! I didn't think of virtual manifests either, so no worries!
Still, this is much improved now with the warning, where previously it would have silently used the default config.
I fully agree!
Published as version 0.5.25
Since #57, we try to read the config from the root package of the workspace, instead of just defaulting to the first package. The problem with this is that the new code assumes that there is always a root package in the workspace, which is not true when only a virtual manifest is used at the root.
With this pull request we no longer error for such workspaces. Instead, we emit a warning that no cargo-xbuild configuration is applied and use the default config. This isn't optimal, but there is no canoncial place to read the config from and I can't think of a better approach.
To ensure that future config related errors are easier to debug, this pull request also prints the underlying cause for config load errors.
Fixes #60