MCPcopy Index your code
hub / github.com/AOSC-Dev/oma

github.com/AOSC-Dev/oma @v1.26.6

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.26.6 ↗ · + Follow
973 symbols 2,466 edges 111 files 105 documented · 11%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

oma banner: header

oma - Oh My Ailurus / Package Manager for AOSC OS

Features | Install | Contribute

oma is an attempt at reworking APT's interface, making it more user-friendly, more robust against common user errors, and more performant during package downloads. oma also integrates closely with AOSC OS's various system management functions, from mirror configuration, topic (testing) repository enrollment, to system feature protection.

For a more detailed overview on oma's features, see features.

oma is also available for other dpkg-based OS.

Please see Install.

A simple tour of oma

Features

  • Clear-and-Simple Interface: Colorful and TUI-heavy interface, with clear marking for key information and simplified commands for common operations.
  • Faster Downloads: Faster package downloads, powered by the performant reqwest HTTP and multi-threaded downloads.
  • Smart Search: Leveraging the indicium search engine for more relevant package search results.
  • Fool-Proofing Mechanisms: Protection against system failures through a combination of mechanisms - active prevention against removal of essential packages, clear marking for potentially dangerous operations, and a disaster recovery mechanism through undo command.
  • System Feature Protection: Informing and advising against uninstalling critical system components by detecting System Feature Markers in key component packages (AOSC OS only).
  • System Status Integration: Integration with system daemons, allowing oma to warn against performing package management operations on battery power, as well as actively inhibiting accidental reboots and suspends.
  • Compatibility with Other dpkg-based OS: Bringing a more friendly package management experience to major dpkg-based distributions like Debian, Ubuntu, deepin, and openKylin.
  • Distro-specific Integration: Supporting not only AOSC OS-specific features such as topic repository enrollment and mirror management, but also distro-specific services such as Ubuntu Pro.

Installation

oma is pre-installed with AOSC OS. It is also available for Debian, Ubuntu, Deepin, openKylin, and more dpkg-based OS.

Automatic Installation

curl -sSf https://repo.aosc.io/get-oma.sh | sudo sh

Building from Source

Dependencies

To build oma, ensure the following dependencies are installed:

During runtime, oma requires or recommends the following:

  • ripgrep (optional, accelerates oma provides, oma files, and oma command-not-found)

Build Procedure (Ubuntu/Debian)

  1. Clone the repository:

bash git clone https://github.com/AOSC-Dev/oma.git cd oma

  1. Install build dependencies:

bash apt install build-essential zlib1g-dev libssl-dev pkgconf nettle-dev libapt-pkg-dev curl xz-utils clang libbz2-dev liblzma-dev curl --proto '=https' --tlsv1.2 -sSf https://just.systems/install.sh | bash -s -- --to /usr/local/bin cargo install cargo-deb

  1. Build the binary as an installable .deb package:

bash just deb

  1. Install and profit!

Usage

Entering the interactive package management interface

oma # without arguments

Example Commands

  • Installing a package:

bash oma install <package_name>

  • Searching for a package:

bash oma search <keyword> - Removing a package:

bash oma remove <package_name>

  • Refreshing repository metadata (done automatically before oma install and oma upgrade):

bash oma refresh

For a full list of available sub-commands and arguments, run:

oma help

Command Reference

Command Description
install Install package(s) from the repository
upgrade Upgrade all installed packages
download Download package(s) without installing
remove Remove specified package(s)
refresh Refresh repository metadata
search Search for package(s) in the repository
show Show detailed information for a package
files List files in the specified package
provides Find packages providing specific patterns
fix-broken Fix broken dependencies
pick Install a specific version of package(s)
mark Mark package(s) with a specific status
list List all available packages
depends Show dependencies for package(s)
rdepends Show reverse dependencies for package(s)
clean Clear downloaded package cache
history Show package history or change logs
help Show help of oma or the given subcommand(s)

Contributing

Contributions are welcome!

Please feel free to file issues or pull requests to help improve oma.

Please see CONTRIBUTING for detailed instructions.

License

oma is licensed under the GNU General Public License v3.0. See the COPYING file for details.

oma banner: footer

Extension points exported contracts — how you extend this code

CliExecuter (Interface)
(no doc) [28 implementers]
src/args.rs
InstallProgressManager (Interface)
(no doc) [3 implementers]
oma-pm/src/progress.rs
Writeln (Interface)
(no doc) [3 implementers]
oma-console/src/writer.rs
RenderPackagesDownloadProgress (Interface)
(no doc) [2 implementers]
src/pb.rs
UPower (Interface)
(no doc)
oma-utils/src/dbus/mod.rs
OmaSearch (Interface)
(no doc) [3 implementers]
oma-pm/src/search.rs
PagerUIText (Interface)
(no doc) [2 implementers]
oma-console/src/pager.rs
RenderRefreshProgress (Interface)
(no doc) [2 implementers]
src/pb.rs

Core symbols most depended-on inside this repo

len
called by 100
src/error.rs
filter
called by 45
src/completions.rs
version
called by 45
oma-pm/src/pkginfo.rs
name
called by 41
oma-pm-operation-type/src/lib.rs
no_progress
called by 31
src/config.rs
println
called by 28
src/table.rs
remove
called by 28
oma-pm/src/apt.rs
write_str
called by 27
oma-console/src/terminal.rs

Shape

Method 451
Function 299
Class 143
Enum 68
Interface 12

Languages

Rust100%

Modules by API surface

oma-pm/src/apt.rs46 symbols
oma-refresh/src/sourceslist.rs42 symbols
oma-console/src/pager.rs32 symbols
src/table.rs29 symbols
oma-pm-operation-type/src/lib.rs26 symbols
oma-refresh/src/config.rs24 symbols
oma-pm/src/pkginfo.rs24 symbols
src/pb.rs23 symbols
src/config_file.rs21 symbols
oma-tum/src/lib.rs21 symbols
oma-refresh/src/inrelease.rs21 symbols
oma-console/src/print.rs21 symbols

For agents

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

⬇ download graph artifact

Ask about this repo answers extend the page