Skip to content

Conversation

@doriable
Copy link
Member

@doriable doriable commented Jul 15, 2025

This PR does some simple clean-ups:

  • Separate the protos in this project into different modules
    and adjusts the buf.gen.*yaml files accordingly. It also
    configures the inputs key in the buf.gen.*yaml files, so
    they don't need to be managed in the Makefile.
  • Adds a GitHub Actions workflow for pushing the example
    weather module to the BSR
    .
  • Adjust the README
    • Change the logo reference: this is so that the logo will work
      properly when pushed to the BSR. However, since the repo is
      currently private, the logo 404's. This should be fixed when
      the repo is public.
    • Adjust the examples so that the top-level example is compilable,
      and the subsequent examples are clear function definitions.
    • Extracted the link definitions

A follow-up PR will be made to use generated SDKs for examples.

We skip buf breaking for this PR in buf-action since this PR breaks
the workspace into new modules.

@doriable doriable changed the title Setup buf modules and cleanup Setup buf modules and cleanup README Jul 15, 2025
@github-actions
Copy link

github-actions bot commented Jul 15, 2025

The latest Buf updates on your PR. Results from workflow Buf CI / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed⏩ skipped✅ passed⏩ skippedJul 15, 2025, 10:11 PM

@doriable doriable added the buf skip breaking Used to skip breaking change checks for `buf-action` label Jul 15, 2025
README.md Outdated
)

// Weather data byte slice.
var weatherDataBytes = []byte{0xa, 0x7, 0x53, 0x65, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x12, 0x1d, 0xa, 0x5, 0x4b, 0x41, 0x44, 0x39, 0x33, 0x15, 0x66, 0x86, 0x22, 0x43, 0x1d, 0xcd, 0xcc, 0x34, 0x41, 0x25, 0xd7, 0xa3, 0xf0, 0x41, 0x2d, 0x33, 0x33, 0x13, 0x40, 0x30, 0x3, 0x12, 0x1d, 0xa, 0x5, 0x4b, 0x48, 0x42, 0x36, 0x30, 0x15, 0xcd, 0x8c, 0x22, 0x43, 0x1d, 0x33, 0x33, 0x5b, 0x41, 0x25, 0x52, 0xb8, 0xe0, 0x41, 0x2d, 0x33, 0x33, 0xf3, 0x3f, 0x30, 0x3}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you format this so it doesn't wrap the screen?

README.md Outdated
"google.golang.org/protobuf/proto"

weatherv1 "github.com/..."
weatherv1 "buf.build/go/hyperpb/internal/gen/example/weather/v1"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we use the expected generated SDK URL here?

README.md Outdated
weatherv1 "buf.build/go/hyperpb/internal/gen/example/weather/v1"
)

// Weather data byte slice.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you convert this to JSON and include that in the comment?

our binary, and parse some data with it.

```go
package main
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you make sure these are all synced up w/ example_test.go? Might also be good to include comments on both sides to say that they need to be in sync.

Copy link
Member

@mcy mcy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, some details.

@mcy mcy merged commit 7cb410a into main Jul 15, 2025
8 checks passed
@mcy mcy deleted the setup-buf-modules-and-cleanup branch July 15, 2025 22:14
mcy pushed a commit that referenced this pull request Jul 16, 2025
This is a follow-up to #3 to use generated SDKs for examples.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

buf skip breaking Used to skip breaking change checks for `buf-action`

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants