Bld

5 Topics 32 Posts
  • Extensions

    Pinned
    2 Votes
    14 Posts
    388 Views

    If you're using bld with Spring Boot you might like the following:

    bld Spring Boot Extension Spring Boot Example Project for bld
  • bld advocacy ideas

    Pinned
    2 Votes
    14 Posts
    245 Views

    @ethauvin that was one of my takeaways from that Reddit thread a while ago. Many people seem to just look at the code verbatim and do a direct comparison, not taking into account what the implications are and how it actually can be used. It's a really tough nut to crack when trying to show of what's possible with bld imho.

  • bld Tips & Tricks

    1 Votes
    2 Posts
    89 Views

    Annotation processors are easy to use with bld. Generally, you'll just need to include processor as a dependency, for example:

    public class ExampleBuild extends Project { public ExampleBuild() { // ... scope(compile) .include(dependency("com.example", "annotator", version(1, 0, 0))); } }

    If the processor is generating source files, you can easily specify where they should be saved, using the -s javac option, for example:

    /** * Saves generated source files in the {@code build/generated} directory. */ @Override public void compile() throws Exception { var generated = new File(buildDirectory(), "generated"); var ignore = generated.mkdir(); compileOperation().compileOptions().addAll(List.of("-s", generated.getAbsolutePath())); super.compile(); }

    To incorporate the generated source code into the source tree, add this directory as an additional source location in your IDE.

    Screenshot from 2023-08-20 21-27-10.png

  • bld v1.7.2 released!

    1 Votes
    1 Posts
    45 Views
    No one has replied
  • bld v1.7.1 released!

    1 Votes
    1 Posts
    43 Views
    No one has replied