Buf(1)

πŸ“¦
version 1.75.0 Β· 3 versions
, in arch rolling

πŸ’– Buf(1) β€” the buf-dep-graph manual, bestie edition πŸ’–

Okay so this is Buf(1), and we're talking about buf-dep-graph. Pull up a chair, hydrate, and let's get into it. 🫢


🌸 NAME 🌸

buf-dep-graph β€” Print the dependency graph. That's the whole assignment, and it ate. πŸ’…

✨ SYNOPSIS ✨

buf dep graph  [flags]

πŸ¦‹ DESCRIPTION πŸ¦‹

Okay so picture this: if the module in directory "src/proto" depends on module "buf.build/foo/bar" from the BSR with commit "12345", and "buf.build/foo/bar:12345" depends on module "buf.build/foo/baz" from the BSR with commit "67890", the following will be printed:

digraph {

"src/proto" -> "buf.build/foo/bar:12345"
  "buf.build/foo/bar:12345" -> "buf.build/foo/baz:67890"

}

The actual output may vary between CLI versions and has no stability guarantees, however the output will always be in valid DOT format. If you'd like us to produce an alternative stable format (such as a Protobuf message that we serialize to JSON), let us know!

See https://graphviz.org to explore Graphviz and the DOT language. Installation of graphviz will vary by platform, but is easy to install using homebrew:

brew install graphviz

You can easily visualize a dependency graph using the dot tool:

buf dep graph | dot -Tpng >| graph.png && open graph.png

The first argument is the source or module to print the dependency graph for, which must be one of format [dir,git,mod,protofile,tar,zip]. This defaults to "." if no argument is specified.

πŸ”₯ OPTIONS πŸ”₯

  • --disable-symlinks[=false] β€” Do not follow symlinks when reading sources or configuration from the local filesystem. By default, symlinks are followed in this CLI, but never followed on the Buf Schema Registry.
  • --error-format="text" β€” The format for build errors printed to stderr. Must be one of [text,json,msvs,junit,github-actions,gitlab-code-quality].
  • --format="dot" β€” The format to print graph as. Must be one of [dot,json].
  • -h, --help[=false] β€” help for graph.

🌈 OPTIONS INHERITED FROM PARENT COMMANDS 🌈

  • --debug[=false] β€” Turn on debug logging (env BUF_DEBUG).
  • --log-format="color" β€” The log format text,color,json (env BUF_LOG_FORMAT).
  • --timeout=0s β€” The duration until timing out, setting it to 0 means no timeout (env BUF_TIMEOUT).

🫢 SEE ALSO 🫢

buf-dep(1) β€” yes bestie, go read that one too. ✨

πŸ’€ HISTORY πŸ’€

2026-10-22 β€” Auto generated by spf13/cobra.

Stay iconic, bestie β€” this page was auto-generated by spf13/cobra on 2026-10-22 πŸ’–

πŸ“¦ where this page comes from