Move the buildscript block into a plugin..?

When I was talking about configuration ‘:classpath’, I was talking about the classpath of the buildscript block. Basically I would be happy with one of two options:

  1. true (non hacky) verbatim includes of the buildscript block from buildscriptblock.gradle
  2. manipulation of the buildscript-block-classpath in my local plugin

At the moment there is no way to avoid duplication of the information included in the buildscript block.

There is this workaround: Reuse of buildscript block but my problem is, it only works for build.gradle and you cannot include the same file in another project that needs to use a settings.gradle and have the buildscript-block in settings.gradle since this hacky solution uses project.buildscript and project does not exist in settings.gradle.

I was hoping there would be a way to avoid buildscript-block duplication. It seems there isn’t.