relateiq/scala-school

Name: scala-school

Owner: SalesforceIQ

Description: null

Created: 2017-07-25 05:37:56.0

Updated: 2017-07-31 17:32:52.0

Pushed: 2017-07-25 18:38:55.0

Homepage: null

Size: 10

Language: Scala

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

scala-school

scala school play along repo

Development

To start an interactive SBT session, type sbt at the prompt:

t

From inside this session, you can execute any of the standard SBT tasks below:

n            Deletes files produced by the build, such as generated sources, compiled classes, and task caches.
ile          Compiles sources.
ole          Starts the Scala interpreter with the project classes on the classpath.
oleProject   Starts the Scala interpreter with the sbt and the build definition on the classpath and useful imports.
oleQuick     Starts the Scala interpreter with the project dependencies on the classpath.
Resources    Copies resources to the output directory.
             Generates API documentation.
age          Produces the main artifact, such as a binary jar.  This is typically an alias for the task that actually does the packaging.
ageBin       Produces a main artifact, such as a binary jar.
ageDoc       Produces a documentation artifact, such as a jar containing API documentation.
ageSrc       Produces a source artifact, such as a jar containing sources and resources.
ish          Publishes artifacts to a repository.
ishLocal     Publishes artifacts to the local Ivy repository.
ishM2        Publishes artifacts to the local Maven repository.
             Runs a main class, passing along arguments provided on the command line.
ain          Runs the main class selected by the first argument, passing the remaining arguments to the main method.
astyle       Run scalastyle on your code
             Executes all tests.
Only         Executes the tests provided as arguments or all tests if no arguments are provided.
Quick        Executes the tests that either failed before, were not run or whose transitive dependencies changed, among those provided as arguments.
te           Resolves and optionally retrieves dependencies, producing a report.

Start a Scala console (REPL) session in the usual way, by running the console task, as shown below:

nsole
o] Compiling 1 Scala source to /Users/spoderman/projects/herp/target/scala-2.11/classes...
o] Starting scala interpreter...
o]
ome to Scala 2.11.8 (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_25).
 in expressions for evaluation. Or try :help.

a>

This starts an interactive Scala session, with the classpath of your project sources.

Contributing

Contributions are reviewed and accepted via pull request. To create one, perform the following steps:

  1. Create a feature branch
  2. Implement your contribution
  3. Write tests
  4. Write documentation
  5. Validate changes
  6. Submit pull request

Before submitting a pull request, ensure that your feature branch builds cleanly with the validate command alias, which will run additional static code analysis with scalastyle and WartRemover before running the unit tests, as follows:

lidate
o] scalastyle using config /Users/spoderman/projects/herp/scalastyle-config.xml
o] Processed 1 file(s)
o] Found 0 errors
o] Found 0 warnings
o] Found 0 infos
o] Finished in 1 ms
cess] created output: /Users/spoderman/projects/herp/target
cess] Total time: 0 s, completed Jan 31, 2017 2:08:17 PM
o] Compiling 1 Scala source to /Users/spoderman/projects/herp/target/scala-2.11/classes...
o] HerpSpec:
o] ScalaTest
o] Run completed in 108 milliseconds.
o] Total number of tests run: 0
o] Suites: completed 1, aborted 0
o] Tests: succeeded 0, failed 0, canceled 0, ignored 0, pending 0
o] No tests were executed.
o] Passed: Total 0, Failed 0, Errors 0, Passed 0
cess] Total time: 1 s, completed Jan 31, 2017 2:08:17 PM
Building

The release process for scala-school makes use of the sbt-release plugin. The release steps are as follows:

  1. Check for SNAPSHOT dependencies
  2. Clean generated files
  3. Run the validate command to compile and test sources
  4. Set the release version of the JAR
  5. Commit the release version
  6. Tag the release in Github
  7. Publish project artifacts
  8. Set the next development version of the project
  9. Commit the next version
  10. Push changes to Github

This can be done interactively by running the release task, or non-interactively by running the release with-defaults task, to accept all defaults. The defaults are almost always sensible.


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.