npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

jejune

v0.1.1

Published

Generating stereotypical usernames has never been easier

Downloads

9

Readme

Jejune

Jejune is a tool that generates stereotypical usernames that can be used for prototypes or boilerplate. Or just for fun.

It works using Markov chains to construct usernames from random words that (usually) make sense in an order (e.g., our is used before lord, so it will try and generate ourlord). It also comes with additional sugar to make the usernames more realistic, such as mispelling words, wings (xXx<name>xXx) and numbers before and after the username (biased towards birth dates).

Installation

npm install -g jejune

Usage

The jejune executable is pretty straight-forward:

$ jejune --help

  Usage: jejune [options] [generators..]

  Options:

    -h, --help     output usage information
    -V, --version  output the version number

  Examples:

    $ jejune christian
    $ jejune

$ for i in {1..5}; do bin/jejune christian; done
Lover_Of_our_Father94
ThroughchurchLover981
FotherOfhumanity132
xOxSinnedxOx
Heaven881

Configuration

Jejune supports configuring general settings in a JSON file. It will be loaded from /etc/jejune/conf.json or ~/.jejune/conf.json (%USERPROFILE\jejune\conf.json on Windows).

An example configuration file with default settings:

{
    "numbers": true,
    "wings": true,
    "literacy": 0.65
}

This enables numbers after and before the username (usually birth dates), wings (prefixes and suffixes) and the literacy level is 0.65, so 65% of the userbase will not misspell words.

Jejune has a modular generator system that is configured by JSON, allowing you to declare your own method of generating usernames, usually related to a certain [sub-]culture.

The default generators are stored in the generators directory in Jejune's source directory. System-wide ones are stored in /etc/jejune/generators (none on Windows) and user-wide ones are in ~/.jejune/generators (%USERPROFILE%\jejune\generators on Windows).

API

jejune([generators..])

If generators is not provided, generate a username using a random generator in any of the configuration directories. If generators is an array, generate an array of usernames using the generators in the array in their exact order. Otherwise, assume generators is the name of a generator and generate a username using that.

Example

var jejune = require("jejune");
var christian = jejune("christian"); // generates just a christian username
var some = jejune(["christian", "teenager", "gamer", "mlp"]); // generates an array of usernames in that order

console.log(jejune()); // username from random generator

N.B. Not all generators listed in the example are implemented yet.