mirror of
https://github.com/go-task/task.git
synced 2025-11-25 22:32:55 +02:00
feat: add uuid and rand number functions (#2225)
* feat: add uuid and rand number functions * chore: remove randFloat for now
This commit is contained in:
@@ -2,11 +2,13 @@ package templater
|
||||
|
||||
import (
|
||||
"maps"
|
||||
"math/rand/v2"
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
"strings"
|
||||
|
||||
"github.com/davecgh/go-spew/spew"
|
||||
"github.com/google/uuid"
|
||||
"gopkg.in/yaml.v3"
|
||||
"mvdan.cc/sh/v3/shell"
|
||||
"mvdan.cc/sh/v3/syntax"
|
||||
@@ -38,6 +40,9 @@ func init() {
|
||||
"mustFromYaml": mustFromYaml,
|
||||
"toYaml": toYaml,
|
||||
"mustToYaml": mustToYaml,
|
||||
"uuid": uuid.New,
|
||||
"randInt": rand.Int,
|
||||
"randIntN": rand.IntN,
|
||||
}
|
||||
|
||||
// aliases
|
||||
|
||||
Reference in New Issue
Block a user