
shell命令
elbort
这个作者很懒,什么都没留下…
展开
-
size命令
显示一个目标文件或者链接库文件中的目标文件的各个段的大小,当没有输入文件名时,默认为a.out。size:支持的目标:elf32-i386 a.out-i386-linux efi-app-ia32 elf32-little elf32-bigsrec symbolsrec tekhex binary ihex trad-core。命令格式:size范例: [root@lo转载 2012-05-15 10:51:42 · 873 阅读 · 0 评论 -
bash之提取文件的每行
1.统计某个目录下所有文件的个数:find . -type f | wc -l 2.提取文档中每行内容:while read linedo a=$(dirname ${line}) echo ${here}${a} mkdir -p ${here}$a cp -r ${here}/Noise.wav ${h原创 2012-05-23 09:06:52 · 1503 阅读 · 0 评论 -
dd命令解析和例子
一、dd命令的解释。1.定义 dd是 Linux/UNIX 下的一个非常有用的命令,作用是用指定大小的块拷贝一个文件,并在拷贝的同时进行指定的转换。dd命令在拷贝完文件之后还会显示拷贝所用的时间,以及每秒的数据传输速度。可以指定不同的block size以测定在不同的block size下的传输速度。2.参数 1. if=文件名:输入文件名,缺省为标准输入。即转载 2012-06-15 09:44:57 · 768 阅读 · 0 评论 -
Slicing filenames based on extension
Here is practical example that can be used to extract different portions of a domain name,given URL="www.google.com":$ echo ${URL%.*} # Remove rightmost .*www.google$ echo ${URL%%.*} # Remove转载 2012-06-15 10:10:49 · 392 阅读 · 0 评论 -
mkdir 创建目录忽略路径判断
mkdir -p /home/slynux/test/hello/childThis single command takes the place of the five different commands listed above. It ignoresif any level of directory exists and creates the missing directorie转载 2012-06-15 14:05:34 · 2186 阅读 · 0 评论 -
文件属性说明
The first column of output specifies the following. The first letter corresponds to: "-"—if it is a regular file. "d"—if it is a directory "c"—for a character device "b"—for a block device "转载 2012-06-15 14:11:16 · 510 阅读 · 0 评论 -
SHELL编程常用列子参考
BASH SHELL编程:1. 初始化顺序: /etc/profile ( ~/.bash_profile | ~/.bash_login | ~/.profile ) ~/.bashrc2. set -o allexport 当前shell变量对其所有子shell都有效. set +o allexport 当前shell变量对其所有子she转载 2012-12-27 10:08:01 · 921 阅读 · 0 评论