feat: add include_external_repositories and exclude_prefixes attributes to copy_to_directory Also change the default behavior such that files from external repositories are not included unless the external repository is listed in include_external_repositories
This is code we would contribute to bazel-skylib, but the declared scope of that project is narrow and it‘s very difficult to get anyone’s attention to review PRs there.
From the release you wish to use: https://github.com/aspect-build/bazel-lib/releases copy the WORKSPACE snippet into your WORKSPACE file.