1
0
mirror of https://github.com/MontFerret/ferret.git synced 2025-03-19 21:28:32 +02:00

22 lines
483 B
Go
Raw Normal View History

package path
import "github.com/MontFerret/ferret/pkg/runtime/core"
// RegisterLib register `PATH` namespace functions.
// @namespace PATH
func RegisterLib(ns core.Namespace) error {
2020-05-13 22:10:47 -04:00
return ns.
Namespace("PATH").
RegisterFunctions(
core.NewFunctionsFromMap(map[string]core.Function{
"BASE": Base,
"CLEAN": Clean,
"DIR": Dir,
"EXT": Ext,
"IS_ABS": IsAbs,
"JOIN": Join,
"MATCH": Match,
"SEPARATE": Separate,
}))
}