O | |
octal, Rx | |
OpenShift_Config | |
OpenShift_Http | |
OpenShift_Quickstarts | |
opt_eol, Keepalived | |
opt_hash, Syslog | |
opt_list | |
opt_plus, Syslog | |
opt_space | |
opt_tab, Sep | |
opt_value, Ntpd | |
opt_ws, Grub | |
option | |
Option definitions, Nslcd | |
option_kw, Hosts_Access | |
options | |
Options with multiple values, Chrony | |
optsep, Automaster | |
optval, Crypttab | |
org, Desktop. | |
origin_list, Access | |
origin_pin, AptPreferences | |
Oz |
An octal value
let octal = /0[0-7]+/
let opt_eol = del /[ \t]*\n?/ " "
deletes an optional # sign
let opt_hash = del /#?/ ""
Same as list, but there might be only one element in the list
let opt_list (lns:lens) (sep:lens) = lns . ( sep . lns )*
An optional list of elements, in square brackets
let opt_list (lns:lens) = rspace lbrack . (Build.opt_list lns (lrspace comma) . space)? . Util.del_str rbrack
let opt_list = Build.opt_list
let opt_list = Build.opt_list [ key Rx.word ] Sep.space
deletes an optional + sign
let opt_plus = del /\+?/ ""
An optional space or tab
let opt_space = /[ \t]*/
Deletes a Rx.opt_space and default to an empty string
let opt_space = del Rx.opt_space ""
Deletes a Rx.opt_space and default to a tab
let opt_tab = del Rx.opt_space "\t"
A subnode for optional values.
let opt_value (s:string) (r:regexp) = Build.key_value s space (store r)
let opt_ws = Util.del_opt_ws ""
A key option
let option = let kv_re = "command" | "environment" | "from" | "permitopen" | "principals" | "tunnel" in let flag_re = "cert-authority" | "no-agent-forwarding" | "no-port-forwarding" | "no-pty" | "no-user-rc" | "no-X11-forwarding" in let option_value = Util.del_str "\"" . store /((\\\\")?[^\\\n"]*)+/ . Util.del_str "\"" in Build.key_value kv_re Sep.equal option_value | Build.flag flag_re
let option =
Optional extensions defined in hosts_options(5)
let option = [ key option_kw . ( del /([ \t]*=[ \t]*|[ \t]+)/ " " . sto_to_colon )? ]
part of method
let option = let value_start = label "value" . Sep.equal in [ label "option" . store Rx.word . (Quote.quote_spaces value_start)? ]
let option = [ indent . del /[oO]ption/ "Option" . label "Option" . sep_spc . quoted_non_empty_string_val . [ label "value" . sep_spc . quoted_string_val ]* . eol ]
Since either an option or a shell command can be given, use an explicit list of known options to avoid misinterpreting a command as an option
let option_kw = "severity" | "spawn" | "twist" | "keepalive" | "linger" | "rfc931" | "banners" | "nice" | "setenv" | "umask" | "user" | /allow/i | /deny/i
let options = let opt_value = /[^#" \t\n\\\\]+|"[^#"\n\\\\]*"/ in let option = [ key Rx.word . (del /[ \t]*=[ \t]*/ "=" . store opt_value)? ] in [ key "options" . sep_space . sto_no_spaces . (sep_space . option)* . Util.comment_or_eol ]
Options values
let options = let options_entry = Build.key_value ("ndots"|"timeout"|"attempts") (Util.del_str ":") (store Rx.integer) | Build.flag ("debug"|"rotate"|"no-check-names" |"inet6"|"ip6-bytestring"|"edns0" |"single-request-reopen") | ip6_dotint in Build.key_value_line_comment "options" Sep.space (Build.opt_list options_entry Sep.space) comment_eol
let options = "# Example options no-pty ssh-dsa AAAA no-pty ssh-ed25519 AAAA no-pty,command=\"foo\" ssh-dsa AAAA no-pty,command=\"foo bar\" ssh-dsa AAAA no-pty,from=\"example.com,10.1.1.0/16\" ssh-dsa AAAA no-pty,environment=\"LANG=en_GB.UTF8\" ssh-dsa AAAA "
let optsep = del /[ \t,]+/ ","
let optval = /[A-Za-z0-9_.:-]+/
origin_list can be a single ipaddr/originname/domain/fqdn or a list of those values
let origin_list = let origin_re = Rx.no_spaces - /[Ee][Xx][Cc][Ee][Pp][Tt]/ in Build.opt_list [ label "origin" . store origin_re ] Sep.space
let origin_pin = pin_gen "origin"