carto is a system package cartographer.
Go to file
Russell 3c9602bdd3 Added support for flatpak 2025-07-28 17:00:22 +00:00
src Added support for flatpak 2025-07-28 17:00:22 +00:00
.gitignore This works so far 2025-07-28 16:47:52 +00:00
Cargo.lock This works so far 2025-07-28 16:47:52 +00:00
Cargo.toml This works so far 2025-07-28 16:47:52 +00:00
justfile This works so far 2025-07-28 16:47:52 +00:00
readme.md Added readme 2025-07-28 16:49:22 +00:00

readme.md

WHERE - Universal System File and Package Mapper

A command-line tool that provides comprehensive observability into your Linux system's package installations and file ownership. Built in Rust for performance and reliability.

Features

  • Universal Package Manager Support - Works with DNF, APT, Flatpak, Snap, and more
  • File Ownership Tracking - Instantly identify which package owns any file
  • Package Tree Visualization - See all files installed by a package in tree format
  • Cross-Distribution Compatibility - Single tool that works across Linux distributions
  • High Performance - Memory-mapped binary format for fast queries

Installation

git clone <repository-url>
cd where
cargo build --release

Usage

Show Package File Tree

Display all files installed by a specific package in a hierarchical tree structure:

# Show files installed by bash package
cargo run -- tree --package bash

# Show trees for first 5 packages (demo mode)
cargo run -- tree

Package Information

Get detailed information about a specific package:

# Show package details and file tree
cargo run -- package bash

File Ownership

Find out which package owns a specific file:

# Check who owns /usr/bin/bash
cargo run -- file /usr/bin/bash

List All Packages

Display all installed packages:

# List all packages
cargo run -- packages

Find Files

Search for files within packages:

# Find all files in bash package
cargo run -- find --package bash

Example Output

Package Tree

bash 5.2.15-6.fc41
├── usr/
│   ├── bin/
│   │   └── bash
│   └── share/
│       ├── doc/
│       │   └── bash/
│       │       ├── CHANGES
│       │       ├── README
│       │       └── NEWS
│       └── man/
│           └── man1/
│               └── bash.1.gz
└── etc/
    └── skel/
        └── .bashrc

File Ownership

/usr/bin/bash is owned by package: bash

Architecture

The tool is designed with a modular architecture supporting multiple package managers:

  • Package Manager Abstraction - Common interface for all package managers
  • Binary Database Format - High-performance storage for file metadata
  • CLI Interface - Clean command-line interface built with Clap
  • Tree Visualization - Hierarchical display of package contents

Supported Package Managers

  • DNF/RPM (Fedora, RHEL, CentOS)
  • 🚧 APT (Debian, Ubuntu) - Coming Soon
  • 🚧 Flatpak - Coming Soon
  • 🚧 Snap - Coming Soon
  • 🚧 Pacman (Arch Linux) - Coming Soon

Development Philosophy

This tool is part of the IntentOS project, focused on creating systems where every component has clear provenance and purpose. The core principle is "know where everything is" - eliminating the entropy and "shrapnel" that accumulates in traditional Linux installations.

Contributing

Built with Rust 2021 edition. Key dependencies:

  • clap - Command line argument parsing
  • memmap2 - Memory-mapped file access
  • chrono - Date/time handling

License

[Add your license here]

Roadmap

  • Complete support for all major package managers
  • Real-time filesystem monitoring
  • Binary database format for fast queries
  • GUI interface
  • Integration with IntentOS package manager
  • Package installation profiles
  • System entropy analysis tools

WHERE gives you complete visibility into your system's package installations - because you should know where everything comes from.