name

Crates.ioname
lib.rsname
version0.1.1
created_at2025-12-08 05:12:09.085664+00
updated_at2025-12-08 06:06:17.689525+00
descriptionWorkspace binary for generating Rust crate names
homepagehttps://github.com/factordynamics/name
repositoryhttps://github.com/factordynamics/name
max_upload_size
id1972749
size87,524
refcell (refcell)

documentation

README

Name Forge banner placeholder

Deterministic crates.io name finder with an interactive CLI.

Stream candidate crate names in order, filter with curated dictionaries, and stop when you have enough available hits.

CI Rust License

InstallationFeaturesUsageDictionaryWorkspaceDevelopmentFlagsBehavior

Installation

[!NOTE] The workspace targets Rust 1.88+ (edition 2024). Install with the commands below when hacking locally.

cargo install name

# Install directly from the workspace while iterating.
cargo install --path bin/name

# Build a release binary when you need artifacts.
cargo build --release -p name

Usage

Run the CLI to scan for available crate names with streaming output.

By default, name uses 3-5 chars, stopping after 10 available.

name

To parallelize searches, you can pass the --parallel flag.

name --min-len 3 --max-len 6 --limit 25 --parallel

name shuffles candidate names by default to avoid repetitive searches.

For an alphabetical deterministic scan, use the --alphabetical flag.

name --alphabetical --limit 50

Features

  • Interactive prompts for length bounds and available-cap defaults (3–5 characters, stop after 10 available) when flags are missing.
  • Deterministic generator that walks length buckets, shuffles (optionally seeded), and can enforce prefix/suffix filters before hitting crates.io.
  • Embedded dictionary blending ~20k words with curated short names; swap in names-only, words-only, or custom files.
  • Configurable caps for total candidates scanned and available results returned; stops early once the available cap is hit.
  • Bounded parallel crates.io checks with ordered streaming output, colored summaries, and a graceful Ctrl+C path.
  • CRATES_IO_BASE_URL override keeps integration tests and local mocks off the real registry.

Dictionary

Use the embedded data or bring your own newline-delimited list:

# Names-only or words-only from the embedded sets.
name --names-only
name --words-only

# Custom dictionary file filtered to your length bounds.
name --dictionary ./my_words.txt --no-limit

[!TIP] The generator preserves ordered output even when --parallel is enabled. For reproducible scans, keep --alphabetical enabled or wire in a fixed shuffle seed via the library API.

Workspace

.
├── Cargo.toml          # Workspace, lint, and profile configuration
├── Justfile            # Developer commands (build, test, lint)
├── bin/
│   └── name/           # User-facing CLI crate
└── crates/             # Shared libraries for CLI parsing, dictionary data, generator, and crates.io client
  • bin/name: Streams available names with colored output, ordered results, and verbose logging when enabled.
  • crates/cli: Clap-based flag parsing plus interactive prompts that build a GeneratorConfig.
  • crates/generator (name-forge): Core engine that filters, shuffles (optionally seeded), and checks candidates sequentially or in parallel.
  • crates/dictionary: Embedded word/name data with iterators grouped by length for deterministic scans.
  • crates/crates-io-client: Minimal reqwest client for existence checks and metadata fetches against crates.io or a mock registry.

Development

  • just test runs the suite with nextest (installs if missing).
  • just check-format / just check-clippy / just check-docs enforce formatting, lints, and docs.
  • just check-udeps checks for unused dependencies (nightly + cargo-udeps).
  • just build-all-targets or cargo build for local builds.

Flags

  • --min-len <N> / --max-len <N>: inclusive length bounds (prompted if omitted).
  • --limit <N>: stop after N available names (defaults to 10); --no-limit disables this cap.
  • --parallel: enable bounded parallel crates.io checks while keeping ordered output.
  • --alphabetical: disable shuffling for deterministic lexicographic scans (shuffle is default).
  • --dictionary <path>: newline-delimited override for the embedded dictionary.
  • --names-only / --words-only: restrict to embedded names or words; otherwise both are used.
  • --verbose: enable tracing logs to stderr.

Behavior

  • Streams available names immediately with colored output and crates.io links, then prints a summary of checked/available/taken/error counts.
  • Honors CRATES_IO_BASE_URL (defaults to https://crates.io), useful for pointing at mocks in tests.
  • Exits cleanly on Ctrl+C.

License

This codebase is MIT licensed; see LICENSE.

Commit count: 0

cargo fmt