3 unstable releases

0.2.1 Dec 6, 2022
0.2.0 Feb 27, 2022
0.1.0 Feb 13, 2022

#1661 in Command line utilities

Download history 83/week @ 2023-11-20 178/week @ 2023-11-27 41/week @ 2023-12-04 97/week @ 2023-12-11 78/week @ 2023-12-18 38/week @ 2024-01-01 21/week @ 2024-01-08 34/week @ 2024-01-15 71/week @ 2024-01-22 83/week @ 2024-01-29 75/week @ 2024-02-05 82/week @ 2024-02-12 78/week @ 2024-02-19 74/week @ 2024-02-26 121/week @ 2024-03-04

359 downloads per month

MIT license

21KB
472 lines

chmap

chmap is a command line tool to work with Clang headermaps produced by Xcode. It is written in Rust.

chmap is the modern, cross-paltform version of the Swift hmap tool.

How to Get

Requirements

You need a Rust toolchain, see rustup.

Cargo

  1. Clone the repository
  2. If you want to run via cargo, use cargo run -- arguments
  3. If you want to install, cargo install --path chmap

cheadermap Crate

If you would like to use the cheadermap library crate, add the following to your Cargo.toml:

[dependencies]
cheadermap = "0.2.0"

How to Use

To print the contents of an hmap file, execute:

chmap print /path/to/file.hmap

For example, if you have just cloned the repository, execute cargo run -- print /path/to/file.hmap.

Development

Visual Studio Code coupled with the rust-analyzer and CodeLLDB provide a good IDE experience.

rustfmt & clippy

If you don't have rustfmt and clippy, you can install them by executing:

rustup component add rustfmt
rustup component add clippy

Before committing, ensure code is formatted and passes clippy without any warnings using:

cargo fmt --all
cargo clippy

Testing

From the repo root, execute:

cargo test

Dependencies

~0.4–0.9MB
~19K SLoC