petname(1)
β¨ petname(1) β the petname manual, but make it cute β¨
okay bestie, welcome to petname(1) π this is the manual for petname, the little utility that makes "pet names" β and yes, this is genuinely the whole manual name situation so let's get into it.
πΈ NAME πΈ
petname β a utility to generate "pet names", consisting of a random combination of adverbs, an adjective, and an animal name
π SYNOPSIS π
petname [-w|--words INT] [-l|--letters INT] [-s|--separator STR]
[-d|--dir STR] [-c|--complexity INT] [-u|--ubuntu]
π OPTIONS π
-w|--wordsβ number of words in the name, default is 2-l|--lettersβ maximum number of letters in each word, default is unlimited-s|--separatorβ string used to separate name words, default is'-'-d|--dirβ directory containingadverbs.txt,adjectives.txt,names.txt, default is/usr/share/petname/-c|--complexityβ[0, 1, 2]; 0 = easy words (small wordlist), 1 = standard words (medium wordlist), 2 = complex words (large wordlist), default=0-u|--ubuntuβ generate ubuntu-style names, alliteration of first character of each word
π¦ DESCRIPTION π¦
so this utility will generate "pet names", consisting of a random combination of an adverb, adjective, and an animal name. These are useful for unique hostnames or container names, for instance. π«Ά
As such, PetName tries to follow the tenets of Zooko's triangle. Names are:
- human meaningful
- decentralized
- secure
no cap, that's the whole vibe. π
π EXAMPLES π
$ petname
wiggly-yellowtail
$ petname --words 1
robin
$ petname --words 3
primly-lasting-toucan
$ petname --words 4
angrily-impatiently-sage-longhorn
$ petname --separator ":"
cool:gobbler
$ petname --separator "" --words 3
comparablyheartylionfish
$ petname --ubuntu
amazed-asp
$ petname --complexity 0
massive-colt
π CODE π
Besides this shell utility, there are also native libraries: python-petname, python3-petname, and golang-petname. Here are some programmatic examples in code:
π§ Golang Example π§
package main
import (
"flag"
"fmt"
"github.com/dustinkirkland/golang-petname"
)
var (
words = flag.Int("words", 2, "The number of words in the pet name")
separator = flag.String("separator", "-", "The separator between words in the pet name")
)
func main() {
flag.Parse()
fmt.Println(petname.Generate(*words, *separator))
}
π Python Example π
See: https://pypi.golang.org/pypi/petname
$ pip3 install petname
$ sudo apt-get install python3-petname
#!/usr/bin/python
import argparse
import petname
parser = argparse.ArgumentParser(description='Generate human readable random names')
parser.add_argument('-w', '--words', help='Number of words in name, default=2', default=2)
parser.add_argument('-s', '--separator', help='Separator between words, default="-"', default="-")
parser.options = parser.parse_args()
print petname.Generate(int(parser.options.words), parser.options.separator)
β AUTHOR β
This manpage and the utility were written by Dustin Kirkland <dustin.kirkland@gmail.com> for Ubuntu systems (but may be used by others). Permission is granted to copy, distribute and/or modify this document and the utility under the terms of the Apache2 License.
The complete text of the Apache2 License can be found in /usr/share/common-licenses/Apache-2.0 on Debian/Ubuntu systems.
and that's the whole thing, bestie π this page is petname β source/version petname, dated 15 December 2014, filed under petname(1). slay, go name a container. periodt. π
β¨
π¦ where this page comes from
- ubuntu jammy: petname 2.8-0ubuntu1 Β· Apache-2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms