Learning Scala and SBT by following "Get Programming with Scala" by Manning.
This is a monorepo containing chapter-wise SBT projects. Each lesson/chapter has its own independent SBT project.
sbt-tutorial/
βββ lesson-09/ # Lesson 9: Import and create packages
β βββ build.sbt
β βββ README.md
β βββ src/
β βββ main/
β βββ scala/
βββ lesson-54/ # Lesson 54: Apache Pekko HTTP Server - Todo App
β βββ build.sbt
β βββ README.md
β βββ src/
β βββ main/
β βββ scala/
βββ lesson-XX/ # Future lessons will be added here
βββ ...
- Isolation: Each lesson is independent and can be run separately
- Organization: Easy to navigate and find specific lesson examples
- Learning: Clear progression through the book
- Version Control: Single git repository for all lessons
Each lesson is a complete SBT project. To work with a specific lesson:
# Navigate to the lesson directory
cd lesson-09
# Start SBT console
sbt
# Compile the project
sbt compile
# Run tests
sbt test
# Run a specific main class
sbt run-
Lesson 9: Import and create packages
- Demonstrates package creation (
my.example.io) - Example:
MyExample.scala- File reading utility class
- Demonstrates package creation (
-
Lesson 54: Apache Pekko HTTP Server - Todo App
- In-memory todo application with server-rendered HTML
- Demonstrates Pekko HTTP routing, form handling, and HTML generation
- Features: Add, view, toggle, delete todos with a clean web interface
When you reach a new lesson in the book:
- Create a new directory:
lesson-XX/ - Add a
build.sbtfile with appropriate dependencies - Create
src/main/scala/directory structure - Add a
README.mdexplaining what the lesson covers - Implement the examples from the book
This repository is configured with:
- Name: Piyush Chauhan
- Email: piyushchauhan2011@gmail.com
All commits will use these credentials automatically.
Following the book chapters and implementing examples as I go! π