Lucky Random

Generate random passwords, numbers, and available ports.

Usage

random [FLAGS] [OPTIONS]

Flags

ArgEnvironment VariableDescription
-p, --available-portGet a random available port. This may be combined with --range to get a random available port in the given range. The default port range is 1024-65535. If an available port cannot be found in the given range the nextavailable port starting at 1024 will be selected
-f, --floatGenerate a floating point range instead of an integer range

Options

ArgEnvironment VariableDescription
-r, --range<lowest_number> <highest_number>Generate a random integer in a range
-l, --length<length>Set the length of the generated string

Usage

lucky random is a utility for generating passwords, number ranges, and for getting random available ports.

Examples

Generate a random password with a specified length:

$ lucky random --length 32

Generate a random integer between 0 and 10 inclusive:

$ lucky random --range 0 10

Generate a random float between 0 and 1:

$ lucky random --float --range 0 1

Find a random available port in between 1024 and 65535:

$ lucky random --available-port