An open API service indexing awesome lists of open source software.

https://github.com/zig-o11y/opentelemetry-proto

Zig type definitions generated from https://github.com/open-telemetry/opentelemetry-proto
https://github.com/zig-o11y/opentelemetry-proto

opentelemetry protobuf zig zig-package

Last synced: about 1 month ago
JSON representation

Zig type definitions generated from https://github.com/open-telemetry/opentelemetry-proto

Awesome Lists containing this project

README

          

## OpenTelemetry Protobuf Zig

[OpenTelemetry Protobuf definitions](https://github.com/open-telemetry/opentelemetry-proto) packaged for Zig.

---

This repository checks out the official OpenTelemetry Protobuf definitions in a submodule and contains a Zig build to expose the generated Zig code as a package.

### Import the package

The following command will checkout the latest avaiable commit on `main`, which _should_ also be the latest tagged version.

```bash
zig fetch --save "git+https://github.com/zig-o11y/opentelemetry-proto"
```

To specify a tag, add the ref (e.g. `v1.6.0` tag).

```bash
zig fetch --save "git+https://github.com/zig-o11y/opentelemetry-proto#v1.6.0"
```

Tags in this repository will mirror the tags in the OpenTelemetry official repository.

### Generate the code for a new release

When a new tag is added in the upstream repository, there is a build step we can use to update the generated code.
Pick a tag from the upstream repo, say , and run:

```zig
zig build update-tag -Dtag=
```

### Dependencies

The marvellous [`zig-protobuf`](https://github.com/Arwalk/zig-protobuf/) library from @Arwalk.