Skip to main content
Version: 2.11.x (deprecated)

scalac


The Scala compiler.

Backend: pants.backend.experimental.scala

Config section: [scalac]

Basic options

args

--scalac-args="[<shell_str>, <shell_str>, ...]"
PANTS_SCALAC_ARGS
default: []

Arguments to pass directly to scalac, e.g. --scalac-args='-encoding UTF-8'.

plugins_for_resolve

--scalac-plugins-for-resolve="{'key1': val1, 'key2': val2, ...}"
PANTS_SCALAC_PLUGINS_FOR_RESOLVE
default: {}

A dictionary, whose keys are the names of each JVM resolve that requires default scalac plugins, and the value is a comma-separated string consisting of scalac plugin names. Each specified plugin must have a corresponding scalac_plugin target that specifies that name in either its plugin_name field or is the same as its target name.

Advanced options

None

Deprecated options

plugins_global

--scalac-plugins-global="['<str>', '<str>', ...]"
PANTS_SCALAC_PLUGINS_GLOBAL
default: []

A list of addresses of scalac_plugin targets which should be used for compilation of all Scala targets in a build.

If you set this, you must also set [scalac].plugins_global_lockfile.

plugins_global_lockfile

--scalac-plugins-global-lockfile=<str>
PANTS_SCALAC_PLUGINS_GLOBAL_LOCKFILE
default: <default>

The filename of the lockfile for global plugins. You must set this option to a file path, e.g. '3rdparty/jvm/global_scalac_plugins.lock', if you set [scalac].plugins_global.