diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 412c209..69bced5 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -29,7 +29,8 @@ jobs: - name: Strip v from version run: echo "RELEASE_VERSION=${RELEASE_VERSION#v}" >> $GITHUB_ENV - - run: chmod +x gradlew && ./gradlew build publish --no-daemon + - name: Build and publish to GitHub Packages + run: chmod +x gradlew && ./gradlew build publish --no-daemon env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.idea/misc.xml b/.idea/misc.xml index e1c3f7e..32cf4db 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -4,7 +4,7 @@ - + \ No newline at end of file diff --git a/README.md b/README.md index b82a19a..bd07952 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,50 @@ Java library for terminal UI: tables, rules, colors, prompts, menus, SelectList, [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/jakubbbdev/terminal-ui) +## Install + +Published to [GitHub Packages](https://github.com/jakubbbdev/terminal-ui/packages). Replace `VERSION` with a [release](https://github.com/jakubbbdev/terminal-ui/releases) tag (e.g. `1.0.0`). + +**Gradle (Kotlin DSL):** + +```kotlin +repositories { + mavenCentral() + maven { url = uri("https://maven.pkg.github.com/jakubbbdev/terminal-ui") } +} +dependencies { + implementation("dev.jakub.terminal:terminal-ui:VERSION") +} +``` + +**Gradle (Groovy):** + +```groovy +repositories { + mavenCentral() + maven { url "https://maven.pkg.github.com/jakubbbdev/terminal-ui" } +} +dependencies { + implementation "dev.jakub.terminal:terminal-ui:VERSION" +} +``` + +**Maven:** + +```xml + + github + https://maven.pkg.github.com/jakubbbdev/terminal-ui + + + dev.jakub.terminal + terminal-ui + VERSION + +``` + +For public packages, read access usually works without credentials. If your tool asks for auth, use a [GitHub PAT](https://github.com/settings/tokens) with `read:packages` as username and the token as password. + ## Requirements - **Java 21**