Template for the project of the course MAC0218 - Programming Techniques II at University of São Paulo (@USP).
Galaxy Raiders is built in Kotlin, a modern programming language for the JVM (Java Virtual Machine) supporting object-oriented programming and functional programming. It uses Gradle as the official build tool.
To develop Galaxy Raiders, please install and use docker.
NOTE: This repo has gradle wrappers to ensure developers use the same version of gradle in every environment. However, using gradle's docker image already guarantees that. Therefore, commands below can use the
gradleCLI directly.
Please also install pre-commit in your development environment to automatically format code and to detect bed smells before making new commits. By default, this integration also uses docker.
This project uses ktlint and detekt for static code analysis.
If you installed pre-commit, to execute the linters, run:
pre-commit run --all-filesAlternatively, to execute the linters manually, run:
docker compose --profile dev run --rm linterThe compilation of all classes and the generation of a runnable self-contained JAR is made "behind the scenes" by docker.
To build the development images, run:
docker compose --profile dev buildTo build the production images, run:
docker compose --profile prod buildAll tests in the project are developed using JUnit 5.
To execute all tests (with live reload), run:
docker compose --profile dev up testerTo execute the project in development mode (with live reload), run:
docker compose --profile dev up demo --buildTo execute the project in production mode, run:
docker compose --profile prod up game --buildTo find available gradle tasks, run:
docker compose --profile dev run --rm demo gradle --no-daemon tasksTo execute any task, run:
docker compose --profile dev run --rm demo gradle --no-daemon {task}