DotMonk.Wildling.FSharp
2.0.7
dotnet tool install --global DotMonk.Wildling.FSharp --version 2.0.7
dotnet new tool-manifest
dotnet tool install --local DotMonk.Wildling.FSharp --version 2.0.7
#tool dotnet:?package=DotMonk.Wildling.FSharp&version=2.0.7
nuke :add-package DotMonk.Wildling.FSharp --version 2.0.7
wildling
F# library and CLI for pattern-based string generation. Zero NuGet dependencies (.NET BCL only). Targets .NET 8.
Docs: Website · Sandbox · Syntax · Source
Registry: NuGet
Example
http://${'dev,stage,prod'}\-${'api,web'}#{0-2}.example.${'com,net,org'}/@.html
(The \- is a literal hyphen; bare - would mean “one letter or digit”. @ is one lowercase letter.)
That builds URL-shaped candidates: scheme http://, then environment × service × optional digits × TLD, then a one-letter path page. Three environments, two services, zero–two digits ('', 0–9, 00–99), three TLDs, and a–z → 51948 strings — the kind of list you generate for fuzzing links or probing staging hosts, not type out.
A few of them:
http://dev-api.example.com/a.html/http://stage-web.example.com/z.htmlhttp://dev-api0.example.net/a.html/http://prod-web9.example.org/m.htmlhttp://dev-api00.example.com/a.html/http://prod-web99.example.org/z.html
Named dictionaries (%{'hosts'}) work the same way when the word lists live in files.
Try it in the sandbox, or see pattern syntax for length ranges, dictionaries, and escapes.
Install
From this repository:
cd fsharp
./build.sh
./bin/wildling "Year 19##"
From a release tag:
git clone --branch v2.0.7 --depth 1 https://github.com/dotmonk/wildling.git
cd wildling
./build.sh fsharp
Registry (CLI): NuGet package DotMonk.Wildling.FSharp is a .NET tool (PackAsTool), not a library PackageReference:
dotnet tool install -g DotMonk.Wildling.FSharp
wildling-fs "Year 19##"
Library: reference the project from a clone (or the built dist/ assembly).
open WildlingLib
let wildling = Wildling.Create([ "Year 19##" ])
let mutable value = wildling.Next()
while not (match value with :? bool as b -> b = false | _ -> false) do
printfn "%O" value
value <- wildling.Next()
Produces dist/wildling.dll when built from this tree. Requires the .NET 8 runtime, or Docker (the launcher falls back to the runtime image if dotnet is not on PATH).
CLI
./bin/wildling "Year 19##"
./bin/wildling --dictionary planets:../dictionaries/planets.txt "%{'planets'}"
./bin/wildling --template ./config.json
Help text and --check output follow docs/cli.md / docs/help.txt.
Build
./build.sh # Docker (dotnet SDK 8): publish to dist/, copies help.txt
Project tests live in ../tests/ and are run with ../test.sh.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
This package has no dependencies.