2

In a .travis.yml file using sbt, I see this

script:
  - sbt ++$TRAVIS_SCALA_VERSION test:fastOptJS test:fullOptJS

In sbt, I can run test, and I can run fastOptJS . What does the single colon between them do?

In travis, can one run a sequence of commands? ie. what does it mean for test:fastOptJS to be followed by test:fullOptJS?

dcl04
  • 89
  • 8

1 Answers1

5

In sbt, I can run test, and I can run fastOptJS . What does the single colon between them do?

test:fastOptJS means fastOptJS in test scope. The confusion comes from the fact that the test scope and the test task are both test in sbt's shell.

This, btw, is fixed in sbt 1.1's new "unified slash syntax" where the test scope now Test, so test:fastOptJS is now Test / fastOptJS.

In travis, can one run a sequence of commands? ie. what does it mean for test:fastOptJS to be followed by test:fullOptJS?

Yes you can run a sequence of commands.

sbt ++$TRAVIS_SCALA_VERSION test:fastOptJS test:fullOptJS means run ++$TRAVIS_SCALA_VERSION (which changes scalaVersion), then test:fastOptJS then test:fullOptJS.

Dale Wijnand
  • 6,054
  • 5
  • 28
  • 55