Skip to content

zig-o11y/opentelemetry-proto

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenTelemetry Protobuf Zig

OpenTelemetry Protobuf definitions 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.

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

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

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 <vX.Y.Z>, and run:

zig build update-tag -Dtag=<vX.Y.Z>

Dependencies

The marvellous zig-protobuf library from @Arwalk.