mirror of
https://github.com/metabarcoding/obitools4.git
synced 2025-06-29 16:20:46 +00:00
several small changes
Former-commit-id: c1cdb95885e44fd6ee7d1c963860d7ab41230c96
This commit is contained in:
@ -155,6 +155,10 @@ var OBILang = gval.NewLanguage(
|
||||
text := fmt.Sprintf(args[0].(string), args[1:]...)
|
||||
return text, nil
|
||||
}),
|
||||
gval.Function("gsub", func(args ...interface{}) (interface{}, error) {
|
||||
text := strings.ReplaceAll(args[0].(string), args[1].(string), args[2].(string))
|
||||
return text, nil
|
||||
}),
|
||||
gval.Function("subspc", func(args ...interface{}) (interface{}, error) {
|
||||
text := strings.ReplaceAll(args[0].(string), " ", "_")
|
||||
return text, nil
|
||||
|
Reference in New Issue
Block a user