fish-shell/tests/test3.out
ridiculousfish 3f3b3a7006 Export arrays as colon delimited, and support path-style variables
This commit begins to bake in a notion of path-style variables.

Prior to this fix, fish would export arrays as ASCII record separator
delimited, except for a whitelist (PATH, CDPATH, MANPATH). This is
surprising and awkward for other programs to deal with, and there's no way
to get similar behavior for other variables like GOPATH or LD_LIBRARY_PATH.

This commit does the following:

1. Exports all arrays as colon delimited strings, instead of RS.

2. Introduces a notion of "path variable." A path variable will be
"colon-delimited" which means it gets colon-separated in quoted expansion,
and automatically splits on colons. In this commit we only do the exporting
part.

Colons are not escaped in exporting; this is deliberate to support uses
like

    `set -x PYTHONPATH "/foo:/bar"`

which ought to work (and already do, we don't want  to make a compat break
here).
2018-10-19 17:29:39 -07:00

47 lines
666 B
Plaintext

Test 1 pass
Test 2 pass
Test 3 pass
Test 4 pass
Test 5 pass
Test 6 pass
Test 7 pass
Test 8 pass
Test 9 pass
Test 10 pass
Test 11 pass
Test 12 pass
Test 13 pass
Test 14 pass
Test 15 pass
Foo change detected
Foo change detected
count:5 content:[functionblock function global universal blocklocal]
Test 16 pass
__fish_test_env17=UNSHADOWED
SHADOWED
__fish_test_env17=UNSHADOWED
wuwuwu
boo
wuwuwu
foo
bar
bar
Testing Universal Startup
1
1
2
2
testu undef in top level shell
testu undef in sub shell
SHLVL: 1
SHLVL: 2
SHLVL: 1
SHLVL: 1
SHLVL: 1
SHLVL: 4
SHLVL: 4
Elements in DISPLAY: 1
Elements in FOO and FOOPATH: 1 4
MANPATH=man1:man2:man3
DONT_ESCAPE_COLONS=1: 2: :3: