macOS
brew install sourcerylocal Homebrew formula metadata
安装
brew install sourcerylocal Homebrew formula metadata
nix profile install nixpkgs#sourcerynixpkgs package indexes · pkgs/by-name/so/sourcery/package.nix · 来源: api.github.com
概览
Meta-programming for Swift, stop writing boilerplate code
历史
Sourcery is a Swift command-line code generator for reducing repetitive source code through templates and annotations. In package-manager culture it is most visible as a developer automation tool installed by Homebrew, CocoaPods, Mint, Swift Package Manager plugins, and pre-commit.
The GitHub repository was created in December 2016 and describes Sourcery as a Swift code generator built on Apple's SwiftSyntax. The project presents its core purpose as extending Swift's language abstractions so teams can generate boilerplate automatically.
The README documents Sourcery as both a standalone command-line executable and an integrated build-tool option. It supports direct binary downloads, Homebrew, CocoaPods, Mint, Swift Package Manager plugin use, and source builds.
The official README states that Sourcery is used in more than 40,000 iOS and macOS projects and names Airbnb, Bumble, and The New York Times as example users. The project also claims that broad community adoption helped influence Apple's later derived Equality and automatic Codable conformance work.
For package users, Sourcery became a familiar Swift ecosystem utility because it can be installed through several package channels while still producing ordinary generated Swift files that fit into Xcode and CI workflows.
Typical CLI usage runs `sourcery --sources <path> --templates <path> --output <path>`, or places options in a `.sourcery.yml` file. The README highlights common templates for equality, hashing, enum cases, mocks and stubs, LinuxMain, decorators, Codable support, and property diffing.
SwiftPM plugin usage is documented separately from the standalone executable: users add Sourcery as a package dependency, place `.sourcery.yml` near the target sources, and run the package plugin with write access enabled.
Sourcery matters to package nerds because it sits at the intersection of source generation, build reproducibility, and Swift package distribution. A formula or package gives teams the same generator binary locally and in CI, making generated-code diffs predictable.
Its presence across Homebrew, CocoaPods, Mint, SwiftPM, and pre-commit also makes it a useful example of a CLI that escaped a single package ecosystem and became part of routine iOS and macOS project automation.
安全态势
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.
.sourcery.yml可执行文件
| 命令 | 类型 | 暴露范围 | 备注 |
|---|---|---|---|
sourcery | cli | 全局可执行文件 |
新鲜度
这些信号区分页生成时间、软件包管理器活动和上游发布比较。只有存在证据 URL 和可比较版本时,才会提示版本落后。
https://github.com/krzysztofzablocki/Sourcery
安装元数据
| 软件包键 | brew:sourcery |
|---|---|
| 版本 | 2.3.0 |
| 软件包管理器 | Homebrew |
| 软件包管理器页面 | https://formulae.brew.sh/formula/sourcery |
| 主页 | https://github.com/krzysztofzablocki/Sourcery |
| 仓库 | https://github.com/krzysztofzablocki/Sourcery |
| 上游文档 | https://github.com/krzysztofzablocki/Sourcery#readme |
| 许可证 | MIT |
| 源码归档 | https://github.com/krzysztofzablocki/Sourcery/archive/refs/tags/2.3.0.tar.gz |
| macOS 提供的库 | curl, libxml2, ncurses, sqlite, swift |
| Bottle | 可用 (于 arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux) |
| Homebrew post-install | 未定义 |
| 服务 | 未声明 |
注册表事实
| Source Database | Homebrew formula API |
|---|---|
| Tap | homebrew/core |
| Full Name | sourcery |
| Version Scheme | 1 |
| Revision | 1 |
| Head Version | HEAD |
| Requirements |
|
| Bottle Stable Root URL | https://ghcr.io/v2/homebrew/core |
| Deprecated | no |
| Disabled | no |
| Keg Only | no |
| URL Keys |
|
源数据库匹配
匹配项来自外部软件包管理器索引,并与本地 Automic Vault 软件包链接分开显示。
sourcery
nix profile install nixpkgs#sourcery来源线索
此页面由 av-web 从 scripts/generate-pkg-sqlite.py 生成的私有软件包 SQLite 工件提供。
View the package source record on GitHub.