Skip to content

Latest commit

 

History

History
31 lines (20 loc) · 1.12 KB

fastbuild.md

File metadata and controls

31 lines (20 loc) · 1.12 KB

Fast Build

The IntelliJ plugin for Bazel includes the Fast Build feature, allowing you to run tests and executables without recompiling the entire target. This feature detects which Java files have changed and compiles only those files, significantly speeding up the development process.

Requirements

To enable Fast Build, you must add specific VM options to your IntelliJ configuration. The flags are required to run Java compilation inside the IntelliJ process, so that there's no need to spawn a separate javac process. Follow these steps:

  1. Navigate to Help -> Edit Custom VM Options.
  2. Add the following entries:
--add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED
--add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED
--add-exports=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED

rules_java

Please use rules_java 7.12.2 or newer

How to Use

To use Fast Build, locate your test or executable in the editor. Click the gutter icon and select either Fast Run or Fast Test.

Demo

fastbuild_demo.mov