使用示例
示例一
[root@web ~]# basename /usr/bin/sort
sort
[root@web ~]# dirname /usr/bin/sort
/usr/bin
[root@web ~]#
示例二
[root@web ~]# basename /usr/include/stdio.h .h
stdio
[root@web ~]# basename /usr/include/stdio.h stdio.h
stdio.h
[root@web ~]#
[root@lC-ICP-DNS1 bin]# basename /Release/domainConvert/bin/nohup.out //获取文件名
nohup.out