# swift-format を Homebrew でインストール

swift-format のインストール経路、実行ファイル、メタデータ、AI エージェント向けセキュリティノートを確認します。

## インストール

```sh
sudo av install brew:swift-format
```

追加のインストールコマンド:

### macOS

- Homebrew (100%):

```sh
brew install swift-format
```

  証拠: local Homebrew formula metadata

## パッケージ情報

- **パッケージキー:** brew:swift-format
- **パッケージマネージャ:** Homebrew
- **パッケージマネージャページ:** <https://formulae.brew.sh/formula/swift-format>
- **バージョン:** 603.0.0
- **ソース概要:** Formatting technology for Swift source code
- **ホームページ:** <https://github.com/swiftlang/swift-format>
- **リポジトリ:** <https://github.com/swiftlang/swift-format>
- **ライセンス:** Apache-2.0
- **ソースアーカイブ:** <https://github.com/swiftlang/swift-format.git>
- **最終更新:** 2026-07-01T13:43:35Z
- **生成日時:** 2026-08-04T22:13:35+00:00

## 実行可能ファイル

- swift-format (cli)
- swift-format (エイリアス)

## インストール挙動

- post-install フック: 未定義
- Bottle: 利用可能 対象 arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## バージョンと鮮度

- ページ生成日: 2026-08-04
- マネージャ版: 603.0.0
- マネージャ更新日: 2026-07-01
- ローカルデータ: OK
- 上流リポジトリ: https://github.com/swiftlang/swift-format
- 情報: No cached GitHub release or tag data was available.
## プロジェクトの歴史と使われ方

swift-format is the Swift project's formatter and linting technology for Swift source code. It is distributed as a command-line tool and as a Swift Package Manager dependency, making it part of both day-to-day CLI workflows and editor/build-tool integrations.

### プロジェクトの歴史

In February 2019, a Swift Forums pitch proposed that the Swift project adopt an official style guide and provide a formatting tool. The proposal described work on a swift-format tool and framed formatting as a way to reduce project-by-project style churn in the Swift ecosystem.

### 採用の歴史

The official repository now describes swift-format as providing formatting technology for SourceKit-LSP and building blocks for code-formatting transformations. It also notes that the package can be used either as a command-line tool or linked into other applications through Swift Package Manager.

### 使われ方

CLI users run swift-format to check, lint, or rewrite Swift files, with project settings stored in a .swift-format file. Version matching matters: the README documents how Swift 5.8 and later changed swift-format's dependency relationship with SwiftSyntax after the parser was rewritten in Swift.

### パッケージ好きにとっての重要性

swift-format matters to package nerds because it sits at the intersection of language tooling, source formatting policy, and compiler-parser versioning. Packaging it is not just about shipping an executable; maintainers also need to track SwiftSyntax and Swift toolchain compatibility so formatter behavior matches the language users are writing.

### タイムライン

- 2019: Swift Forums pitch proposes an official Swift style guide and formatter.
- 2019: Swift Evolution discussion of SE-0250 documents .swift-format configuration lookup behavior.
- Swift 5.8 era: README documents the SwiftSyntax parser rewrite and new version-numbering alignment.
- Current: Repository describes swift-format as used by SourceKit-LSP and usable as both CLI and package dependency.

### Related projects

- SwiftSyntax provides syntax-tree infrastructure used by swift-format.
- SourceKit-LSP uses swift-format formatting technology.
- Swift Package Manager is a distribution and embedding route for the formatter.

### ソース

- <https://forums.swift.org/t/pitch-an-official-style-guide-and-formatter-for-swift/21025>
- <https://forums.swift.org/t/se-0250-swift-code-style-guidelines-and-formatter/21795>
- <https://github.com/swiftlang/swift-format>


## セキュリティノート

narrow executable package without higher-risk signals.

- **Geiger リスク:** グリーン / 低
- narrow executable package without higher-risk signals


## Configuration and credential file locations

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.


## Configuration files

- Unix: .swift-format
## ソースデータベース詳細

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** swift-format
- **Version Scheme:** 1
- **Revision:** 0
- **Head Version:** HEAD
- **Requirements:** xcode
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable


## 関連リンク

- [Source-control packages](https://pkg.so/ja/source-control-tools/) - Belongs to a source-control command family.
- [Terminal utility packages](https://pkg.so/ja/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://pkg.so/ja/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Developer build packages](https://pkg.so/ja/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [xcbeautify](https://pkg.so/ja/brew/xcbeautify/) - Shares pkgdb curated category or tags: cli, developer-tools, formatter, swift.
- [swiftformat](https://pkg.so/ja/brew/swiftformat/) - Shares pkgdb curated category or tags: cli, developer-tools, formatter, swift.
- [buildifier](https://pkg.so/ja/brew/buildifier/) - Shares pkgdb curated category or tags: cli, developer-tools, formatter, linting.
- [dfmt](https://pkg.so/ja/brew/dfmt/) - Shares pkgdb curated category or tags: cli, developer-tools, formatter, source-code.
- [fprettify](https://pkg.so/ja/brew/fprettify/) - Shares pkgdb curated category or tags: cli, developer-tools, formatter, source-code.
- [findent](https://pkg.so/ja/brew/findent/) - Shares pkgdb curated category or tags: cli, developer-tools, formatter, source-code.
- [fourmolu](https://pkg.so/ja/brew/fourmolu/) - Shares pkgdb curated category or tags: cli, developer-tools, formatter, source-code.
- [fnlfmt](https://pkg.so/ja/brew/fnlfmt/) - Shares pkgdb curated category or tags: cli, developer-tools, formatter, source-code.
- [scalariform](https://pkg.so/ja/brew/scalariform/) - Local package facts share a topical domain. Shared terms: cli, code, developer, developer-tools, formatter.
- [swift-protobuf](https://pkg.so/ja/brew/swift-protobuf/) - Package names and metadata indicate a similar tool family. Shared terms: cli, code, developer, developer-tools, swift.

## Combined YAML source

View the package source record on GitHub. [combined/swift-format.yml](https://github.com/mxcl/pkgdb/blob/main/combined/swift-format.yml)


## ソース

- pkg.so package database
- Geiger risk classifier
- package-page enrichment
- curated configuration and credential file locations
- curated package history
- package version freshness
- pkgdb category and tag curation
- package relationship graph
- cross-ecosystem install command graph
