[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-bash] How to print a bash variable in the most succinct way?
From: |
Peng Yu |
Subject: |
Re: [Help-bash] How to print a bash variable in the most succinct way? |
Date: |
Wed, 10 Aug 2016 05:47:03 -0500 |
On Tuesday, August 9, 2016, Eduardo Bustamante <address@hidden> wrote:
> On Tue, Aug 9, 2016 at 4:22 PM, Peng Yu <address@hidden
> <javascript:;>> wrote:
> [..]
> > declare -a x='([0]="a" [1]="'\''" [2]="-")'
> What's the problem with the above representation? It's syntactically
> correct. What's your specific use case that makes this representation
> incorrect?
>
I need the most human readable repesentation. The one returned by declare
has redundancy in it. E.g., [1]= is not really necessary.
--
Regards,
Peng