Senior Scala Developer
Senior Scala Developer
contributor for Scala Center
VS
ScalaCLI
Metals
ScalaCLI
Metals
Better command line interface for Scala
LSP server providing language features to editors such as VS Code, Vim, Emacs, Sublime
It contains information about how to install it, what features are available, cookbooks and guides with multiple example.
> scala-cli run Main.scala
> scala-cli -S 3.1.3 Main.scala
> scala-cli compile --jvm adopt:14 Main.scala
> scala-cli fmt --check
> scala-cli package --native .
> scala-cli publish .
> scala-cli test .
> scala-cli repl --ammonite .
Main commands:
clean Clean the workspace
compile Compile Scala code
dependency-update Update dependencies in project
doc Generate Scaladoc documentation
fmt, format, scalafmt Format Scala code
repl, console Fire-up a Scala REPL
package Compile and package Scala code
publish
publish local
publish setup
run Compile and run Scala code.
test Compile and test Scala code
Miscellaneous commands:
about Print details about this application
version Print `scala-cli` version
See 'scala-cli <command> --help' to read about a specific subcommand.
To see full help run 'scala-cli <command> --help-full'.
#!/usr/bin/env -S scala-cli shebang
//> using scala "3.2.0"
object types:
trait Opaque[H, T](using H =:= T):
def apply(s: T): H = s.asInstanceOf[H]
extension (h: H) def value: T = h.asInstanceOf[T]
opaque type Hello = String
object Hello extends Opaque[Hello, String]
@main def hello =
import types.{*, given}
val x = Hello("yes")
x.value