Question

I want to print the whole array in tcsh, because then i want to pipe it to uniq, is there a way to do it in tcsh.

i had set array

and was printing it:

echo "$array"

but it ended up with error: Word too long, it works for smaller arrrays,

Is there some simple way to do it?

Was it helpful?

Solution

The usual solution to this problem is to work with files instead of variables:

cat > file <<EOF
YOUR ARRAY TEXT HERE.....
EOF
uniq file
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top