shell脚本中执行ll命令,提示ll:command not found

如:查看当前脚本运行路径下的文件信息
test.sh

#!/bin/bash

cur_path=`pwd`
ll $cur_path

在这里插入图片描述
解决方法:使用ls -l (ll是ls -l的别名)

#!/bin/bash

cur_path=`pwd`
ls -l $cur_path

你可能感兴趣的:(linux学习笔记)