Awesome
Scala Bootstrap (base / project skeleton)
[!IMPORTANT]
Project deprecated in favor of Codely Scala Basic Skeleton (powered by Giter 8)
Introduction
This is a repository intended to serve as a starting point if you want to bootstrap a project in Scala.
It could be useful if you want to start from scratch a kata or a little exercise or project. The idea is that you don't have to worry about the boilerplate, just clone this repo and there you go:
- Latest versions of Scala, SBT and ScalaTest in order to practice with them
- Best practices applied:
README.md
(badges included)LICENSE
build.sbt
scalastyle-config.xml
.scalafmt.conf
.gitignore
.editorconfig
.travis.yml
How To Start
Video screencast (in Spanish)
- Clone this repository
git clone https://github.com/CodelyTV/scala_bootstrap
. - Run SBT on the project directory
sbt
. - Run the scalatests with
t
. - Check the scalastyle in the production code with
s
and use thets
command to check the test code style. - Check the scalaFmt with
tf
command to check the code style and apply guidelines withf
. - Start your project!
Pre-push Git hook
There's one Git hook included. It's inside the doc/hooks
folder and it will run the prep
SBT task before pushing to any remote.
This prep
task is intended to run all the checks you consider before pushing. At this very moment, it try to compile and check the code style rules with ScalaStyle and ScalaFmt.
You can define what this task does just modifying the prep
task in the build.sbt
file. We like the approach of just running 1 single SBT task as the hook instead of multiple tasks because it's more efficient (the hook doesn't has to run SBT multiple times), and also because this way we can control the pre push tasks just with the SBT alias defined at the build.sbt
without altering the hooks.
If you want to install this hook, just cd doc/hooks
and run ./install-hooks.sh
.
Other programming languages
- Scala g8 template Useful to bootstrap your project with the
sbt new
command! - PHP
- Scala
About
This hopefully helpful utility has been developed by CodelyTV and contributors.
We'll try to maintain this project as simple as possible, but Pull Requests are welcomed!
License
The MIT License (MIT). Please see License File for more information.