davsclaus commented on issue #1847:
URL: https://github.com/apache/camel-website/issues/1847#issuecomment-6549235248

   Tested locally (macOS arm64, Homebrew 7.0.11): the formula rendered from 
`formula.rb.tpl` for the released 4.23.0 works.
   
   | Step | Result |
   |---|---|
   | `brew audit --new --strict --online` | pass, no findings |
   | `brew install` from a local tap | pass, pulls in `openjdk@21` |
   | `brew test` (`camel --version`) | pass |
   | `camel init hello.yaml` + `camel run hello.yaml` | pass, Camel 4.23.0 
starts the route |
   | `camel doctor` | lists the Homebrew installation 
(`/opt/homebrew/Cellar/apache-camel/4.23.0/libexec (HOMEBREW)`) |
   | `camel self-update --check` | refuses: `this install is managed by 
Homebrew - run 'brew upgrade apache-camel'` |
   
   With `camel` also installed by JBang (`~/.jbang/bin`) earlier on the `PATH`, 
`brew install` prints a caveat that it shadows the Homebrew one.
   
   The formula (the `sha256` matches the `.sha1` of the zip on Maven Central):
   
   ```ruby
   class ApacheCamel < Formula
     desc "CLI for building and running Apache Camel integration routes"
     homepage "https://camel.apache.org/";
     url 
"https://search.maven.org/remotecontent?filepath=org/apache/camel/camel-launcher/4.23.0/camel-launcher-4.23.0-bin.zip";
     sha256 "2fa53a229fb5ef8e819cbc24a015d75a16105c9c0b7897742d13adea1695c8e5"
     license "Apache-2.0"
   
     livecheck do
       url 
"https://search.maven.org/remotecontent?filepath=org/apache/camel/camel-launcher/maven-metadata.xml";
       regex(%r{<release>([0-9]+\.[0-9]+\.[0-9]+)</release>}i)
     end
   
     depends_on "openjdk@21"
   
     def install
       libexec.install Dir["*"]
       (bin/"camel").write_env_script libexec/"bin/camel.sh",
         Language::Java.overridable_java_home_env("21")
     end
   
     test do
       output = shell_output("#{bin}/camel --version")
       assert_match "4.23.0", output
     end
   end
   ```
   
   Next step is the pull request against Homebrew/homebrew-core, adding it as 
`Formula/a/apache-camel.rb`, from a committer's own account.
   
   _Claude Code on behalf of davsclaus (Claus Ibsen)_
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to