Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into mcy/lsp-big-lock
Browse files Browse the repository at this point in the history
  • Loading branch information
mcy committed Oct 8, 2024
2 parents 5df33b5 + 3be1615 commit 153ccd6
Show file tree
Hide file tree
Showing 134 changed files with 1,399 additions and 1,034 deletions.
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@

- No changes yet.

## [v1.45.0] - 2024-10-08

- Update `buf registry module info --format=json` to add `default_label_name`, which provides the name
of the default label of a module.

## [v1.44.0] - 2024-10-03

- Update the `PROTOVALIDATE` lint rule to check example field options. Examples will be checked that
Expand Down Expand Up @@ -1277,7 +1282,8 @@ buf check breaking proto --against .git#branch=master,subdir=proto

Initial beta release.

[Unreleased]: https://github.com/bufbuild/buf/compare/v1.44.0...HEAD
[Unreleased]: https://github.com/bufbuild/buf/compare/v1.45.0...HEAD
[v1.45.0]: https://github.com/bufbuild/buf/compare/v1.44.0...v1.45.0
[v1.44.0]: https://github.com/bufbuild/buf/compare/v1.43.0...v1.44.0
[v1.43.0]: https://github.com/bufbuild/buf/compare/v1.42.0...v1.43.0
[v1.42.0]: https://github.com/bufbuild/buf/compare/v1.41.0...v1.42.0
Expand Down
80 changes: 39 additions & 41 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@
[![Homebrew](https://img.shields.io/homebrew/v/buf)](https://github.com/bufbuild/homebrew-buf)
[![Slack](https://img.shields.io/badge/slack-buf-%23e01563)][badges_slack]

<a name="features"></a>
The [`buf`][buf] CLI is the best tool for working with [Protocol Buffers][protobuf]. It provides:

- A [linter][lint_usage] that enforces good API design choices and structure.
- A [breaking change detector][breaking_usage] that enforces compatibility at the source code or wire level.
- A [breaking change detector][breaking_tutorial] that enforces compatibility at the source code or wire level.
- A [generator][generate_usage] that invokes your plugins based on configurable [templates][templates].
- A [formatter][format_usage] that formats your Protobuf files in accordance with industry standards.
- Integration with the [Buf Schema Registry][bsr], including full dependency management.
Expand Down Expand Up @@ -53,7 +54,7 @@ buf --help

For more comprehensive usage information, consult Buf's [documentation][docs], especially these guides:

* [`buf breaking`][breaking_usage]
* [`buf breaking`][breaking_tutorial]
* [`buf build`][build_usage]
* [`buf generate`][generate_usage]
* [`buf lint`][lint_usage]
Expand All @@ -62,7 +63,7 @@ For more comprehensive usage information, consult Buf's [documentation][docs], e

## CLI breaking change policy

We will never make breaking changes within a given major version of the CLI. Once `buf` reaches v1.0, you can expect no breaking changes until v2.0. But as we have no plans to ever release a v2.0, we will likely never break the `buf` CLI.
We will never make breaking changes within a given major version of the CLI. After `buf` reached v1.0, you can expect no breaking changes until v2.0. But as we have no plans to ever release a v2.0, we will likely never break the `buf` CLI.

> This breaking change policy does _not_ apply to commands behind the `buf beta` gate, and you should expect breaking changes to commands like `buf beta registry`. The policy does go into effect, however, when those commands or flags are elevated out of beta.
Expand All @@ -86,10 +87,10 @@ While `buf`'s [core features][features] should cover most use cases, we've inclu

* **Automatic file discovery**. Buf walks your file tree and builds your `.proto` files in accordance with your supplied [build configuration][build_config], which means that you no longer need to manually specify `--proto_paths`. You can still, however, specify `.proto` files manually through CLI flags in cases where file discovery needs to be disabled.
* **Fine-grained rule configuration** for [linting][lint_rules] and [breaking changes][breaking_rules]. While we do have recommended defaults, you can always select the exact set of rules that your use case requires, with [40 lint rules][lint_rules] and [53 breaking change rules][breaking_rules] available.
* **Configurable error formats** for CLI output. `buf` outputs information in `file:line:column:message` form by default for each lint error and breaking change it encounters, but you can also select JSON and, in the near future, JUnit output.
* **Editor integration** driven by `buf`'s granular error output. We currently provide linting integrations for both [Vim and Visual Studio Code][ide] but we plan to support other editors, such as Emacs and [JetBrains IDEs][jetbrains] like IntelliJ and GoLand, in the future.
* **Configurable error formats** for CLI output. `buf` outputs information in `file:line:column:message` form by default for each lint error and breaking change it encounters, but you can also select JSON, MSVS, JUnit, and Github Actions output.
* **Editor integration** driven by `buf`'s granular error output. We currently provide linting integrations for both [Vim and Visual Studio Code][ide] and [JetBrains IDEs][jetbrains] like IntelliJ and GoLand, but we plan to support other editors such as Emacs in the future.
* **Universal Input targeting**. Buf enables you to perform actions like linting and breaking change detection not just against local `.proto` files but also against a broad range of other [Inputs], such as tarballs and ZIP files, remote Git repositories, and pre-built [image][images] files.
* **Speed**. Buf's internal Protobuf compiler compiles your Protobuf sources using all available cores without compromising deterministic output, which is considerably faster than `protoc`. This allows for near-instantaneous feedback, which is of special importance for features like [editor integration][ide].
* **Speed**. Buf's internal Protobuf [compiler] compiles your Protobuf sources using all available cores without compromising deterministic output, which is considerably faster than `protoc`. This allows for near-instantaneous feedback, which is of special importance for features like [editor integration][ide].

## Next steps

Expand All @@ -107,51 +108,48 @@ For feature requests, bugs, or technical questions, email us at [dev@buf.build][

[badges_slack]: https://buf.build/links/slack
[bash]: https://www.gnu.org/software/bash
[binary]: https://docs.buf.build/installation#binary
[breaking]: https://docs.buf.build/breaking
[breaking_rules]: https://docs.buf.build/breaking/rules
[breaking_usage]: https://docs.buf.build/breaking/usage
[binary]: https://buf.build/docs/installation#binary
[breaking]: https://buf.build/docs/breaking/overview
[breaking_rules]: https://buf.build/docs/breaking/rules
[breaking_tutorial]: https://buf.build/docs/breaking/tutorial
[brew]: https://brew.sh
[bsr]: https://docs.buf.build/bsr
[bsr]: https://buf.build/docs/bsr/introduction
[bsr_plugins]: https://buf.build/plugins
[bsr_usage]: https://docs.buf.build/bsr/usage
[bsr_usage]: https://buf.build/docs/bsr/module/dependency-management
[buf]: https://buf.build
[build_config]: https://docs.buf.build/build/usage/#configuration
[build_usage]: https://docs.buf.build/build/usage
[build_config]: https://buf.build/docs/build/usage/#key-concepts
[build_usage]: https://buf.build/docs/build/usage
[cli-tutorial]: https://buf.build/docs/tutorials/getting-started-with-buf-cli
[compiler]: https://docs.buf.build/build/internal-compiler
[contact]: https://docs.buf.build/contact
[docker]: https://docs.buf.build/installation#use-the-docker-image
[docs]: https://docs.buf.build
[compiler]: https://buf.build/docs/reference/internal-compiler
[docker]: https://buf.build/docs/installation#use-the-docker-image
[docs]: https://buf.build/docs
[email_dev]: mailto:dev@buf.build
[email_info]: mailto:info@buf.build
[filedescriptorset]: https://github.com/protocolbuffers/protobuf/blob/044c766fd4777713fef2d1a9a095e4308d770c68/src/google/protobuf/descriptor.proto#L57
[features]: #features
[fish]: https://fishshell.com
[format_usage]: https://docs.buf.build/format/usage
[generate_usage]: https://docs.buf.build/generate/usage
[ide]: https://docs.buf.build/editor-integration
[format_usage]: https://buf.build/docs/format/style
[generate_usage]: https://buf.build/docs/generate/tutorial
[ide]: https://buf.build/docs/editor-integration
[idl]: https://en.wikipedia.org/wiki/Interface_description_language
[images]: https://docs.buf.build/reference/images
[inputs]: https://docs.buf.build/reference/inputs
[install]: https://docs.buf.build/installation
[jetbrains]: https://docs.buf.build/editor-integration#jetbrains-ides
[lint]: https://docs.buf.build/lint
[lint_rules]: https://docs.buf.build/lint/rules
[lint_usage]: https://docs.buf.build/lint/usage
[npm]: https://docs.buf.build/installation#npm
[images]: https://buf.build/docs/reference/images
[inputs]: https://buf.build/docs/reference/inputs
[install]: https://buf.build/docs/installation
[jetbrains]: https://buf.build/docs/editor-integration#jetbrains-ides
[lint]: https://buf.build/docs/lint/overview
[lint_rules]: https://buf.build/docs/lint/rules
[lint_usage]: https://buf.build/docs/lint/tutorial
[npm]: https://buf.build/docs/installation#npm
[minisign]: https://github.com/jedisct1/minisign
[powershell]: https://docs.microsoft.com/en-us/powershell
[protobuf]: https://developers.google.com/protocol-buffers
[pushing]: https://docs.buf.build/bsr/usage#push-a-module
[releases]: https://docs.buf.build/installation#github-releases
[protobuf]: https://protobuf.dev
[pushing]: https://buf.build/docs/bsr/module/dependency-management#push-a-module
[releases]: https://buf.build/docs/installation#github-releases
[repo]: https://github.com/bufbuild/buf/
[repositories]: https://docs.buf.build/bsr/overview#module
[roadmap]: https://docs.buf.build/roadmap
[source]: https://docs.buf.build/installation#from-source
[tarball]: https://docs.buf.build/installation#tarball
[templates]: https://docs.buf.build/configuration/v1/buf-gen-yaml
[users]: https://docs.buf.build/bsr/user-management#organization-roles
[verifying]: https://docs.buf.build/installation#verifying-a-release
[windows]: https://docs.buf.build/installation#windows-support
[repositories]: https://buf.build/docs/bsr/introduction#module
[source]: https://buf.build/docs/installation#from-source
[tarball]: https://buf.build/docs/installation#tarball
[templates]: https://buf.build/docs/configuration/v1/buf-gen-yaml
[users]: https://buf.build/docs/admin/manage-members
[verifying]: https://buf.build/docs/installation#var-selection-github-verifying-a-release
[windows]: https://buf.build/docs/installation#windows-support
[zsh]: https://zsh.org
30 changes: 15 additions & 15 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ module github.com/bufbuild/buf

go 1.22.0

toolchain go1.23.1
toolchain go1.23.2

require (
buf.build/gen/go/bufbuild/bufplugin/protocolbuffers/go v1.34.2-20240928190436-5e8abcfd7a7e.2
Expand All @@ -16,7 +16,7 @@ require (
connectrpc.com/otelconnect v0.7.1
github.com/bufbuild/protocompile v0.14.1
github.com/bufbuild/protoplugin v0.0.0-20240911180120-7bb73e41a54a
github.com/bufbuild/protovalidate-go v0.7.1
github.com/bufbuild/protovalidate-go v0.7.2
github.com/docker/docker v27.3.1+incompatible
github.com/go-chi/chi/v5 v5.1.0
github.com/gofrs/flock v0.12.1
Expand All @@ -35,19 +35,20 @@ require (
github.com/spf13/cobra v1.8.1
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.9.0
github.com/tetratelabs/wazero v1.8.0
github.com/tetratelabs/wazero v1.8.1
go.lsp.dev/jsonrpc2 v0.10.0
go.lsp.dev/protocol v0.12.0
go.uber.org/atomic v1.11.0
go.uber.org/multierr v1.11.0
go.uber.org/zap v1.27.0
golang.org/x/crypto v0.27.0
golang.org/x/exp v0.0.0-20240909161429-701f63a606c0
go.uber.org/zap/exp v0.1.1-0.20240913022758-ede8e1888f83
golang.org/x/crypto v0.28.0
golang.org/x/exp v0.0.0-20241004190924-225e2abe05e6
golang.org/x/mod v0.21.0
golang.org/x/net v0.29.0
golang.org/x/net v0.30.0
golang.org/x/sync v0.8.0
golang.org/x/term v0.24.0
golang.org/x/tools v0.25.0
golang.org/x/term v0.25.0
golang.org/x/tools v0.26.0
google.golang.org/protobuf v1.34.3-0.20240906163944-03df6c145d96
gopkg.in/yaml.v3 v3.0.1
pluginrpc.com/pluginrpc v0.5.0
Expand Down Expand Up @@ -83,7 +84,7 @@ require (
github.com/go-task/slim-sprig/v3 v3.0.0 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/google/pprof v0.0.0-20240929191954-255acd752d31 // indirect
github.com/google/pprof v0.0.0-20241001023024-f4c0cfd0cf1d // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/mitchellh/go-homedir v1.1.0 // indirect
Expand Down Expand Up @@ -116,12 +117,11 @@ require (
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.55.0 // indirect
go.opentelemetry.io/otel v1.30.0 // indirect
go.opentelemetry.io/otel/metric v1.30.0 // indirect
go.opentelemetry.io/otel/sdk v1.30.0 // indirect
go.opentelemetry.io/otel/trace v1.30.0 // indirect
go.uber.org/mock v0.4.0 // indirect
golang.org/x/sys v0.25.0 // indirect
golang.org/x/text v0.18.0 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240924160255-9d4c2d233b61 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240924160255-9d4c2d233b61 // indirect
google.golang.org/grpc v1.67.0 // indirect
golang.org/x/sys v0.26.0 // indirect
golang.org/x/text v0.19.0 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240930140551-af27646dc61f // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240930140551-af27646dc61f // indirect
google.golang.org/grpc v1.67.1 // indirect
)
Loading

0 comments on commit 153ccd6

Please sign in to comment.