17 stable releases (5 major)

5.5.0 Jul 3, 2024
5.4.0 Nov 30, 2023
5.0.2 Jun 23, 2023
5.0.1 Mar 23, 2023
0.3.0 Jun 13, 2017

#217 in Development tools

Download history 79/week @ 2024-11-16 315/week @ 2024-11-23 171/week @ 2024-11-30 250/week @ 2024-12-07 170/week @ 2024-12-14 52/week @ 2024-12-21 68/week @ 2024-12-28 238/week @ 2025-01-04 221/week @ 2025-01-11 155/week @ 2025-01-18 60/week @ 2025-01-25 209/week @ 2025-02-01 221/week @ 2025-02-08 388/week @ 2025-02-15 309/week @ 2025-02-22 183/week @ 2025-03-01

1,139 downloads per month
Used in symbolic-proguard

BSD-3-Clause

490KB
2.5K SLoC

Rust Proguard Parser

A simple Rust library that implements basic proguard handling.

Documentation

Release Management

We use craft to release new versions.


lib.rs:

This crate implements handling of proguard mapping files.

The main use case is to re-map classes or complete stack frames, but it can also be used to parse a proguard mapping line-by-line.

The uuid feature also allows getting the UUID of the proguard file.

Examples

let mapping = r#"
android.arch.core.internal.SafeIterableMap -> a.a.a.b.c:
    13:13:java.util.Map$Entry eldest():168:168 -> a
"#;
let mapper = proguard::ProguardMapper::from(mapping);

// re-mapping a classname
assert_eq!(
    mapper.remap_class("a.a.a.b.c"),
    Some("android.arch.core.internal.SafeIterableMap"),
);

// re-map a stack frame
assert_eq!(
    mapper
        .remap_frame(&proguard::StackFrame::new("a.a.a.b.c", "a", 13))
        .collect::<Vec<_>>(),
    vec![proguard::StackFrame::new(
        "android.arch.core.internal.SafeIterableMap",
        "eldest",
        168
    )],
);

Dependencies