This is an implementation of the minesweeper game in Java. Its UI is implemented using JavaFX.
JDK 11 or later is required for this project.
The easiest way to run the game is using the Gradle build. After checking out this project, you can run the game from its root directory as follows:
$ git clone https://github.com/ThatHai/mines.git
$ cd mines
$ ./gradlew run
Instead of cloning the project, you can just download the project zip file.
Alternatively, you can create a distribution of the project and run the game with the generated script:
$ ./gradlew installDist
$ ./build/install/mines/bin/mines
Note: JavaFX runtime libs are platform specific, thus you can only run the game on the platform you create the distribution for.
This is an application gradle project, thus the usual gradle tasks apply:
to build
$ ./gradlew build
to run unit tests
$ ./gradlew test
to create the install distribution (located in build/install
)
$ ./gradlew installDist