Small library for randomly generating strings from a regex pattern.
Regex pattern | Sample output |
---|---|
.* |
hM7R |
\d+ |
415 |
[a-d4-8]{5} |
a8c6c |
[a-f0-9]{4}-[a-f0-9]{6} |
893a-9034d1 |
import "github.com/pipe01/revregexp
str := revregexp.Reverse("Hello (World|Everyone)")
fmt.Println(str)
// Outputs "Hello World" or "Hello Everyone"