[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: CR/LF



On Sat, Dec 10, 2022 at 09:01:29PM -0500, Jim Popovitch wrote:
> Why does this produce a CR/LF
> 
>  ~$ TEST=$(ssh -o LogLevel=QUIET -t user@server "echo -n ''"); echo ${TEST}

It does not produce a carriage return, unless you're on Windows.

The second echo command (the local one) produces a newline.  Since you
did not give it any parameters, that's all it produces.

> whilst this same command does not:
>  
>  ~$ ssh -o LogLevel=QUIET -t user@server "echo -n ''"

The remote echo produces no output, and there's no local echo, so you
get no output.


Reply to: