MCPcopy Index your code
hub / github.com/archlinux/alpm

github.com/archlinux/alpm @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
2,252 symbols 5,419 edges 297 files 993 documented · 44%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

ALPM

This project comprises specifications, as well as Rust libraries and tools for Arch Linux Package Management.

The ALPM project arose from the need for more clearly specifying the interfaces, as well as providing bindings and tools in a memory-safe programming language. The specifications and implementations are based on ad-hoc implementations in the pacman project. Currently, this project aims to maintain compatibility with pacman 5.1.0 and onwards.

The scope of this project is to provide robust integration for all relevant package creation and consumption, as well as repository management tasks. As such, the ALPM project also aims at providing drop-in replacements or alternatives for some facilities provided by pacman.

This project has been financed by the Sovereign Tech Agency. Read the official announcement for more information.

Documentation

The latest project documentation can be found at https://alpm.archlinux.page

Documentation for all current ALPM lints is available at https://alpm.archlinux.page/lints/

Overview

The following mindmap attempts to provide a high-level overview of the project and put file types as well as (existing and upcoming) libraries into context.

mindmap
  root((ALPM))
    📂 Source
      📄 PKGBUILD
      📄 .SRCINFO
      📚️ alpm-pkgbuild
      ⌨️/📚️ alpm-srcinfo
    📦 Package
      📄 .BUILDINFO
      📄 .INSTALL
      📄 .MTREE
      📄 .PKGINFO
      ⌨️/📚️ alpm-buildinfo
      ⌨️/📚️ alpm-mtree
      📚️ alpm-package
      ⌨️/📚️ alpm-pkginfo
      ⌨️/📚️ alpm-soname
    🗄️ Repository
      📄 desc
      📄 files
      ⌨️/📚️ alpm-repo-db
    🗄️ Package Management
      📄 desc
      📄 files
      ⌨️/📚️ alpm-db
    ✅️ Linting
      ⌨️/📚️ alpm-lint
    💬 Language bindings
      🐍 python-alpm
    🛠️ Utils
      📚️ alpm-common
      📚️ alpm-compress
      📚️ alpm-parsers

For an overview of planned specifications and components, refer to the milestones of the project.

Components

Currently the following software components are available:

Contributing

Please refer to the contribution guidelines to learn how to contribute to this project.

Releases

Releases of components are created by the developers of this project.

OpenPGP certificates with the following OpenPGP fingerprints can be used to verify signed tags:

Some of the above are part of archlinux-keyring and certified by at least three main signing keys of the distribution.

License

This project can be used under the terms of the Apache-2.0 or MIT. Contributions to this project, unless noted otherwise, are automatically licensed under the terms of both of those licenses.

Extension points exported contracts — how you extend this code

MetadataFile (Interface)
A trait for metadata files. Metadata files are expected to adhere to a [`FileFormatSchema`] that is encoded in them (pu [8 …
alpm-common/src/traits/metadata_file.rs
LintRule (Interface)
The trait definition and behavioral description of a lint rule. This trait must be implemented by every available lint. [9 …
alpm-lint/src/rule.rs
DigestString (Interface)
[`Digest`] extension providing a [`Self::ENCODING`] constant defining the string representation of the digest used for p [8 …
alpm-types/src/checksum.rs
FileFormatSchema (Interface)
A trait for file format schemas and their versioning. File formats are expected to either expose the schema version dir [8 …
alpm-common/src/traits/schema.rs
EditDistance (Interface)
Trait for calculating edit distance between two types. [3 implementers]
alpm-lint/src/utils.rs
FromOffsetDateTime (Interface)
A trait for allowing conversion from an [`OffsetDateTime`] to a type. [1 implementers]
alpm-types/src/date.rs

Core symbols most depended-on inside this repo

from_str
called by 317
alpm-parsers/src/custom_ini/de.rs
join
called by 236
alpm-package/src/input.rs
path
called by 145
alpm-common/src/package/input.rs
from_str
called by 88
python-alpm/src/types/system.rs
parse
called by 87
alpm-types/src/version/comparison.rs
to_path_buf
called by 65
alpm-package/src/input.rs
is_empty
called by 62
alpm-types/src/pkg.rs
value
called by 54
alpm-types/src/pkg.rs

Shape

Function 941
Method 932
Class 196
Enum 173
Interface 6
Route 4

Languages

Rust87%
Python12%
TypeScript1%
C1%

Modules by API surface

python-alpm/src/srcinfo/source_info/v1/package_base.rs66 symbols
python-alpm/tests/types/test_version.py47 symbols
alpm-package/src/package.rs45 symbols
python-alpm/src/srcinfo/source_info/v1/package.rs41 symbols
python-alpm/tests/srcinfo/test_package_base.py38 symbols
alpm-parsers/src/custom_ini/de.rs36 symbols
alpm-lint/src/lint_rules/store.rs36 symbols
python-alpm/src/srcinfo/source_info/v1/merged.rs35 symbols
python-alpm/tests/types/test_system.py34 symbols
python-alpm/tests/srcinfo/test_package.py34 symbols
alpm-types/src/checksum.rs33 symbols
alpm-package/src/input.rs31 symbols

For agents

$ claude mcp add alpm \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact