@@ -50,7 +50,8 @@ if [ -n "$VSCODE_ENV_REPLACE" ]; then
50
50
IFS=' :' read -ra ADDR <<< " $VSCODE_ENV_REPLACE"
51
51
for ITEM in " ${ADDR[@]} " ; do
52
52
VARNAME=" $( echo $ITEM | cut -d " =" -f 1) "
53
- VALUE=" $( echo $ITEM | cut -d " =" -f 2) "
53
+ # Use -e to encoded expand colons and other sequences
54
+ VALUE=" $( echo -e " $ITEM " | cut -d " =" -f 2) "
54
55
export $VARNAME =" $VALUE "
55
56
done
56
57
builtin unset VSCODE_ENV_REPLACE
@@ -59,7 +60,8 @@ if [ -n "$VSCODE_ENV_PREPEND" ]; then
59
60
IFS=' :' read -ra ADDR <<< " $VSCODE_ENV_PREPEND"
60
61
for ITEM in " ${ADDR[@]} " ; do
61
62
VARNAME=" $( echo $ITEM | cut -d " =" -f 1) "
62
- VALUE=" $( echo $ITEM | cut -d " =" -f 2) "
63
+ # Use -e to encoded expand colons and other sequences
64
+ VALUE=" $( echo -e " $ITEM " | cut -d " =" -f 2) "
63
65
export $VARNAME =" $VALUE ${! VARNAME} "
64
66
done
65
67
builtin unset VSCODE_ENV_PREPEND
@@ -68,7 +70,8 @@ if [ -n "$VSCODE_ENV_APPEND" ]; then
68
70
IFS=' :' read -ra ADDR <<< " $VSCODE_ENV_APPEND"
69
71
for ITEM in " ${ADDR[@]} " ; do
70
72
VARNAME=" $( echo $ITEM | cut -d " =" -f 1) "
71
- VALUE=" $( echo $ITEM | cut -d " =" -f 2) "
73
+ # Use -e to encoded expand colons and other sequences
74
+ VALUE=" $( echo -e " $ITEM " | cut -d " =" -f 2) "
72
75
export $VARNAME =" ${! VARNAME} $VALUE "
73
76
done
74
77
builtin unset VSCODE_ENV_APPEND
0 commit comments