24 lines
No EOL
680 B
TOML
24 lines
No EOL
680 B
TOML
# This is an example Stargate configuration file that defines a couple of routes to match against.
|
|
[[routes]]
|
|
from = "a"
|
|
to = "https://cptlobster.dev"
|
|
|
|
[[routes]]
|
|
from = ["b", "d"]
|
|
to = "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
|
|
|
|
# This is a simple regex matcher. It will match any string that ends in "ic".
|
|
[[routes]]
|
|
from = ".*ic"
|
|
to = "https://en.wikipedia.org/wiki/Special:Random"
|
|
using = "regex"
|
|
|
|
[[routes]]
|
|
from = "dod([fs][0-9]{2})e([0-9]{3})"
|
|
# Capture groups can be replaced using numbered capture groups (`$1`, `$2`, ...)
|
|
to = "https://dod.cptlobster.dev/episodes/$1/$2"
|
|
using = "regex"
|
|
|
|
[[routes]]
|
|
from = "sub/path"
|
|
to = "https://www.youtube.com/watch?v=dQw4w9WgXcQ" |