Skip to content

Commit

Permalink
Setup rtx support (#46)
Browse files Browse the repository at this point in the history
  • Loading branch information
gi-wg2 authored Oct 20, 2023
1 parent e49ea6e commit 10b0fcc
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 6 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/java-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Build Java packages

on:
push:
branches:
- 'master'
paths-ignore:
- '*.md'
- '.gitignore'
pull_request:
paths-ignore:
- '*.md'
- '.gitignore'

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [macOS-latest, ubuntu-latest]

steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup rtx
uses: jdx/rtx-action@v1
- name: Make Maven Wrapper executable
if: contains(matrix.os, 'win') == false
run: chmod +x mvnw
- name: Package v1
run: ./mvnw --file wgtwo/pom-v1.xml package
- name: Package v0
run: ./mvnw --file wgtwo/pom-v0.xml package
3 changes: 3 additions & 0 deletions .rtx.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[tools]
java = "corretto-21"
buf = "latest"
13 changes: 7 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,16 @@ We do include generated go code as part of this repo, which is generated by Buf

1. `buf generate`

## Buf and other required tooling
## Required tooling

Building the FileDescriptorSet and Go code requires some tooling:
1. Building image.bin and generating go code requires [buf](https://docs.buf.build/installation).
2. Building the Java code requires a compatible Java version

1. `buf` (https://docs.buf.build/installation)
2. `protoc-gen-go` (https://pkg.go.dev/google.golang.org/protobuf)
2. `protoc-gen-go-grpc` (https://pkg.go.dev/google.golang.org/grpc/cmd/protoc-gen-go-grpc)
### `rtx`

We have [Hermit](https://github.com/cashapp/hermit) support, which will provide the required packages.
We do recommend using [rtx](https://github.com/jdx/rtx) for managing these dependencies.

If `rtx` is installed, the required tooling should be automatically picked up from [.rtx.toml](.rtx.toml).

## NPM package

Expand Down

0 comments on commit 10b0fcc

Please sign in to comment.