Library for generate silly names such as MrEarmuffsifier742! This supersedes my other project called Name Generator. CLI: https://pypi.org/project/pynamegen/ https://pypi.org/project/libnamegen
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
BBaoVanC 2f17f3babf
Update README.md to say latest two versions of Python are supported
9 months ago
libnamegen Change references of GitHub to my Gitea instance 9 months ago
tests Add pytest to Drone CI (#5) 9 months ago
.drone.yml Add pytest to Drone CI (#5) 9 months ago
.gitignore Add env/ to .gitignore 9 months ago
LICENSE Initial commit 1 year ago
README.md Update README.md to say latest two versions of Python are supported 9 months ago
requirements.txt Update README.md and setup.py for migration 9 months ago
setup.py Bump version to v3.1.1.post1 in setup.py 9 months ago

README.md

libnamegen

Build Status

PyPI PyPI - License

Package containing various name generation methods. Originally on my NameGenerator project.

Features

  • Easy to use
  • Imported as module
  • Always tested before release
  • Officially supports latest two versions of Python 3

How to Install

Run the command pip install libnamegen. If you want to specify a specific Python version to use for pip, use a command such as pip3 or pip3.8.

libnamegen requires the package libprogress, but it will automatically be installed by pip.


Documentation

API

Generate one classic name without debug:

from libnamegen import classic

# this uses the defaults which are one name, debug disabled, and classic generator
print(classic.gen())

Generate seven classic names with debug:

from libnamegen import classic

print(classic.gen(count=7, debug=True))
# print(classic.gen(7, True))  # also valid

Prompt the user for the amount of names, enable debug, and generate classic names:

from libnamegen import classic

amt = input("Amount of names to generate >> ")
count = int(amt)

names = classic.gen(count, true)
for name in names:
  print(name)

Generate one random name without debug:

from libnamegen import random

print(random.gen())

Generate one name using the random method 15 characters long:

from libnamegen import random

print(random.gen(length=15))

You can also import the entire libnamegen package, which will import all generation methods:

import libnamegen

print(libnamegen.classic.gen())

License

libnamegen is licensed under the GPLv3 license. For more information, please refer to LICENSE.