HNHacker News
TopNewBestAskShowJobs

reimisdev

23 karma · joined June 13, 2025

submissionscomments
reimisdev··on Show HN: Rust framework for advanced file recognition and identification
You are absolutely right if you only need to detect simple file types. But of course no one forks a library to add the 3 file types they need and then re-builds them, and not to mention that because it's a static rule, if you want to detect more complex file types, it almost means you'll have to rewrite the entire core for that.
reimisdev··on Show HN: Rust framework for advanced file recognition and identification
These two crates follow different philosophies. file-type is great for lightweight, static detection. In contrast, `magical_rs` is designed to be a framework — it lets you define custom rules, layer logic via DSLs, and even embed custom function pointers for advanced matching. So if your use-case involves complex formats, edge-case detection, or internal tooling where you need full control — magical_rs gives you the power without forcing you to fork the crate.
reimisdev··on Show HN: Rust framework for advanced file recognition and identification
You're right – that phrase was a bit much. I'll revise it. Thanks for pointing it out!
reimisdev··on Magical_rs
A zero-dependency, no_std-friendly Rust crate that detects file types with surgical precision by matching magic bytes at exact offsets — including deep-offset formats like ISO and TAR. Built for speed, safety, and extensibility.

magical_rs is a lightweight, dependency-free Rust crate that detects file types by matching magic bytes (signatures) at specific offsets — including tricky formats like .iso with signatures 32KB into the file.

No external tools. No bloated dependencies. Just fast, reliable file type detection.