Skip to content

Carht/randomstring

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

random string

A golang library for generate a random string lowercases, string uppercase and numbers. Util for unix-like shell scripting.

Usage

Return a string of 32 characters.

./randstr
GAPkKnVFRICHskSCDxeTFTknIIsQBbdd

Cases:

  • Default (length of this string: 32 letters, upper and lowercases):
./randstr
UDckrRnCvURNRuKvNWziyRIBxREtjaEQ
  • Another cases:
./randstr -lu 35
WIMVngPABZGiBHcCuhmDLTVcoBAHrdJJUGH

./randstr -l 35
sgjxwcoqnkkqogzotoigozvyjdmzsegixul

./randstr -u 35
IBZDSTKGTFQSUWIICQSOTUBBNYISCIAWOYC

./randstr -nl 30
en8usol16pe8e6fhwy5c8xz7d5v9sr

./randstr -nu 32
DYCA7VFE1AURUI66PZGISG7IHQ8707HX

./randstr -n 20
46495882363454181740

./randstr -v
0.1.3

Warning

    On most GNU/Linux file systems, filenames can be up to 255 characters long, 
	this is the most portable character set [-._A-Za-z0-9] 

Version

If you use the argument -v or version return this:

./randstr -v
0.1.3

Usage example

mkdir $(randstr -l 27)
cp /home/user/file.xyz /home/user/$(randstr -u 45)
mv /home/user/file.xyz $(randstr -l 17)

License

GPLv3.0

About

A golang Library for generate random strings.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages