[master] 6df251006 OS/X's shell still (!) does not support -n on built-in echo
Dridi Boukelmoune
dridi at varni.sh
Mon Oct 23 05:59:57 UTC 2023
On Fri, Oct 20, 2023 at 9:20 AM Poul-Henning Kamp <phk at freebsd.org> wrote:
>
>
> commit 6df251006899ddd9410b34a60766995007fdec7b
> Author: Poul-Henning Kamp <phk at FreeBSD.org>
> Date: Fri Oct 20 09:18:36 2023 +0000
>
> OS/X's shell still (!) does not support -n on built-in echo
There is no -n option in POSIX, and in fact echo has no options at all.
> diff --git a/bin/varnishtest/tests/u00000.vtc b/bin/varnishtest/tests/u00000.vtc
> index 831dd9eac..d3baa09d6 100644
> --- a/bin/varnishtest/tests/u00000.vtc
> +++ b/bin/varnishtest/tests/u00000.vtc
> @@ -173,7 +173,7 @@ shell -err -expect {Cannot read -f file} {
> # Test that incomplete CLI commands in -I causes failure
>
> process p1 {
> - echo -n foobar > ${tmpdir}/_foobar
> + /bin/echo -n foobar > ${tmpdir}/_foobar
Looks like a job for printf instead.
> exec varnishd -n ${tmpdir}/v0 -d -a :0 -I ${tmpdir}/_foobar 2>&1
> } -expect-exit 2 -start
>
> @@ -182,7 +182,7 @@ process p1 -screen-dump
> process p1 -wait
>
> process p2 {
> - echo 'foobar << blabla' > ${tmpdir}/_foobar
> + /bin/echo 'foobar << blabla' > ${tmpdir}/_foobar
> exec varnishd -n ${tmpdir}/v0 -d -a :0 -I ${tmpdir}/_foobar 2>&1
> } -expect-exit 2 -start
>
> _______________________________________________
> varnish-commit mailing list
> varnish-commit at varnish-cache.org
> https://www.varnish-cache.org/lists/mailman/listinfo/varnish-commit
More information about the varnish-commit
mailing list