Human Name - Elixir bindings for the `human-name` crate as a Rust NIF

I needed a reliable way to process human names and found a handy crate (https://crates.io/crates/human_name) and decided to whip up a NIF using Rustler.

Hex: hex.pm/packages/human_name
Github: github.com/amokan/human_name
Docs: hexdocs.pm/human_name/readme.html

A couple caveats:

  • I am quite rusty (no pun intended) with Rust, so if anyone feels the need to DRY up that code and wants to submit a PR - please do!
  • This has not been tested off of my Apple M1-based machine. I will be using this in a actual production data pipeline next week, but until then - test it out before you push to production and turn off your alerts :slight_smile:
6 Likes

If anyone gave this a shot earlier today, you likely had no luck via hex - since I failed to include the rust files in the package bundle.

Try again with v0.1.2 as this should be resolved. Last resort, just link to the git repo in your deps.

Anyone bundling up a rustler-based package - do not forget to adjust your :files and :exclude_patterns attributes in your mix.exs.

3 Likes

Let me hereby confirm that the package builds and runs fine on my x86-64 Linux machine :+1: .
Great work on this library! :confetti_ball:

1 Like

Great! Thank you for the feedback.

Works just fine on an Intel Mac with 10.15.7 (Catalina), too. Built and executed the sample code from README without issues.

1 Like