# swiftlint を Homebrew, dnf, MacPorts, Nix でインストール

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

## インストール

```sh
sudo av install brew:swiftlint
```

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

### macOS

- Homebrew (100%):

```sh
brew install swiftlint
```

  証拠: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install swiftlint
```

  証拠: MacPorts ports tree: devel/swiftlint/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- dnf (92%):

```sh
sudo dnf install swiftlint
```

  証拠: Fedora Rawhide package metadata: swiftlint from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#swiftlint
```

  証拠: nixpkgs package indexes: pkgs/by-name/sw/swiftlint/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

## パッケージ情報

- **パッケージキー:** brew:swiftlint
- **パッケージマネージャ:** Homebrew
- **バージョン:** 0.65.0
- **ソース概要:** Tool to enforce Swift style and conventions
- **ホームページ:** <https://github.com/realm/SwiftLint>
- **リポジトリ:** <https://github.com/realm/SwiftLint>
- **最終更新:** 2026-06-27T09:34:51Z
- **生成日時:** 2026-08-03T19:37:03+00:00

## 実行可能ファイル

- swiftlint (エイリアス)

## インストール挙動

- Bottle: 利用不可

## バージョンと鮮度

- ページ生成日: 2026-08-03
- マネージャ版: 0.65.0
## プロジェクトの歴史と使われ方

SwiftLint is a Swift style and convention linter originally published by Realm. It became one of the default package-manager-installed tools in Swift projects because it gives teams a shared command-line style gate for local development, Xcode, SwiftPM, Bazel, CocoaPods, Mint, and CI.

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

The SwiftLint repository was created in May 2015. The README describes the tool as loosely based on the archived GitHub Swift Style Guide and aligned with rules generally accepted by the Swift community.

As Swift tooling matured, SwiftLint moved from simple command-line linting into several build-system surfaces. Its README now documents Swift Package command and build-tool plugins, Xcode package integration, Homebrew, CocoaPods, Mint, Bazel, prebuilt packages, and source builds.

### 採用の歴史

SwiftLint's adoption follows the rise of Swift as a production language: teams needed automated style checks that could run before code review and inside Xcode builds. The official README includes a 2017 video introduction by JP Simard, showing that the project had already become notable in the Swift community by then.

The input package facts show broad packaging beyond Homebrew, including DNF, MacPorts, and Nix. That cross-manager presence is unusual for a Swift-specific CLI and signals sustained use outside one local macOS setup.

### 使われ方

Common usage is `swiftlint` in a project directory, usually governed by `.swiftlint.yml`. The README emphasizes that SwiftLint analyzes valid, compilable Swift source, which is why teams often place it after or alongside normal build steps rather than as a substitute compiler.

Modern usage includes SwiftPM plugins and Bazel targets as well as traditional Homebrew-installed binaries called from Xcode script phases.

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

SwiftLint is package-nerd significant because it packages a moving style rule set as a reproducible CLI. Version pinning matters: rule defaults, SwiftSyntax behavior, and autocorrection can affect source diffs across a whole repository.

It also demonstrates how Swift command-line tools escaped the single-machine Homebrew model and became build plugins, package dependencies, and CI artifacts.

### タイムライン

- 2015: GitHub repository created.
- 2017: Official README links a recorded video introduction.
- 2018: GitHub release metadata includes 0.28.x and 0.29.x releases.
- 2026: GitHub release metadata shows active 0.63.x through 0.65.x maintenance.

### Related projects

- Related projects include SwiftFormat for formatting, SwiftSyntax for rule implementation, SourceKit/Clang for type information, SwiftLintPlugins for SwiftPM plugin consumption, and Bazel rules for build integration.

### ソース

- <https://api.github.com/repos/realm/SwiftLint>
- <https://github.com/realm/SwiftLint#readme>
- <https://realm.github.io/SwiftLint>
- input.source_facts.package-manager


## セキュリティノート

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: .swiftlint.yml
## 他のパッケージマネージャ記録

- Nix - swiftlint: normalized package name match | nixpkgs package indexes: pkgs/by-name/sw/swiftlint/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- dnf - swiftlint - 0.63.0-2.fc45: normalized package name match | Fedora Rawhide package metadata: swiftlint from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Tool to enforce Swift style and conventions | https://realm.github.io/SwiftLint/
- MacPorts - swiftlint: normalized package name match | MacPorts ports tree: devel/swiftlint/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## 関連リンク

- [swiftlint](https://pkg.so/ja/pkg/npm/swiftlint/) - Same normalized package name exists in another local package ecosystem.

## Combined YAML source

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


## ソース

- pkg.so package database
- Geiger risk classifier
- curated configuration and credential file locations
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
