You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

33 lines
342 B

#!/bin/bash
exname=$(basename $0)
prefix_cmd="
. /etc/shlib
include common
include parse
. ../lib/common
"
try "echo '
a: b
' | yaml_opt_bash_env PREFIX | tr '\0' ':'"
noerror
is out 'PREFIX_A:b:'
try "echo '
x: 1
y:
a: 4
b: 3
' | yaml_opt_bash_env PREFIX | tr '\0' ':'"
noerror
is out 'PREFIX_X:1:PREFIX_Y_A:4:PREFIX_Y_B:3:'