Skip to content

Commit

Permalink
Add shadow to build the app
Browse files Browse the repository at this point in the history
  • Loading branch information
duncte123 committed Dec 9, 2023
1 parent 9ba86c1 commit c304ae0
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 1 deletion.
22 changes: 21 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,24 @@
[openjdk]: https://www.azul.com/downloads/?version=java-21-lts&architecture=x86-64-bit&package=jre#zulu
[download]: https://github.com/duncte123/bruh-mark/releases/latest

# Bruh Mark
My solution for day 5 part 2 of Advent of Code 2023 was so hard on the CPU that I decided to turn it into a weird benchmark.

My own score: DNF

TODO: how to compile, how to run, requirements and releases
## Running the application
To run this application you will need to install java 21 or newer, you can download [openjdk here][openjdk]. I built this application with Azul's jdk so that one is validated to work.
Once you have downloaded and installed java, you can validate the installation by running `java -version` in your favourite terminal, it should list version 21.

Next up you can download the latest version of Bruh Mark from the [releases page][download].
After that, you should open a terminal window in the directory that you downloaded `BruhMark.jar` into and run `java -jar BruhMark.jar`

## Compiling from source
To compile from source, you will need to have the JDK installed instead of the JRE. After that, you need to run the following command in the folder that contains the `src` directory of this project

```bash
./gradlew build
```
(On windows you will need to run `gradlew.bat build`)

The resulting file will be in `build/libs/BruhMark.jar`
10 changes: 10 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar

plugins {
kotlin("jvm") version "1.9.21"
application
id("com.github.johnrengelman.shadow") version "8.1.1"
}

group = "me.duncte123"
Expand All @@ -26,3 +29,10 @@ tasks.withType<Wrapper> {
gradleVersion = "8.5"
distributionType = Wrapper.DistributionType.BIN
}

tasks.withType<ShadowJar> {
// Configure the file name to be "BruhMark.jar"
archiveBaseName.set("BruhMark")
archiveClassifier.set("")
archiveVersion.set("")
}

0 comments on commit c304ae0

Please sign in to comment.