"Prepare Plugin Module for Deployment" from a Gradle-based Plugin Project?

I have followed the below guide to create a plugin project using Gradle.

I know how to use :runIde to see my plugin in action, but I would like to be able to build it into a single jar file, the way you can do it when you make a DevKit based project using Build -> Prepare Plugin Module for Deployment. (pictured below)

Is there a way to do this from a Gradle-based plugin? If not, how can install my Gradle-based plugin on IntelliJ or Android Studio locally, without publishing it?

Thank you.