sergiopolimante
New Contributor II

"This include array can appear only as a top-level mapping." - you can't use include inside targets. 

You can use sync - exclude to exclude the yml files, but if they are in the include the workflows are going to be created anyway, even if the yml files are not deployed to the environment.

I want to deploy all resources to dev and staging, but not some resources to prod. I couldn't find a way. 

If there was a way to use conditions in databricks.yml it would be easy to do it. But as this post explains, it is only possible to do it when initializing a template: https://community.databricks.com/t5/data-engineering/if-else-conditions-in-databricks-asset-bundles/...