macOS
brew install yamlfmtlocal Homebrew formula metadata
安装
brew install yamlfmtlocal Homebrew formula metadata
sudo apk add yamlfmtAlpine Linux edge package indexes · yamlfmt · 来源: dl-cdn.alpinelinux.org
nix profile install nixpkgs#yamlfmtnixpkgs package indexes · pkgs/by-name/ya/yamlfmt/package.nix · 来源: api.github.com
sudo pacman -S yamlfmtArch Linux sync databases · yamlfmt · 来源: geo.mirror.pkgbuild.com
scoop install main/yamlfmtScoop official bucket manifest trees · bucket/yamlfmt.json · 来源: api.github.com
概览
Extensible command-line tool to format YAML files
历史
Google yamlfmt is a Go command-line formatter and library for YAML files. Its goals are explicit: be easy to distribute as a single binary, be extensible with custom formatters, and be usable as a library foundation for teams that need a customized YAML formatter.
The repository was created on 2022-08-10. The README describes the project as an extensible formatter rather than only a fixed style tool: users can run the `yamlfmt` command, install it as a pre-commit hook, use a container image, or build on the library APIs.
The project grew around formatter backends and configuration. The default `basic` formatter serializes YAML through a fork of gopkg.in/yaml.v3, while the `kyaml` formatter targets Kubernetes YAML style. The docs also record caveats around YAML directives, anchors, aliases, line breaks, and line-length behavior, showing the practical complexity behind YAML formatting.
yamlfmt has a broad package-manager footprint in the supplied data, including Homebrew, Nix, apk, pacman, and Scoop. Its README also presents Go installation, release binaries, pre-commit integration, and a container image, which fits modern developer-tool adoption through local hooks and CI checks.
The repository lives under the Google organization but the README states that it is not officially supported by Google and is maintained primarily by an individual maintainer in spare time. That makes it an interesting case where a high-visibility org namespace helped adoption of a still-community-paced developer tool.
Basic usage is `yamlfmt x.yaml y.yaml ...` or `yamlfmt .`, where directories are searched recursively for `.yaml` and `.yml` files. The `-dstar` mode enables doublestar glob matching, and `-lint` supports CI workflows that check formatting without rewriting files.
Configuration is discovered from a `-conf` flag, the working directory, ancestor directories, or a system config directory. Supported config filenames include `.yamlfmt`, `yamlfmt.yml`, `yamlfmt.yaml`, `.yamlfmt.yaml`, and `.yamlfmt.yml`.
yamlfmt is package-nerd significant because it packages the messy YAML-formatting problem as a distributable Go binary with docs for hooks, containers, global config, and release artifact verification.
It also represents the split in YAML tooling between generic style normalization and domain-specific formats such as Kubernetes KYAML, a distinction that matters to maintainers choosing formatter defaults for large repositories.
安全态势
narrow executable package without higher-risk signals.
绿色 风险 · 低 置信度 · appliance
在无人值守的代理使用前,请检查该工具是否读取明文凭据、写入远程状态、发布制品或调用插件。
local files
These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.
Config paths the tool may read or write during local use.
.yamlfmtyamlfmt.ymlyamlfmt.yaml.yamlfmt.yaml.yamlfmt.yml$XDG_CONFIG_HOME/yamlfmt/.yamlfmt~/.config/yamlfmt/.yamlfmt%LOCALAPPDATA%\yamlfmt\.yamlfmt可执行文件
| 命令 | 类型 | 暴露范围 | 备注 |
|---|---|---|---|
yamlfmt | 可执行文件 | 已索引可执行文件 | 从本地可执行文件索引发现。 |
新鲜度
这些信号区分页生成时间、软件包管理器活动和上游发布比较。只有存在证据 URL 和可比较版本时,才会提示版本落后。
安装元数据
| 软件包键 | brew:yamlfmt |
|---|---|
| 版本 | 0.21.0 |
| 软件包管理器 | Homebrew |
| 主页 | https://github.com/google/yamlfmt |
| 仓库 | https://github.com/google/yamlfmt |
| 最后更新 | 2026-07-25T21:32:48+02:00 |
| Pulse | updated |
| Bottle | 未记录 |
| 服务 | 未声明 |
源数据库匹配
匹配项来自外部软件包管理器索引,并与本地 Automic Vault 软件包链接分开显示。
yamlfmt
nix profile install nixpkgs#yamlfmtyamlfmt 0.21.0-r6
An extensible command line tool or library to format yaml files
https://github.com/google/yamlfmt
sudo apk add yamlfmtyamlfmt-doc 0.21.0-r6
An extensible command line tool or library to format yaml files (documentation)
https://github.com/google/yamlfmt
sudo apk add yamlfmt-docyamlfmt 0.21.0-1
An extensible command line tool or library to format yaml files.
https://github.com/google/yamlfmt
sudo pacman -S yamlfmtmain/yamlfmt
scoop install main/yamlfmt来源线索
此页面由 av-web 从 scripts/generate-pkg-sqlite.py 生成的私有软件包 SQLite 工件提供。
View the package source record on GitHub.