Is there a way to find out all the possible activator command line options?
The activator -help
only provides a bare minimum available option/feature list but all the nice things are hidden and not available even on the typesafe website online documentation.
So far I know of the following commands/features:
activator run
activator -jvm-debug 9999 run
activator compile
activator clean
activator clean compile dist
activator doc //creates a nice documentation of your whole project
Any idea where this is information is available?
('m using activator to run Play framework projects)
Let's dive a little deeper and show examples with some of the more useful features built into Typesafe Config. Some features include reading config values as lists, configuration resolution, fallback configs, memory helpers, duration helpers and boolean helpers.
Operation Not Permitted in SBT / Typesafe Activator inside Vagrant Synced Folder 1 typesafe activator dependency error 3 Typesafe Activator running error (Could not retrieve jansi 1.11)
It can be used as a wrapper script that launches into traditional command line sbt, but it also includes a template and tutorial system, and an optional GUI for getting started. You can think of Activator as traditional sbt (activator shell or activator ), plus an optional UI mode (activator ui), plus a template system (activator new).
The built-in buttons remain for common tasks (compile, run, test), but the search box at the top of Activator’s UI now autocompletes tasks in addition to source files: We’re now grouping templates based on the Typesafe Reactive Platform in their own category.
Activator is not some tool that have some wide options. It looks like, but it is just a wrapper to run sbt project. From the activator source page in git:
Activator aims to be a friendly one-stop-shop to bootstrap your Scala, Akka, and Play development. It can be used as a wrapper script that launches into traditional command line sbt, but it also includes a template and tutorial system, and an optional GUI for getting started.
You can think of Activator as traditional sbt (activator shell or activator ), plus an optional UI mode (activator ui), plus a template system (activator new).
That's all. Actually only four commands:
Let's look in to this in a details.
The source code
https://github.com/typesafehub/activator/blob/master/launcher/src/main/scala/activator/ActivatorLauncher.scala
try configuration.arguments match {
case Array("ui") => RebootToUI(configuration, version = checkForUpdatedVersion.getOrElse(APP_VERSION))
case Array("new", _*) => Exit(ActivatorCli(configuration))
case Array("list-templates") => Exit(TemplateHandler())
case Array("shell") => RebootToSbt(configuration, useArguments = false)
case _ if Sbt.looksLikeAProject(new File(".")) => RebootToSbt(configuration, useArguments = true)
case _ => displayHelp(configuration)
} catch {
case e: Exception => generateErrorReport(e)
}
You can see that there is only 4 commands ui, new, list-template, shell and one meta command:
case _ if Sbt.looksLikeAProject(new File(".")) => RebootToSbt(configuration, useArguments = true)
It means that if you run activator
command in the project directory (and it's not ui
, new
, list-template
, shell
) than activator will run sbt with the command and argument that you pass to the activator. So run
, compile
, stage
is not activator commands but sbt commands.
If you will run activator not in the project directory (and it's not ui
, new
, list-template
, shell
commands), then it will show you some "help page"
Activator also allow to pass java arguments that would be used for run activator.jar - you can see it by inspecting "activator.bat" file or activator shell script.
SBT
Reference of sbt commands you can found here: http://www.scala-sbt.org/0.13/docs/Command-Line-Reference.html
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With