vbs中,如果需要运行的程序中带有空格,按照通常的方式往往会提示错误,其实有两种形式不同的解决方法:在应用程序前后分别加三个双引号,代码如下:[c-sharp] view plaincopyprint?Setwshell=CreateObject("WScript.Shell")wshell.Run...
分类:
其他好文 时间:
2014-07-05 17:07:12
阅读次数:
274
***************************************************************************************************##build-input.sh#!/bin/bashset -eucurrent_home=$(re...
分类:
其他好文 时间:
2014-07-05 16:43:00
阅读次数:
317
疯狂的暑假学习之 Django学习笔记(二)—— 模板
参考: 《The Django Book》 第四章
一、模板基础知识
1.模板是如何工作的
用 python manage.py shell 启动交互界面(因为manage.py 保存了Django的配置,如果直接python启动交互界面运行下面代码会出错)
输入下面代码
>>> from django import template
>>> t = template.Template('My name is {{name}}.')
>>> ...
分类:
其他好文 时间:
2014-07-05 10:41:57
阅读次数:
278
一、什么是可变参数
我们在C语言编程中有时会遇到一些参数个数可变的函数,例如printf()函数,其函数原型为:
int printf( const char* format, ...);
它除了有一个参数format固定以外,后面跟的参数的个数和类型是可变的(用三个点“…”做参数占位符),实际调用时可以有以下的形式:
printf("%d",i);
printf("%s",s...
分类:
其他好文 时间:
2014-07-05 10:38:06
阅读次数:
199
在nginx中使用lua直接访问mysql和memcaced达到数据接口的统一
安装nginx参见《nginx+lua+redis构建高并发应用》
让nginx 中的nginx_lua_module支持mysql 和memcache
下载
https://github.com/agentzh/lua-resty-memcached
https://github.com/agentzh/lua-resty-mysql
对于访问接口的统一有很多的处理方式,这里介绍使用nginx lua 访问mysql并用m...
分类:
数据库 时间:
2014-07-04 09:16:42
阅读次数:
431
HBase Shell
HBase shell使用起来最方便,进入HBase shell控制台即可使用。
$ $HBASE_HOME/bin/hbase shell
常见操作有create(创建表)/put(插入或更新数据)/get(根据rowkey查询)/scan(范围查询)/delete(删除列)/deleteAll(根据rowkey删除整行数据)/disable&drop(禁用表之后再...
分类:
编程语言 时间:
2014-07-04 08:12:54
阅读次数:
383
#!/bin/bashwhiletruedo badip=$(lastb-i-a|awk‘/ssh:notty/{print$NF}‘|sort|uniq-c|awk‘($1>3){print$2}‘) foriin$badip do iptables-tfilter-IINPUT-s$i-ptcp--dport22-jDROP done :>/var/log/btmp sleep10sdone
分类:
移动开发 时间:
2014-07-04 06:22:09
阅读次数:
364
屌丝运维常用shell列出你最常用的10条shellhistory|awk‘{a[$2]++}END{for(iina){printa[i]""i}}‘|sort-rn|headhistory|awk‘{a[$4]++}END{for(iina){printa[$i]""i}}‘|sort-rn|headgrep-v"#".bash_history|awk‘{++a[$1]}END{for(iina)printi,a[i]|"sort-k2-nr..
分类:
其他好文 时间:
2014-07-04 06:19:01
阅读次数:
253
php_memcached.dll csdn资源
memcached在windows7上的安装问题
错误:
通过cmd命令行进入到D:\webEve\memcached(下载后的解压目录)
运行 memcached.exe -d install
报错“ failed to install service or service already ins...