SBT: Start a command line 'run' of the main class of a non-default project

前端 未结 4 1082
别那么骄傲
别那么骄傲 2021-01-30 08:33

I am starting to use sbt build my Scala code (and handle dependencies). As far as I know if I use

$ sbt run 

on the command line th

4条回答
  •  甜味超标
    2021-01-30 08:45

    This works: sbt "runMain com.example.Hello arg1" or sbt "run-main com.example.Hello arg1".

    See here for reference: https://blog.ssanj.net/posts/2016-03-02-how-to-run-a-specific-main-class-with-parameters-through-sbt.html

提交回复
热议问题