Skip to main content

Crate normalize_manifest

Crate normalize_manifest 

Source
Expand description

Manifest file parsing for programming language ecosystems.

Provides a uniform ParsedManifest type and parsers for common package manifest formats. See docs/manifest-support.md for full coverage status.

§Dispatch

  • parse_manifest(filename, content) — dispatches by exact filename
  • parse_manifest_by_extension(ext, content) — for wildcard-named files (.nimble, .cabal, .csproj, .rockspec)

§Convenience helpers

  • go_module(content) — extract module info from go.mod
  • npm_entry_point(content) — extract entry point from package.json

Re-exports§

pub use go_mod::GoModule;
pub use npm::npm_entry_point;

Modules§

cabal
Parser for *.cabal files (Haskell/Cabal).
cabal_project
Parser for cabal.project files (Haskell/Cabal).
cargo
Parser for Cargo.toml files (Rust/Cargo).
clojure
Parsers for Clojure manifest files.
common_lisp
Parser for *.asd files (Common Lisp/ASDF).
composer
Parser for composer.json files (PHP/Composer).
conan
Parsers for Conan C/C++ package manifests.
crystal
Parser for shard.yml files (Crystal/Shards).
dub
Parsers for Dub package manifests (D language).
dune
Parser for dune-project files (OCaml/Dune).
elm
Parser for elm.json files (Elm package manager).
erlang
Parser for rebar.config files (Erlang/rebar3).
flake
Heuristic parser for flake.nix files (Nix).
fortran_fpm
Parser for fpm.toml files (Fortran Package Manager).
gemfile
Parser for Gemfile files (Ruby/Bundler).
gleam
Parser for gleam.toml files (Gleam package manager).
go_mod
Parser for go.mod files (Go modules).
gradle
Parsers for Gradle build files.
gradle_libs
Parser for gradle/libs.versions.toml files (Gradle version catalog).
julia
Parser for Project.toml files (Julia package manager).
maven
Parser for pom.xml files (Java/Maven).
mix_exs
Parser for mix.exs files (Elixir/Hex).
nimble
Parser for *.nimble files (Nim/Nimble).
npm
Parser for package.json files (npm/Node.js).
nuget
Parsers for NuGet package manifests (.NET).
ocaml
Parser for *.opam files (OCaml/OPAM).
perl
Parser for cpanfile files (Perl/CPAN).
pip
Parser for requirements.txt files (pip).
pipfile
Parser for Pipfile files (Pipenv).
pubspec
Parser for pubspec.yaml files (Dart/Flutter).
purescript
Parser for spago.yaml files (PureScript/Spago).
pyproject
Parser for pyproject.toml files (PEP 621 / Poetry).
r_description
Parser for R DESCRIPTION files (CRAN/DCF format).
racket
Parser for info.rkt files (Racket).
rockspec
Parser for *.rockspec files (Lua/LuaRocks).
sbt
Parser for build.sbt files (Scala/sbt).
setup_cfg
Parser for setup.cfg files (Python / setuptools).
setup_py
Heuristic parser for setup.py files (Python/setuptools).
sexpr
Minimal S-expression parser shared by the Dune, Common Lisp, and Racket manifest parsers.
stack
Parser for stack.yaml files (Haskell/Stack).
swift_pm
Heuristic parser for Package.swift files (Swift Package Manager).
vcpkg
Parser for vcpkg.json files (Microsoft vcpkg C/C++ package manager).
vlang
Parser for v.mod files (V language/vpm).
zig
Parser for build.zig.zon files (Zig).

Structs§

DeclaredDep
A declared dependency extracted from a manifest.
ManifestError
Error returned by manifest parsers.
ParsedManifest
Parsed contents of a project manifest file.

Enums§

DepKind
The kind of dependency relationship.

Traits§

ManifestParser
A parser for a specific manifest file format.

Functions§

go_module
Parse go.mod content to extract module information.
parse_manifest
Parse a manifest file by exact filename, dispatching to the correct parser.
parse_manifest_by_extension
Parse a manifest file whose format is identified by file extension.