例1:在python中包装ls命令#!/usr/bin/envpython#pythonwapperforthelscommandimportsubprocesssubprocess.call(["ls","-l"])在Linux中执行该命令[root@pydbpython]#pythonls.py...
分类:
编程语言 时间:
2014-05-10 01:32:55
阅读次数:
377
配符可以令我们的查找工作更加灵活方便,下面就让我们来看一下这些统配符的具体用法。1、“?”
代表任意单个字符,输入几个“?”就代表几个未知字符。比如我们输入“?国”就可以找到诸如“中国”、“美国”、“英国”等字符;输入“???国”可以找到“孟加拉国”等字符。2、“*”可以代表任意多个字符。比如我们输...
分类:
其他好文 时间:
2014-05-08 21:29:13
阅读次数:
288
我们知道在linux下当我们想把文字用命令输入到一个文本下时可以用echo命令例:echo
"nihao" > /z.txt同样当我们想把命令执行的结果也输入到一个文本时,不用echo,直接命令到输入的文本就行了例:ls /home >
/z.txt-------------------------...
分类:
系统相关 时间:
2014-05-08 20:18:31
阅读次数:
396
python中re模块1.正则匹配基础知识(1)通配符..ython可以匹配
aython,jython,只有一个字符如果要匹配a.py的话需要进行转义a\.py,r如果这样写a.py那么会匹配成aapy(2)字符集[][a-z]ython
可以匹配a-z之间任意一个字符 yython[a-zA-Z...
分类:
其他好文 时间:
2014-05-08 20:01:49
阅读次数:
264
不小心重命名了libc.so.6动态库,运行命令
#mv /lib/libc.so.6 /lib/libc.so.6.back
#ls
ls: error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory
各种命令都不好...
分类:
其他好文 时间:
2014-05-07 04:49:53
阅读次数:
319
例如文档里出现了四号字体又出现了小四字体,现在我需要把所有四号字体转为小四
一个个用眼睛看总会看漏掉
所以还是需要利用搜索
打开搜索框,输入“[一-龥]”(去掉双引号)
勾选“使用通配符”
然后点击下面“格式”-字体
选择四号
然后一个个搜索就可以找到所有的四号字体,再改成小四即可
另外还可以搜索替换对应颜色对应字体的文字...
分类:
其他好文 时间:
2014-05-07 03:17:51
阅读次数:
345
关于cp命令:1.将一个文件复制到一个目录中,并保持原文件名。[root@localhosttest]#ls-l
total44
drwxr-xr-x2rootroot4096May420:56d1
drwxr-xr-x4rootroot4096May323:00d2
-rw-r--r--1rootroot0May420:54dir1
-rw-rw-r--1zhangfengzhezhangfengzhe0Feb262012helloworld
-rw-r..
分类:
系统相关 时间:
2014-05-06 17:37:37
阅读次数:
522
1 private void w_day_scheduling_Load(object sender,
EventArgs e) 2 { 3 4 if (ls_deptname == string.Empty) 5 ...
分类:
其他好文 时间:
2014-05-06 10:32:53
阅读次数:
326
Question:HowdoIview,modifyandrecreatethenewinitrd.imgonUbuntu,Debian,CentOS,Fedora,Red-Hat,ArchLinux,orSUSEdistributions?1.HowToViewContentOfinitrd.imgfile?initrd.imgisingzipformat.Somoveinitrd.imgtoinitrd.gzasshownbelow.#cp/tftpboot/el5/initrd.img.
#ls
cd..
分类:
其他好文 时间:
2014-05-05 12:31:38
阅读次数:
359
二、配置haproxy实现网站的负载均衡:1、node1和node2都安装httpd,php,php-mysql:[root@node1~]#yum-yinstallhttpdphpphp-mysql[root@node2~]#yum-yinstallhttpdphpphp-mysql2、为node1和node2提供静态和动态网页:[root@node1~]#ls/var/www/html/
index.htmlindex.php
[roo..
分类:
其他好文 时间:
2014-05-05 12:30:42
阅读次数:
614