✨ Allow value prefixed with bang to skip parsing
This commit is contained in:
parent
d0b6c40445
commit
a8cbfd087f
2 changed files with 8 additions and 0 deletions
|
|
@ -17,6 +17,10 @@ func ParseString(in string) any {
|
|||
return s
|
||||
}
|
||||
|
||||
if strings.HasPrefix(s, "!") {
|
||||
return strings.TrimPrefix(s, "!")
|
||||
}
|
||||
|
||||
yesno := regexp.MustCompile("^(y|Y|yes|Yes|YES|n|N|no|No|NO|true|True|TRUE|false|False|FALSE|on|On|ON|off|Off|OFF)$")
|
||||
yes := regexp.MustCompile("^(y|Y|yes|Yes|YES|true|True|TRUE|on|On|ON)$")
|
||||
null := regexp.MustCompile("^(~|null|Null|NULL|none|None|NONE|nil|Nil|NIL)$")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue