ens-normalize-rs
A Rust implementation of ENS (Ethereum Name Service) name normalization.
Description
ens-normalize-rs is a robust Rust library for normalizing and validating ENS names according to ENSIP-15 specifications. It handles Unicode normalization, validation, beautification of ENS names ensuring correct, consistent and idempotent behavior.
Installation
Or pin a semver range in Cargo.toml (see crates.io for the latest version):
[]
= "0.1"
Usage
Testing
Crate contains several types of tests:
- Unit tests
- Integration (e2e) tests --
tests/e2e.rs - Validation ENS docs tests --
tests/ens_tests.rs
To run all tests simply run:
cargo test
Releasing (maintainers)
Releases are automated with release-plz:
- Merge PRs using Conventional Commits (
feat:→ minor,fix:→ patch,feat!:/BREAKING:→ major). - release-plz opens or updates a Release PR (version bump in
Cargo.toml+CHANGELOG.md). - Merge the Release PR → CI tags the release and runs
cargo publishto crates.io.
One-time setup: add a crates.io API token with publish permission for ens-normalize-rs as the GitHub Actions secret CARGO_REGISTRY_TOKEN (repo → Settings → Secrets and variables → Actions).
Roadmap
- Tokenization
- Normalization
- Beautification
- ENSIP-15 Validation Tests
- Unicode Normalization Tests
- CLI to update
specs.jsonandnf.json - analog of ens_cure function
- analog of ens_normalizations function
License
This project is licensed under the MIT License - see the LICENSE file for details.