shell ls结果赋给变量

dirSrc=$(ls test/ -l | awk '/^d/{print $NF}') echo "dirSrc is $dirSrc"
相关文章
相关标签/搜索