The Return of the Scala Rule Tutorial: The Execution

This builds on the first part of the tutorial. In this post, we will make the the rule actually produce an executable. Capturing the output from scalac At the end of the tutorial last time, we were calling scalac, but ignoring the result: (cd /private/var/tmp/_bazel_kchodorow/92df5f72e3c78c053575a1a42537d8c3/blerg && exec env – /bin/bash -c ‘external/scala/bin/scalac HelloWorld.scala; echo ”’blah”’Continue reading “The Return of the Scala Rule Tutorial: The Execution”

Tutorial: how to write Scala rules for Bazel

Bazel comes with built-in support for several languages and allows you to write your own support for any other languages in Python. Although you could probably get more abstract, let’s define a rule as something that takes some files, does something to them, and then gives you some output files. Specifically, for this example, weContinue reading “Tutorial: how to write Scala rules for Bazel”