Shell Test命令参数解析
来源:互联网 发布:rewrite龙骑士07 知乎 编辑:程序博客网 时间:2024/06/14 04:53
Test命令参数解析 .
test -n string : string 不为空
test -z string : string 为空
test int1 -eq int2 : int1 == int 2
test int1 -ne int2 : int1 != int2
test int1 -gt int2 : int1 > int2
test int1 -ge int2 : int1 >= int2
test int1 -lt int2 : int1 < int2
test int1 -le int2 : int1 <= int2
test -r filename : 用户对文件filename有读权限
test -w filename : 用户对文件filename有写权限
test -x filename : 用户对文件filename有可执行权限
test -f filename : 文件filename为普通文件
test -d filename : 文件filename为目录
test -c filename : 文件filename为字符设备文件
test -b filename :文件filename为块设备文件
test -s filename : 文件filename大小不为零
test -t fnumb : 与文件描述符fnumb(默认值为1)相关的设备是一个终端设备
test ! -s empty : empty 为空
test -a : And
test -o : Or
转自
http://blog.csdn.net/runming918/article/details/7226515
- Shell Test命令参数解析
- Shell Test命令参数解析
- Shell Test命令参数解析
- Linux Shell : Test命令参数解析
- Linux Shell : Test命令参数解析
- Linux Shell : Test命令参数解析
- linux Shell : Test命令参数解析
- Linux Shell : Test命令参数解析
- shell test和find命令实例解析
- shell test 参数
- shell中的test命令
- shell 笔记 test命令
- Linux Shell Test 命令
- shell 的test命令
- SHELL test [ 命令用法
- shell中的test命令
- shell 之 test 命令
- SHELL test [ 命令用法
- Linux用户及权限基础 1---- Linux用户基础
- 存储系统相关名词解释
- poj-2560最小生成树
- <climits>
- Android 编程下 Touch 事件的分发和消费机制
- Shell Test命令参数解析
- pear os 8 测试版
- sublime 必装插件(备忘)
- 修改 apache 上传文件大小限制
- 栈
- 在Python中使用SWIG调用C和C++程序
- [IOS]图片的旋转和缩放
- C++ 对象的内存布局(下)
- 离散数学及其应用--第一章-命题逻辑的基本概念