I'm trying to save the find output to a variable in this manner:
a=find /Users/Downloads/DTI_allsites/subprojects/*/UII_0077 -name "dti_preprocessed" -type d
But I keep getting the following message:
-bash:
/Users/Downloads/DTI_allsites/subprojects/UII_B/UII_0077: is a directory
whenever I try to use the command, to echo the path using:
echo $a
I don't get anything saved in the variable. How can I fix this?
a=$(find <...>)
and it didn't work? – Benjamin W. Aug 27 '18 at 15:54