trait AndroidAppKotlinModule extends BaseClass with AndroidAppModule with KotlinModule
Trait for building Android applications using the Mill build tool.
This trait defines all the necessary steps for building an Android app from Kotlin sources, integrating both Android-specific tasks and generic Kotlin tasks by extending the KotlinModule (for standard Kotlin tasks) and AndroidAppModule (for Android Application Workflow Process).
It provides a structured way to handle various steps in the Android app build process, including compiling Kotlin sources, creating DEX files, generating resources, packaging APKs, optimizing, and signing APKs.
- Annotations
- @experimental()
- Source
- AndroidAppKotlinModule.scala
- Alphabetic
- By Inheritance
- AndroidAppKotlinModule
- KotlinModule
- AndroidAppModule
- JavaModule
- SemanticDbJavaModule
- OfflineSupportModule
- CoursierModule
- GenIdeaModule
- RunModule
- TaskModule
- JavaModuleBase
- BspModule
- WithZincWorker
- Module
- BaseClass
- Cacher
- Cacher
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Type Members
- trait KotlinTests extends BaseClass with JavaTests with KotlinModule
A test sub-module linked to its parent module best suited for unit-tests.
A test sub-module linked to its parent module best suited for unit-tests.
- Definition Classes
- KotlinModule
- type CompileProblemReporter = api.CompileProblemReporter
- Definition Classes
- KotlinModule
- type JavaTests = JavaModuleTests
- Definition Classes
- JavaModule
- Annotations
- @nowarn()
Deprecated Type Members
- trait JavaModuleTests extends BaseClass with JavaModule with TestModule
- Definition Classes
- JavaModule
- Annotations
- @deprecated
- Deprecated
(Since version Mill 0.11.10) Use JavaTests instead
Abstract Value Members
- abstract def androidSdkModule: ModuleRef[AndroidSdkModule]
Abstract method to provide access to the Android SDK configuration.
Abstract method to provide access to the Android SDK configuration.
This method must be implemented by the concrete class to specify the SDK paths.
- returns
The Android SDK module that is used across the project.
- Definition Classes
- AndroidAppModule
- abstract def kotlinVersion: T[String]
The Kotlin version to be used (for API and Language level settings).
The Kotlin version to be used (for API and Language level settings).
- Definition Classes
- KotlinModule
Concrete Value Members
- object millInternal extends Internal
Miscellaneous machinery around traversing & querying the build hierarchy, that should not be needed by normal users of Mill
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def allIvyDeps: T[Agg[scalalib.Dep]]
Aggregation of mandatoryIvyDeps and ivyDeps.
Aggregation of mandatoryIvyDeps and ivyDeps. In most cases, instead of overriding this Target you want to override
ivyDeps
instead.- Definition Classes
- JavaModule
- def allJavaSourceFiles: T[Seq[api.PathRef]]
All individual Java source files fed into the compiler.
All individual Java source files fed into the compiler. Subset of allSourceFiles.
- Definition Classes
- KotlinModule
- def allKotlinSourceFiles: T[Seq[api.PathRef]]
All individual Kotlin source files fed into the compiler.
All individual Kotlin source files fed into the compiler. Subset of allSourceFiles.
- Definition Classes
- KotlinModule
- def allLocalMainClasses: T[Seq[String]]
- Definition Classes
- RunModule
- def allSourceFiles: T[Seq[api.PathRef]]
All individual source files fed into the compiler.
All individual source files fed into the compiler.
- Definition Classes
- KotlinModule → JavaModule → SemanticDbJavaModule
- def allSources: T[Seq[api.PathRef]]
The folders containing all source files fed into the compiler
The folders containing all source files fed into the compiler
- Definition Classes
- JavaModule
- def androidAlignedUnsignedApk: T[api.PathRef]
Optimizes the APK using the
zipalign
tool for better performance.Optimizes the APK using the
zipalign
tool for better performance.For more details on the zipalign tool, refer to: zipalign Documentation
- Definition Classes
- AndroidAppModule
- def androidApk: T[api.PathRef]
Signs the APK using a keystore to generate a final, distributable APK.
Signs the APK using a keystore to generate a final, distributable APK.
The signing step is mandatory to distribute Android applications. It adds a cryptographic signature to the APK, verifying its authenticity. This method uses the
apksigner
tool along with a keystore file to sign the APK.If no keystore is available, a new one is generated using the
keytool
utility.For more details on the apksigner tool, refer to: apksigner Documentation
- Definition Classes
- AndroidAppModule
- def androidDex: T[api.PathRef]
Converts the generated JAR file into a DEX file using the
d8
tool.Converts the generated JAR file into a DEX file using the
d8
tool.- Definition Classes
- AndroidAppModule
- def androidJar: T[api.PathRef]
Packages the compiled Java
.class
files into a JAR file using the D8 tool.Packages the compiled Java
.class
files into a JAR file using the D8 tool.The D8 compiler is used here to package and optimize the Java bytecode into a format suitable for Android (DEX). D8 converts the Java
.class
files into a jar file which is suitable for DEX (Dalvik Executable) format and is required for Android runtime.For more details on the d8 tool, refer to: d8 Documentation
- Definition Classes
- AndroidAppModule
- def androidKeystore: T[api.PathRef]
Generates a new keystore file if it does not exist.
Generates a new keystore file if it does not exist.
A keystore is required to sign the APK for distribution. This method checks if a keystore exists, and if not, generates a new one using the
keytool
utility. The keystore holds the cryptographic keys used to sign the APK.For more details on the keytool utility, refer to: keytool Documentation
- Definition Classes
- AndroidAppModule
- def androidManifest: Task[api.PathRef]
An XML file containing configuration and metadata about your android application
An XML file containing configuration and metadata about your android application
- Definition Classes
- AndroidAppModule
- def androidResources: T[api.PathRef]
Generates the Android resources (such as layouts, strings, and other assets) needed for the application.
Generates the Android resources (such as layouts, strings, and other assets) needed for the application.
This method uses the Android
aapt
tool to compile resources specified in the project'sAndroidManifest.xml
and any additional resource directories. It creates the necessary R.java files and other compiled resources for Android. These generated resources are crucial for the app to function correctly on Android devices.For more details on the aapt tool, refer to: aapt Documentation
- Definition Classes
- AndroidAppModule
- def androidUnsignedApk: T[api.PathRef]
Packages the DEX files and Android resources into an unsigned APK using the
aapt
tool.Packages the DEX files and Android resources into an unsigned APK using the
aapt
tool.The
aapt
tool takes the DEX files (compiled code) and resources (such as layouts and assets), and packages them into an APK (Android Package) file. This APK file is unsigned and requires further processing to be distributed.- Definition Classes
- AndroidAppModule
- def artifactId: T[String]
The exact id of the artifact to be published.
The exact id of the artifact to be published. You probably don't want to override this. If you want to customize the name of the artifact, override artifactName instead. If you want to customize the scala version in the artifact id, see ScalaModule.artifactScalaVersion
- Definition Classes
- JavaModule
- def artifactName: T[String]
Override this to change the published artifact id.
Override this to change the published artifact id. For example, by default a scala module foo.baz might be published as foo-baz_2.12 and a java module would be foo-baz. Setting this to baz would result in a scala artifact baz_2.12 or a java artifact baz.
- Definition Classes
- JavaModule
- def artifactNameParts: T[Seq[String]]
- Definition Classes
- JavaModule
- def artifactSuffix: T[String]
The suffix appended to the artifact IDs during publishing
The suffix appended to the artifact IDs during publishing
- Definition Classes
- JavaModule
- def artifactTypes: T[Set[Type]]
Default artifact types to fetch and put in the classpath.
Default artifact types to fetch and put in the classpath. Add extra types here if you'd like fancy artifact extensions to be fetched.
- Definition Classes
- JavaModule
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def assembly: T[api.PathRef]
An executable uber-jar/assembly containing all the resources and compiled classfiles from this module and all it's upstream modules and dependencies
An executable uber-jar/assembly containing all the resources and compiled classfiles from this module and all it's upstream modules and dependencies
- Definition Classes
- JavaModule
- def assemblyRules: Seq[Rule]
Configuration for the assembly task: how files and file-conflicts are managed when combining multiple jar files into one big assembly jar.
Configuration for the assembly task: how files and file-conflicts are managed when combining multiple jar files into one big assembly jar.
- Definition Classes
- JavaModule
- def bindDependency: define.Task[(scalalib.Dep) => BoundDep]
Bind a dependency (Dep) to the actual module contetxt (e.g.
Bind a dependency (Dep) to the actual module contetxt (e.g. the scala version and the platform suffix)
- returns
The BoundDep
- Definition Classes
- CoursierModule
- def bspBuildTarget: BspBuildTarget
Use to fill most fields of
BuildTarget
.Use to fill most fields of
BuildTarget
.- Definition Classes
- KotlinModule → JavaModule → SemanticDbJavaModule → BspModule
- Annotations
- @internal()
- def bspBuildTargetData: define.Task[Option[(String, AnyRef)]]
Use to populate the
BuildTarget.{dataKind,data}
fields.Use to populate the
BuildTarget.{dataKind,data}
fields.Mill specific implementations: - JvmBuildTarget - ScalaBuildTarget
- Definition Classes
- JavaModule → BspModule
- Annotations
- @internal()
- def bspCompileClassesPath: T[UnresolvedPath]
The path to the compiled classes by compile without forcing to actually run the compilation.
The path to the compiled classes by compile without forcing to actually run the compilation. This is safe in an BSP context, as the compilation done later will use the exact same compilation settings, so we can safely use the same path.
Keep in sync with compile
- Definition Classes
- JavaModule
- Annotations
- @internal()
- def bspCompileClasspath: T[Agg[UnresolvedPath]]
Same as compileClasspath, but does not trigger compilation targets, if possible.
Same as compileClasspath, but does not trigger compilation targets, if possible.
Keep in sync with compileClasspath
- Definition Classes
- JavaModule
- Annotations
- @internal()
- def bspCompiledClassesAndSemanticDbFiles: T[UnresolvedPath]
- Definition Classes
- SemanticDbJavaModule
- def bspDisplayName: String
- Definition Classes
- BspModule
- def bspDisplayName0: String
- Definition Classes
- BspModule
- def bspJvmBuildTarget: JvmBuildTarget
- Definition Classes
- JavaModule
- Annotations
- @internal()
- def bspLocalClasspath: T[Agg[UnresolvedPath]]
Same as localClasspath, but with all dependencies on compile replaced by their non-compiling bspCompileClassesPath variants.
Same as localClasspath, but with all dependencies on compile replaced by their non-compiling bspCompileClassesPath variants.
Keep in sync with localClasspath
- Definition Classes
- JavaModule
- Annotations
- @internal()
- def bspLocalRunClasspath: T[Agg[UnresolvedPath]]
Same as localRunClasspath but for use in BSP server.
Same as localRunClasspath but for use in BSP server.
Keep in sync with localRunClasspath
- Definition Classes
- JavaModule
- def bspTransitiveCompileClasspath: T[Agg[UnresolvedPath]]
Same as transitiveCompileClasspath, but with all dependencies on compile replaced by their non-compiling bspCompileClassesPath variants.
Same as transitiveCompileClasspath, but with all dependencies on compile replaced by their non-compiling bspCompileClassesPath variants.
Keep in sync with transitiveCompileClasspath
- Definition Classes
- JavaModule
- Annotations
- @internal()
- def bspTransitiveLocalClasspath: T[Agg[UnresolvedPath]]
Same as transitiveLocalClasspath, but with all dependencies on compile replaced by their non-compiling bspCompileClassesPath variants.
Same as transitiveLocalClasspath, but with all dependencies on compile replaced by their non-compiling bspCompileClassesPath variants.
Keep in sync with transitiveLocalClasspath
- Definition Classes
- JavaModule
- Annotations
- @internal()
- def cachedTarget[T](t: => T)(implicit c: Enclosing): T
- Attributes
- protected[this]
- Definition Classes
- Cacher → Cacher
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @HotSpotIntrinsicCandidate() @native()
- def compile: T[CompilationResult]
Compiles all the sources to JVM class files.
Compiles all the sources to JVM class files.
- Definition Classes
- KotlinModule → JavaModule → SemanticDbJavaModule
- def compileClasspath: T[Agg[api.PathRef]]
All classfiles and resources from upstream modules and dependencies necessary to compile this module.
All classfiles and resources from upstream modules and dependencies necessary to compile this module.
Keep in sync with bspCompileClasspath
- Definition Classes
- JavaModule → SemanticDbJavaModule
- def compileIvyDeps: T[Agg[scalalib.Dep]]
Same as
ivyDeps
, but only present at compile time.Same as
ivyDeps
, but only present at compile time. Useful for e.g. macro-related dependencies likescala-reflect
that doesn't need to be present at runtime- Definition Classes
- JavaModule
- def compileModuleDeps: Seq[JavaModule]
The compile-only direct dependencies of this module.
The compile-only direct dependencies of this module. These are *not* transitive, and only take effect in the module that they are declared in.
- Definition Classes
- JavaModule
- final def compileModuleDepsChecked: Seq[JavaModule]
Same as compileModuleDeps but checked to not contain cycles.
Same as compileModuleDeps but checked to not contain cycles.
- Definition Classes
- JavaModule
- def compileResources: T[Seq[api.PathRef]]
The folders where the compile time resource files for this module live.
The folders where the compile time resource files for this module live. If your resources files do not necessarily need to be seen by the compiler, you should use resources instead.
- Definition Classes
- JavaModule
- def compiledClassesAndSemanticDbFiles: T[api.PathRef]
- Definition Classes
- SemanticDbJavaModule
- def coursierCacheCustomizer: define.Task[Option[(FileCache[coursier.util.Task]) => FileCache[coursier.util.Task]]]
Customize the coursier file cache.
Customize the coursier file cache.
This is rarely needed to be changed, but sometimes e.g you want to load a coursier plugin. Doing so requires adding to coursier's classpath. To do this you could use the following:
override def coursierCacheCustomizer = Task.Anon { Some( (fc: coursier.cache.FileCache[Task]) => fc.withClassLoaders(Seq(classOf[coursier.cache.protocol.S3Handler].getClassLoader)) ) }
- Definition Classes
- CoursierModule
- def defaultCommandName(): String
The name of the default command, which will be automatically excecuted if the module name is provided at the Mill command line
The name of the default command, which will be automatically excecuted if the module name is provided at the Mill command line
- Definition Classes
- JavaModule → TaskModule
- def defaultResolver: define.Task[Resolver]
- Definition Classes
- CoursierModule
- def docJar: T[api.PathRef]
The documentation jar, containing all the Dokka HTML files, for publishing to Maven Central.
The documentation jar, containing all the Dokka HTML files, for publishing to Maven Central. You can control Dokka version by using dokkaVersion and option by using dokkaOptions.
- Definition Classes
- KotlinModule → JavaModule
- def docJarUseArgsFile: T[Boolean]
Control whether
docJar
-target should use a file to pass command line arguments to the javadoc tool.Control whether
docJar
-target should use a file to pass command line arguments to the javadoc tool. Defaults totrue
on Windows. Beware: Using an args-file is probably not supported for very old javadoc versions.- Definition Classes
- JavaModule
- def docResources: T[Seq[api.PathRef]]
Extra directories to be copied into the documentation.
Extra directories to be copied into the documentation.
Typically includes static files such as html and markdown, but depends on the doc tool that is actually used.
- Definition Classes
- JavaModule
- See also
- def docSources: T[Seq[api.PathRef]]
Directories to be processed by the API documentation tool.
Directories to be processed by the API documentation tool.
Typically includes the source files to generate documentation from.
- Definition Classes
- JavaModule
- See also
- def dokkaOptions: T[Seq[String]]
Additional options to be used by the Dokka tool.
Additional options to be used by the Dokka tool. You should not set the
-outputDir
setting for specifying the target directory, as that is done in the docJar target.- Definition Classes
- KotlinModule
- def dokkaVersion: T[String]
Dokka version.
Dokka version.
- Definition Classes
- KotlinModule
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalMainClass: T[String]
- Definition Classes
- JavaModule → RunModule
- def finalMainClassOpt: T[Either[String, String]]
- Definition Classes
- JavaModule → RunModule
- def forkArgs: T[Seq[String]]
Any command-line parameters you want to pass to the forked JVM under
run
,test
orrepl
Any command-line parameters you want to pass to the forked JVM under
run
,test
orrepl
- Definition Classes
- JavaModule → RunModule
- def forkEnv: T[Map[String, String]]
Any environment variables you want to pass to the forked JVM under
run
,test
orrepl
Any environment variables you want to pass to the forked JVM under
run
,test
orrepl
- Definition Classes
- JavaModule → RunModule
- def forkWorkingDir: T[Path]
- Definition Classes
- JavaModule → RunModule
- def generatedSources: T[Seq[api.PathRef]]
Combines standard Java source directories with additional sources generated by the Android resource generation step.
Combines standard Java source directories with additional sources generated by the Android resource generation step.
Ensures that generated files like
R.java
(which contain references to resources) are included in the source set and compiled correctly.- Definition Classes
- AndroidAppModule → JavaModule
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @HotSpotIntrinsicCandidate() @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @HotSpotIntrinsicCandidate() @native()
- def ideaCompileOutput: T[PathRef]
- Definition Classes
- GenIdeaModule
- def ideaConfigFiles(ideaConfigVersion: Int): define.Task[Seq[IdeaConfigFile]]
Contribute components to idea config files.
Contribute components to idea config files.
- Definition Classes
- GenIdeaModule
- def ideaJavaModuleFacets(ideaConfigVersion: Int): define.Task[Seq[JavaFacet]]
Contribute facets to the Java module configuration.
Contribute facets to the Java module configuration.
- ideaConfigVersion
The IDEA configuration version in use. Probably
4
.
- Definition Classes
- GenIdeaModule
- def intellijModulePath: Path
- Definition Classes
- GenIdeaModule
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def ivyDeps: T[Agg[scalalib.Dep]]
Any ivy dependencies you want to add to this Module, in the format ivy"org::name:version" for Scala dependencies or ivy"org:name:version" for Java dependencies
Any ivy dependencies you want to add to this Module, in the format ivy"org::name:version" for Scala dependencies or ivy"org:name:version" for Java dependencies
- Definition Classes
- JavaModule → JavaModuleBase
- def ivyDepsTree(args: IvyDepsTreeArgs = IvyDepsTreeArgs()): define.Command[Unit]
Command to print the transitive dependency tree to STDOUT.
Command to print the transitive dependency tree to STDOUT.
- Definition Classes
- JavaModule
- def jar: T[api.PathRef]
A jar containing only this module's resources and compiled classfiles, without those from upstream modules and dependencies
A jar containing only this module's resources and compiled classfiles, without those from upstream modules and dependencies
- Definition Classes
- JavaModule
- def javacOptions: T[Seq[String]]
Options to pass to the java compiler
Options to pass to the java compiler
- Definition Classes
- JavaModule → SemanticDbJavaModule
- def javadocOptions: T[Seq[String]]
Additional options to be used by the javadoc tool.
Additional options to be used by the javadoc tool. You should not set the
-d
setting for specifying the target directory, as that is done in the docJar target.- Definition Classes
- JavaModule
- def kotlinCompileTask(extraKotlinArgs: Seq[String] = Seq()): define.Task[CompilationResult]
The actual Kotlin compile task (used by compile and kotlincHelp).
The actual Kotlin compile task (used by compile and kotlincHelp).
- Attributes
- protected
- Definition Classes
- KotlinModule
- def kotlinCompilerClasspath: T[Seq[api.PathRef]]
The Java classpath resembling the Kotlin compiler.
The Java classpath resembling the Kotlin compiler. Default is derived from kotlinCompilerIvyDeps.
- Definition Classes
- KotlinModule
- def kotlinCompilerIvyDeps: T[Agg[Dep]]
The Ivy/Coursier dependencies resembling the Kotlin compiler.
The Ivy/Coursier dependencies resembling the Kotlin compiler. Default is derived from kotlinCompilerVersion.
- Definition Classes
- KotlinModule
- def kotlinCompilerVersion: T[String]
The version of the Kotlin compiler to be used.
The version of the Kotlin compiler to be used. Default is derived from kotlinVersion.
- Definition Classes
- KotlinModule
- def kotlinWorkerRef: ModuleRef[KotlinWorkerModule]
- Attributes
- protected
- Definition Classes
- KotlinModule
- def kotlinWorkerTask: define.Task[KotlinWorker]
- Definition Classes
- KotlinModule
- def kotlincHelp(args: String*): define.Command[Unit]
Runs the Kotlin compiler with the
-help
argument to show you the built-in cmdline help.Runs the Kotlin compiler with the
-help
argument to show you the built-in cmdline help. You might want to add additional arguments like-X
to see extra help.- Definition Classes
- KotlinModule
- def kotlincOptions: T[Seq[String]]
Additional Kotlin compiler options to be used by compile.
Additional Kotlin compiler options to be used by compile.
- Definition Classes
- KotlinModule
- def launcher: define.Target[api.PathRef]
Builds a command-line "launcher" file that can be used to run this module's code, without the Mill process.
Builds a command-line "launcher" file that can be used to run this module's code, without the Mill process. Useful for deployment & other places where you do not want a build tool running
- Definition Classes
- JavaModule
- def localClasspath: T[Seq[api.PathRef]]
The *output* classfiles/resources from this module, used for execution, excluding upstream modules and third-party dependencies, but including unmanaged dependencies.
The *output* classfiles/resources from this module, used for execution, excluding upstream modules and third-party dependencies, but including unmanaged dependencies.
This is build from localCompileClasspath and localRunClasspath as the parts available "before compilation" and "after compilation".
Keep in sync with bspLocalClasspath
- Definition Classes
- JavaModule
- def localCompileClasspath: T[Agg[api.PathRef]]
The *input* classfiles/resources from this module, used during compilation, excluding upstream modules and third-party dependencies
The *input* classfiles/resources from this module, used during compilation, excluding upstream modules and third-party dependencies
- Definition Classes
- JavaModule
- def localRunClasspath: T[Seq[api.PathRef]]
The part of the localClasspath which is available "after compilation".
The part of the localClasspath which is available "after compilation".
Keep in sync with bspLocalRunClasspath
- Definition Classes
- JavaModule → RunModule
- def mainClass: T[Option[String]]
Allows you to specify an explicit main class to use for the
run
command.Allows you to specify an explicit main class to use for the
run
command. If none is specified, the classpath is searched for an appropriate main class to use if one exists- Definition Classes
- JavaModule → RunModule
- def mandatoryIvyDeps: T[Agg[Dep]]
The dependencies of this module.
The dependencies of this module. Defaults to add the kotlin-stdlib dependency matching the kotlinVersion.
- Definition Classes
- KotlinModule → JavaModule
- def mandatoryJavacOptions: T[Seq[String]]
Additional options for the java compiler derived from other module settings.
Additional options for the java compiler derived from other module settings.
- Definition Classes
- JavaModule → SemanticDbJavaModule
- def manifest: T[JarManifest]
Creates a manifest representation which can be modified or replaced The default implementation just adds the
Manifest-Version
,Main-Class
andCreated-By
attributesCreates a manifest representation which can be modified or replaced The default implementation just adds the
Manifest-Version
,Main-Class
andCreated-By
attributes- Definition Classes
- JavaModule
- def mapDependencies: define.Task[(Dependency) => Dependency]
Map dependencies before resolving them.
Map dependencies before resolving them. Override this to customize the set of dependencies.
- Definition Classes
- CoursierModule
- implicit def millModuleBasePath: BasePath
- Definition Classes
- Module
- def millModuleDirectChildren: Seq[define.Module]
- Definition Classes
- Module
- implicit def millModuleExternal: External
- Definition Classes
- Module
- implicit def millModuleSegments: Segments
- Definition Classes
- Module
- implicit def millModuleShared: Foreign
- Definition Classes
- Module
- def millOuterCtx: Ctx
- Definition Classes
- BaseClass
- def millSourcePath: Path
- Definition Classes
- Module
- def moduleDeps: Seq[JavaModule]
The direct dependencies of this module.
The direct dependencies of this module. This is meant to be overridden to add dependencies. To read the value, you should use moduleDepsChecked instead, which uses a cached result which is also checked to be free of cycle.
- Definition Classes
- JavaModule
- See also
moduleDepschecked
- final def moduleDepsChecked: Seq[JavaModule]
Same as moduleDeps but checked to not contain cycles.
Same as moduleDeps but checked to not contain cycles. Prefer this over using moduleDeps directly.
- Definition Classes
- JavaModule
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @HotSpotIntrinsicCandidate() @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @HotSpotIntrinsicCandidate() @native()
- def platformSuffix: T[String]
What platform suffix to use for publishing, e.g.
What platform suffix to use for publishing, e.g.
_sjs
for Scala.js projects- Definition Classes
- JavaModule
- def prepareOffline(all: Flag): define.Command[Unit]
- all
If
true
fetches also source dependencies
- Definition Classes
- JavaModule → OfflineSupportModule
- def prependShellScript: T[String]
What shell script to use to launch the executable generated by
assembly
.What shell script to use to launch the executable generated by
assembly
. Defaults to a generic "universal" launcher that should work for Windows, OS-X and Linux- Definition Classes
- JavaModule
- def printDepsTree(inverse: Boolean, additionalDeps: define.Task[Agg[BoundDep]], whatDependsOn: List[JavaOrScalaModule]): define.Task[Unit]
Task that print the transitive dependency tree to STDOUT.
Task that print the transitive dependency tree to STDOUT. NOTE: that when
whatDependsOn
is used withinverse
it will just be ignored since when usingwhatDependsOn
the tree _must_ be inversed to work, so this will always be set as true.- inverse
Invert the tree representation, so that the root is on the bottom.
- additionalDeps
Additional dependency to be included into the tree.
- whatDependsOn
possible list of modules to target in the tree in order to see where a dependency stems from.
- Attributes
- protected
- Definition Classes
- JavaModule
- def recursiveModuleDeps: Seq[JavaModule]
The direct and indirect dependencies of this module
The direct and indirect dependencies of this module
- Definition Classes
- JavaModule
- def recursiveRunModuleDeps: Seq[JavaModule]
The direct and indirect runtime module dependencies of this module
The direct and indirect runtime module dependencies of this module
- Definition Classes
- JavaModule
- def repositoriesTask: define.Task[Seq[Repository]]
The repositories used to resolved dependencies with resolveDeps().
The repositories used to resolved dependencies with resolveDeps().
- Definition Classes
- CoursierModule
- def resolutionCustomizer: define.Task[Option[(Resolution) => Resolution]]
Customize the coursier resolution resolution process.
Customize the coursier resolution resolution process. This is rarely needed to changed, as the default try to provide a highly reproducible resolution process. But sometime, you need more control, e.g. you want to add some OS or JDK specific resolution properties which are sometimes used by Maven and therefore found in dependency artifact metadata. For example, the JavaFX artifacts are known to use OS specific properties. To fix resolution for JavaFX, you could override this task like the following:
override def resolutionCustomizer = Task.Anon { Some( (r: coursier.core.Resolution) => r.withOsInfo(coursier.core.Activation.Os.fromProperties(sys.props.toMap)) ) }
- Definition Classes
- CoursierModule
- def resolveDeps(deps: define.Task[Agg[BoundDep]], sources: Boolean = false, artifactTypes: Option[Set[Type]] = None): define.Task[Agg[api.PathRef]]
Task that resolves the given dependencies using the repositories defined with repositoriesTask.
Task that resolves the given dependencies using the repositories defined with repositoriesTask.
- deps
The dependencies to resolve.
- sources
If
true
, resolve source dependencies instead of binary dependencies (JARs).- artifactTypes
If non-empty, pull the passed artifact types rather than the default ones from coursier
- returns
The PathRefs to the resolved files.
- Definition Classes
- CoursierModule
- def resolvePublishDependency: define.Task[(scalalib.Dep) => Dependency]
- Definition Classes
- JavaModule
- def resolvedIvyDeps: T[Agg[api.PathRef]]
Resolved dependencies based on transitiveIvyDeps and transitiveCompileIvyDeps.
Resolved dependencies based on transitiveIvyDeps and transitiveCompileIvyDeps.
- Definition Classes
- JavaModule
- def resolvedRunIvyDeps: T[Agg[api.PathRef]]
- Definition Classes
- JavaModule
- def resolvedSemanticDbJavaPluginIvyDeps: T[Agg[api.PathRef]]
- Attributes
- protected
- Definition Classes
- SemanticDbJavaModule
- def resources: T[Seq[api.PathRef]]
The folders where the resource files for this module live.
The folders where the resource files for this module live. If you need resources to be seen by the compiler, use compileResources.
- Definition Classes
- JavaModule → JavaModuleBase
- def run(args: define.Task[Args] = Task.Anon(Args())): define.Command[Unit]
Runs this module's code in a subprocess and waits for it to finish
Runs this module's code in a subprocess and waits for it to finish
- Definition Classes
- JavaModule → RunModule
- def runBackground(args: String*): define.Command[Unit]
Runs this module's code in a background process, until it dies or
runBackground
is used again.Runs this module's code in a background process, until it dies or
runBackground
is used again. This lets you continue using Mill while the process is running in the background: editing files, compiling, and only re-starting the background process when you're ready.You can also use
-w foo.runBackground
to make Mill watch for changes and automatically recompile your code & restart the background process when ready. This is useful when working on long-running server processes that would otherwise run forever- Definition Classes
- JavaModule
- def runBackgroundLogToConsole: Boolean
If true, stdout and stderr of the process executed by
runBackground
orrunMainBackground
is sent to mill's stdout/stderr (which usualy flow to the console).If true, stdout and stderr of the process executed by
runBackground
orrunMainBackground
is sent to mill's stdout/stderr (which usualy flow to the console).If false, output will be directed to files
stdout.log
andstderr.log
inrunBackground.dest
(orrunMainBackground.dest
)- Definition Classes
- JavaModule → RunModule
- def runBackgroundTask(mainClass: define.Task[String], args: define.Task[Args] = Task.Anon(Args())): define.Task[Unit]
- Definition Classes
- RunModule
- def runClasspath: T[Seq[api.PathRef]]
All classfiles and resources from upstream modules and dependencies necessary to run this module's code after compilation
All classfiles and resources from upstream modules and dependencies necessary to run this module's code after compilation
- Definition Classes
- JavaModule → RunModule
- def runForkedTask(mainClass: define.Task[String], args: define.Task[Args] = Task.Anon(Args())): define.Task[Unit]
Runs this module's code in a subprocess and waits for it to finish
Runs this module's code in a subprocess and waits for it to finish
- Definition Classes
- RunModule
- def runIvyDeps: T[Agg[scalalib.Dep]]
Additional dependencies, only present at runtime.
Additional dependencies, only present at runtime. Useful for e.g. selecting different versions of a dependency to use at runtime after your code has already been compiled.
- Definition Classes
- JavaModule
- def runLocal(args: define.Task[Args] = Task.Anon(Args())): define.Command[Unit]
Runs this module's code in-process within an isolated classloader.
Runs this module's code in-process within an isolated classloader. This is faster than
run
, but in exchange you have less isolation between runs since the code can dirty the parent Mill process and potentially leave it in a bad state.- Definition Classes
- JavaModule → RunModule
- def runLocalTask(mainClass: define.Task[String], args: define.Task[Args] = Task.Anon(Args())): define.Task[Unit]
- Definition Classes
- RunModule
- def runMain(mainClass: String, args: String*): define.Command[Unit]
Same as
run
, but lets you specify a main class to runSame as
run
, but lets you specify a main class to run- Definition Classes
- JavaModule → RunModule
- def runMainBackground(mainClass: String, args: String*): define.Command[Unit]
Same as
runBackground
, but lets you specify a main class to runSame as
runBackground
, but lets you specify a main class to run- Definition Classes
- JavaModule → RunModule
- def runMainLocal(mainClass: String, args: String*): define.Command[Unit]
Same as
runLocal
, but lets you specify a main class to runSame as
runLocal
, but lets you specify a main class to run- Definition Classes
- JavaModule → RunModule
- def runModuleDeps: Seq[JavaModule]
The runtime-only direct dependencies of this module.
The runtime-only direct dependencies of this module. These *are* transitive, and so get propagated to downstream modules automatically
- Definition Classes
- JavaModule
- final def runModuleDepsChecked: Seq[JavaModule]
Same as moduleDeps but checked to not contain cycles.
Same as moduleDeps but checked to not contain cycles. Prefer this over using moduleDeps directly.
- Definition Classes
- JavaModule
- def runUseArgsFile: T[Boolean]
Control whether
run*
-targets should use an args file to pass command line args, if possible.Control whether
run*
-targets should use an args file to pass command line args, if possible.- Definition Classes
- JavaModule → RunModule
- def runner: define.Task[Runner]
- Definition Classes
- RunModule
- def semanticDbData: T[api.PathRef]
- Definition Classes
- SemanticDbJavaModule
- def semanticDbEnablePluginScalacOptions: T[Seq[String]]
Scalac options to activate the compiler plugins.
Scalac options to activate the compiler plugins.
- Attributes
- protected
- Definition Classes
- SemanticDbJavaModule
- def semanticDbJavaVersion: T[String]
- Definition Classes
- SemanticDbJavaModule
- def semanticDbPluginClasspath: T[Agg[api.PathRef]]
- Attributes
- protected
- Definition Classes
- SemanticDbJavaModule
- def semanticDbPluginIvyDeps: T[Agg[scalalib.Dep]]
- Attributes
- protected
- Definition Classes
- SemanticDbJavaModule
- def semanticDbScalaVersion: T[String]
- Definition Classes
- SemanticDbJavaModule
- def semanticDbVersion: T[String]
- Definition Classes
- SemanticDbJavaModule
- def showModuleDeps(recursive: Boolean = false): define.Command[Unit]
Show the module dependencies.
Show the module dependencies.
- recursive
If
true
include all recursive module dependencies, else only show direct dependencies.
- Definition Classes
- JavaModule
- def skipIdea: Boolean
Skip Idea project file generation.
Skip Idea project file generation.
- Definition Classes
- GenIdeaModule
- def sourceJar: T[api.PathRef]
The source jar, containing only source code for publishing to Maven Central
The source jar, containing only source code for publishing to Maven Central
- Definition Classes
- JavaModule
- def sources: T[Seq[api.PathRef]]
The folders where the source files for this module live
The folders where the source files for this module live
- Definition Classes
- JavaModule
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- Module → AnyRef → Any
- def transitiveCompileClasspath: T[Agg[api.PathRef]]
The transitive version of
compileClasspath
The transitive version of
compileClasspath
- Definition Classes
- JavaModule
- def transitiveCompileIvyDeps: T[Agg[BoundDep]]
The compile-only transitive ivy dependencies of this module and all it's upstream compile-only modules.
The compile-only transitive ivy dependencies of this module and all it's upstream compile-only modules.
- Definition Classes
- JavaModule
- def transitiveIvyDeps: T[Agg[BoundDep]]
The transitive ivy dependencies of this module and all it's upstream modules.
The transitive ivy dependencies of this module and all it's upstream modules. This is calculated from ivyDeps, mandatoryIvyDeps and recursively from moduleDeps.
- Definition Classes
- JavaModule
- def transitiveLocalClasspath: T[Agg[api.PathRef]]
The transitive version of
localClasspath
The transitive version of
localClasspath
- Definition Classes
- JavaModule
- def transitiveModuleCompileModuleDeps: Seq[JavaModule]
All direct and indirect module dependencies of this module, including compile-only dependencies: basically the modules whose classpath are needed at compile-time.
All direct and indirect module dependencies of this module, including compile-only dependencies: basically the modules whose classpath are needed at compile-time.
Note that
compileModuleDeps
are defined to be non-transitive, so we only look at the directcompileModuleDeps
when assembling this list- Definition Classes
- JavaModule
- def transitiveModuleDeps: Seq[JavaModule]
Like
recursiveModuleDeps
but also include the module itself, basically the modules whose classpath are needed at runtimeLike
recursiveModuleDeps
but also include the module itself, basically the modules whose classpath are needed at runtime- Definition Classes
- JavaModule
- def transitiveModuleRunModuleDeps: Seq[JavaModule]
All direct and indirect module dependencies of this module, including compile-only dependencies: basically the modules whose classpath are needed at runtime.
All direct and indirect module dependencies of this module, including compile-only dependencies: basically the modules whose classpath are needed at runtime.
Note that
runModuleDeps
are defined to be transitive- Definition Classes
- JavaModule
- def transitiveRunIvyDeps: T[Agg[BoundDep]]
The transitive run ivy dependencies of this module and all it's upstream modules.
The transitive run ivy dependencies of this module and all it's upstream modules. This is calculated from runIvyDeps, mandatoryIvyDeps and recursively from moduleDeps.
- Definition Classes
- JavaModule
- def transitiveRunModuleDeps: Seq[JavaModule]
Like
recursiveModuleDeps
but also include the module itself, basically the modules whose classpath are needed at runtimeLike
recursiveModuleDeps
but also include the module itself, basically the modules whose classpath are needed at runtime- Definition Classes
- JavaModule
- def unmanagedClasspath: T[Agg[api.PathRef]]
Adds the Android SDK JAR file to the classpath during the compilation process.
Adds the Android SDK JAR file to the classpath during the compilation process.
- Definition Classes
- AndroidAppModule → JavaModule
- def upstreamAssembly2: T[Assembly]
Build the assembly for upstream dependencies separate from the current classpath
Build the assembly for upstream dependencies separate from the current classpath
This should allow much faster assembly creation in the common case where upstream dependencies do not change
- Definition Classes
- JavaModule
- def upstreamAssemblyClasspath: T[Agg[api.PathRef]]
All upstream classfiles and resources necessary to build and executable assembly, but without this module's contribution
All upstream classfiles and resources necessary to build and executable assembly, but without this module's contribution
- Definition Classes
- JavaModule
- def upstreamCompileOutput: T[Seq[CompilationResult]]
The upstream compilation output of all this module's upstream modules
The upstream compilation output of all this module's upstream modules
- Definition Classes
- JavaModule → SemanticDbJavaModule
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- def when(cond: Boolean)(args: String*): Seq[String]
- Attributes
- protected
- Definition Classes
- KotlinModule
- def zincAuxiliaryClassFileExtensions: T[Seq[String]]
Files extensions that need to be managed by Zinc together with class files.
Files extensions that need to be managed by Zinc together with class files. This means, if zinc needs to remove a class file, it will also remove files which match the class file basename and a listed file extension.
- Definition Classes
- JavaModule
- def zincIncrementalCompilation: T[Boolean]
- Definition Classes
- JavaModule → SemanticDbJavaModule
- def zincReportCachedProblems: T[Boolean]
If
true
, we always show problems (errors, warnings, infos) found in all source files, even when they have not changed since the previous incremental compilation.If
true
, we always show problems (errors, warnings, infos) found in all source files, even when they have not changed since the previous incremental compilation. Whenfalse
, we report only problems for files which we re-compiled.- Definition Classes
- JavaModule → SemanticDbJavaModule
- def zincWorker: ModuleRef[ZincWorkerModule]
- Definition Classes
- JavaModule → SemanticDbJavaModule → WithZincWorker
- def zincWorkerRef: ModuleRef[ZincWorkerModule]
- Attributes
- protected
- Definition Classes
- KotlinModule
Deprecated Value Members
- def doRunBackground(taskDest: Path, runClasspath: Seq[api.PathRef], zwBackgroundWrapperClasspath: Agg[api.PathRef], forkArgs: Seq[String], forkEnv: Map[String, String], finalMainClass: String, forkWorkingDir: Path, runUseArgsFile: Boolean, backgroundOutputs: Option[(ProcessOutput, ProcessOutput)])(args: String*): (Ctx) => Result[Unit]
- Attributes
- protected
- Definition Classes
- JavaModule → RunModule
- Annotations
- @deprecated
- Deprecated
(Since version Mill 0.12.0) Binary compat shim, use
.runner().run(..., background=true)
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated
(Since version 9)
- def resolveCoursierDependency: define.Task[(scalalib.Dep) => Dependency]
- Definition Classes
- CoursierModule
- Annotations
- @deprecated
- Deprecated
(Since version Mill after 0.11.0-M0) To be replaced by bindDependency
- def resolveDeps(deps: define.Task[Agg[BoundDep]], sources: Boolean): define.Task[Agg[api.PathRef]]
- Definition Classes
- CoursierModule
- Annotations
- @deprecated
- Deprecated
(Since version Mill after 0.12.0-RC3) Use the override accepting artifactTypes
- def upstreamAssembly: T[api.PathRef]
Build the assembly for upstream dependencies separate from the current classpath
Build the assembly for upstream dependencies separate from the current classpath
This should allow much faster assembly creation in the common case where upstream dependencies do not change
This implementation is deprecated because of it's return value. Please use upstreamAssembly2 instead.
- Definition Classes
- JavaModule
- Annotations
- @deprecated
- Deprecated
(Since version Mill 0.11.8) Use upstreamAssembly2 instead, which has a richer return value