diff --git a/README.md b/README.md index 5172bd0c..0a979194 100644 --- a/README.md +++ b/README.md @@ -79,10 +79,10 @@ OpenFastTrace at it's core is a Java Archive (short "[JAR](https://docs.oracle.c ### Getting Pre-Built Packages -Pre-Built JAR files (called `openfasttrace-4.2.0.jar`) are available from the following places: +Pre-Built JAR files (called `openfasttrace-4.9.0.jar`) are available from the following places: -* [Maven Central](https://repo1.maven.org/maven2/org/itsallcode/openfasttrace/openfasttrace/4.2.0/openfasttrace-4.2.0.jar) -* [GitHub](https://github.com/itsallcode/openfasttrace/releases/download/4.2.0/openfasttrace-4.2.0.jar) +* [Maven Central](https://repo1.maven.org/maven2/org/itsallcode/openfasttrace/openfasttrace/4.9.0/openfasttrace-4.9.0.jar) +* [GitHub](https://github.com/itsallcode/openfasttrace/releases/download/4.9.0/openfasttrace-4.9.0.jar) Check our [developer guide](doc/developer_guide.md#getting-the-openfasttrace-library) to learn how to use the OFT JAR as dependency in your own code with popular build tools. @@ -101,6 +101,20 @@ If you just want to run OFT: apt-get install openjdk-17-jre +### Installation via Homebrew + +On macOS or Linux, install OpenFastTrace with [Homebrew](https://brew.sh/): + +```shell +brew install openfasttrace +``` + +The formula installs the OpenJDK 17 runtime dependency and provides the `oft` command. For example: + +```shell +oft trace /path/to/directory/being/traced +``` + ## Running OpenFastTrace ### Run JAR File @@ -108,7 +122,7 @@ If you just want to run OFT: The most basic variant to run OpenFastTrace is directly from the JAR file via the command line: ```sh -java -jar product/target/openfasttrace-4.2.0.jar trace /path/to/directory/being/traced +java -jar product/target/openfasttrace-4.9.0.jar trace /path/to/directory/being/traced ``` If you want to run OFT automatically as part of a continuous build, we recommend using our plugins for [Gradle](https://github.com/itsallcode/openfasttrace-gradle) and [Maven](https://github.com/itsallcode/openfasttrace-maven-plugin). diff --git a/doc/changes/changes_4.10.0.md b/doc/changes/changes_4.10.0.md index 374c5d78..1d7b19e3 100644 --- a/doc/changes/changes_4.10.0.md +++ b/doc/changes/changes_4.10.0.md @@ -11,6 +11,7 @@ Each release now includes an SPDX 3 SBOM for the product JAR and a SHA-256 check ## Feature * #542: CI and releases now provide an SPDX 3 SBOM. +* #586: Publish to Homebrew ## Bugfixes diff --git a/doc/developer_guide.md b/doc/developer_guide.md index 714d64f1..2aa033eb 100644 --- a/doc/developer_guide.md +++ b/doc/developer_guide.md @@ -15,7 +15,7 @@ To use OpenFastTrace as a dependency in your [Maven](https://maven.apache.org) p org.itsallcode.openfasttrace openfasttrace - 4.2.0 + 4.9.0 compile @@ -27,7 +27,7 @@ To use OpenFastTrace as a dependency in your [Gradle](https://gradle.org/) proje ```groovy dependencies { - compile "org.itsallcode.openfasttrace:openfasttrace:4.2.0" + compile "org.itsallcode.openfasttrace:openfasttrace:4.9.0" } ``` @@ -275,6 +275,44 @@ mvn package * or go to [GitHub Actions](https://github.com/itsallcode/openfasttrace/actions/workflows/release.yml) and start the `release.yml` workflow on branch `main`. 2. Update the title and description of the newly created [GitHub release](https://github.com/itsallcode/openfasttrace/releases). 3. After some time the release will be available at [Maven Central](https://repo1.maven.org/maven2/org/itsallcode/openfasttrace/openfasttrace/). +4. Verify Homebrew release + 1. Check that Homebrew detects the release: + ```shell + brew livecheck openfasttrace + ``` + 2. Homebrew/core's autobump service automatically opens a pull request to update the `openfasttrace` formula. Review the formula update and its CI results, respond to any maintainer feedback, and merge the pull request when it is ready. + 3. After the formula update is merged, confirm that Homebrew reports the new version: + ```shell + brew info openfasttrace + ``` + +The Homebrew follow-up is performed in Homebrew/core. It does not require Homebrew credentials, formula-update automation, or additional changes in this repository. + +## Homebrew Formula + +OpenFastTrace is published in [Homebrew/core](https://github.com/Homebrew/homebrew-core) as the `openfasttrace` formula. It installs the portable release JAR and exposes the `oft` command with an OpenJDK 17 runtime. + +### Updating the Formula + +1. Fork `Homebrew/homebrew-core`, tap it locally with `brew tap --force homebrew/core`, and create a branch from the current `main` branch. +2. Update `Formula/o/openfasttrace.rb` with the immutable GitHub Release JAR URL and its SHA-256 checksum from the matching `.jar.sha256` release asset. +3. Follow Homebrew's [Formula Cookbook](https://docs.brew.sh/Formula-Cookbook) and [pull request guidance](https://docs.brew.sh/How-To-Open-a-Homebrew-Pull-Request), including its required AI-use disclosure when applicable. + +### Testing the Formula + +From the Homebrew/core checkout, validate the formula with: + +```shell +HOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source openfasttrace +brew test openfasttrace +brew audit --new --strict --online openfasttrace +``` + +The formula's GitHub Release JAR URL is discoverable by Homebrew's default livecheck strategy. After the initial formula is merged, Homebrew/core's autobump service maintains new release versions. Confirm discovery locally when updating the formula: + +```shell +brew livecheck openfasttrace +``` ## Module Overview