pdfrs 0.1.1

A CLI tool to read/write PDFs and convert to/from markdown
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
use std::fs;
fn main() {
    let bytes = fs::read("/Users/yingkitw/Desktop/myproject/pdfrs/target/test_output/signed_test.pdf").unwrap();
    let text = String::from_utf8_lossy(&bytes);
    println!("Looking for /Type /Sig: {}", text.contains("/Type /Sig"));
    println!("Looking for /Sig: {}", text.contains("/Sig"));
    for line in text.lines() {
        if line.contains("Sig") || line.contains("Contents") {
            println!("{}", line);
        }
    }
}