macOS
brew install peglocal Homebrew formula metadata
sudo port install pegMacPorts ports tree · devel/peg/Portfile · ソース: api.github.com
brew
peg のインストール経路、実行ファイル、メタデータ、AI エージェント向けセキュリティノートを確認します。
インストール
brew install peglocal Homebrew formula metadata
sudo port install pegMacPorts ports tree · devel/peg/Portfile · ソース: api.github.com
sudo apk add pegAlpine Linux edge package indexes · peg · ソース: dl-cdn.alpinelinux.org
nix profile install nixpkgs#pegnixpkgs package indexes · pkgs/by-name/pe/peg/package.nix · ソース: api.github.com
sudo pacman -S pegArch Linux sync databases · peg · ソース: geo.mirror.pkgbuild.com
sudo zypper install pegopenSUSE Tumbleweed package metadata · peg · ソース: download.opensuse.org
概要
Program to perform pattern matching on text
履歴
peg and leg are recursive-descent parser generators for C. They process Parsing Expression Grammars and generate C parsers, with `peg` following Bryan Ford's original PEG syntax and `leg` using conventions intended as an alternative to lex and yacc.
Ian Piumarta's official page lists peg/leg as tools for generating recursive-descent parsers from Parsing Expression Grammars. The first public release in the official version history is 0.1.1 on 2007-05-15.
The manual page explains that peg reads grammar files or standard input and generates C source defining `yyparse()`, while leg uses a syntax intended to make it attractive to users familiar with lex and yacc workflows.
The official version history shows steady maintenance through 0.1.19 stable in 2023, including reentrant parsing support, error actions, UTF-8 fixes, C++ support improvements, and Windows/Mac build files.
peg/leg spread through Unix-like package managers as a small C parser-generation tool: the input metadata lists Homebrew, Debian, Ubuntu, Arch, MacPorts, Nix, Alpine, and openSUSE package names.
Its niche is smaller than yacc-family tools, but it remains useful where a project wants PEG-style ordered choice, unlimited backtracking, and combined scanning and parsing in generated C.
Typical use is to run `peg` or `leg` over a grammar file and compile or include the generated C source in a client program.
The official manual documents options such as `-o` for output file selection, `-P` for suppressing `#line` directives, `-v` for verbose mode, and `-V` for version output.
peg/leg is package-manager-friendly because it is a compact C command-line tool with a stable manual page, source tarballs, and a long version history.
For package nerds it is also a useful contrast with lex/yacc: a small PEG-based generator that produces embeddable C parsers without requiring a larger parser framework.
セキュリティ状態
narrow executable package without higher-risk signals.
リスク グリーン · 信頼度 低 · appliance
エージェントに無人実行させる前に、このツールが平文の認証情報を読むか、リモート状態を書き込むか、成果物を公開するか、プラグインを起動するかを確認してください。
実行可能ファイル
| コマンド | 種類 | 公開範囲 | メモ |
|---|---|---|---|
leg | cli | グローバル実行可能ファイル | |
peg | cli | グローバル実行可能ファイル |
鮮度
これらの信号は、ページ生成時期、パッケージマネージャの活動、上流リリース比較を分けて示します。バージョン遅れは、証拠 URL と比較可能なバージョンがある場合だけ警告されます。
https://www.piumarta.com/software/peg/
インストールメタデータ
| パッケージキー | brew:peg |
|---|---|
| バージョン | 0.1.19 |
| パッケージマネージャ | Homebrew |
| パッケージマネージャページ | https://formulae.brew.sh/formula/peg |
| ホームページ | https://www.piumarta.com/software/peg/ |
| 上流ドキュメント | https://www.piumarta.com/software/peg |
| ライセンス | MIT |
| ソースアーカイブ | https://www.piumarta.com/software/peg/peg-0.1.19.tar.gz |
| 最終更新 | 2026-06-14T14:47:59+02:00 |
| Pulse | updated |
| Bottle | 利用可能 (対象 arm64_linux, arm64_monterey, arm64_sequoia, arm64_sonoma, arm64_tahoe, arm64_ventura, monterey, sonoma, ventura, x86_64_linux) |
| Homebrew post-install | 未定義 |
| サービス | 宣言なし |
レジストリ情報
| Source Database | Homebrew formula API |
|---|---|
| Tap | homebrew/core |
| Full Name | peg |
| Aliases |
|
| Version Scheme | 0 |
| Revision | 0 |
| Bottle Stable Root URL | https://ghcr.io/v2/homebrew/core |
| Deprecated | no |
| Disabled | no |
| Keg Only | no |
| URL Keys |
|
ソースデータベース一致
一致は外部パッケージマネージャインデックスから取得され、ローカルの Automic Vault パッケージリンクとは分けて表示されます。
peg 0.1.20+really0.1.18-1
recursive-descent parser generators for C
https://piumarta.com/software/peg/
sudo apt install pegpeg
nix profile install nixpkgs#pegpeg 0.1.18-1build1
recursive-descent parser generators for C
http://piumarta.com/software/peg/
sudo apt install pegpeg 0.1.18-r1
Recursive-descent parser generators for C
https://www.piumarta.com/software/peg/
sudo apk add pegpeg-doc 0.1.18-r1
Recursive-descent parser generators for C (documentation)
https://www.piumarta.com/software/peg/
sudo apk add peg-docpeg 0.1.19-1
recursive-descent parser generators for C
http://piumarta.com/software/peg/
sudo pacman -S pegpeg 0.1.20-1.7
Recursive-Descent parser generators for C
https://piumarta.com/software/peg/
sudo zypper install pegpeg
sudo port install pegソース経路
このページは scripts/generate-pkg-sqlite.py が生成した非公開のパッケージ SQLite アーティファクトから av-web によって提供されます。
View the package source record on GitHub.