bullsgl

博客园 首页 新随笔 联系 订阅 管理

2013年12月16日 #

摘要: 1 private void setImageTag(string imgFile, string tagFile, string imgTag, string imgTitle) 2 { 3 uint padding = 2048; 4 if (File.Exists(imgFile)) 5 { 6 BitmapDecoder decoder = null; 7 // load the jpg file with a JpegBitmapDecoder 8 using (Stream jpegStreamIn = ... 阅读全文
posted @ 2013-12-16 16:53 bullsgl 阅读(1430) 评论(0) 推荐(0) 编辑

2013年10月18日 #

摘要: echo "test"| tee -a file1 file2如果想去掉在屏幕上的显示echo "test"| tee -a file1 file2 > /dev/null 阅读全文
posted @ 2013-10-18 11:28 bullsgl 阅读(1843) 评论(0) 推荐(0) 编辑

2013年10月12日 #

摘要: 单个文件较简单if [[ -f filename ]]; then echo existfi文件存在并且有内容if [[ -s filename ]]; then echo existfi带匹配符的多个文件时if ls /path/*.log &> /dev/null; then echo existfi或者需要知道有多少个文件存在时file_count=`find /path -name *.log | wc -l`if [[ file_count > 0 ]]; then echo exits $file_countfi 阅读全文
posted @ 2013-10-12 17:13 bullsgl 阅读(149) 评论(0) 推荐(0) 编辑

2013年10月11日 #

摘要: stat -c %y file取得修改日期stat -c %y file | cut -c 1-4,6-7,9-10 阅读全文
posted @ 2013-10-11 16:39 bullsgl 阅读(1208) 评论(0) 推荐(0) 编辑

2013年10月10日 #

摘要: 发送到文件夹的位置%APPDATA%\Microsoft\Windows\SendTo 阅读全文
posted @ 2013-10-10 14:07 bullsgl 阅读(170) 评论(0) 推荐(0) 编辑

2013年9月27日 #

摘要: 客户的账号下执行ssh-keygen -t rsa生成秘钥文件~/.ssh/id_rsa --秘钥文件~/.ssh/id_rsa.pub --公钥文件将公钥文件id_rsa.pub放到sftp服务器用户账号的.ssh目录下,文件名改为authorized_keys服务器用户账号下的.ssh目录和文件authorized_keys的权限改为700(必须是这个权限)客户端执行命令sftp 【服务端账号】@服务器名即可自动登录 阅读全文
posted @ 2013-09-27 16:16 bullsgl 阅读(700) 评论(0) 推荐(0) 编辑

2013年9月23日 #

摘要: 问题:VMWARE上安装的CentOS6.4,安装Apache,启动后,虚拟机上能访问,主机能ping通,但无法访问Apache。原因:防火墙设置,配置iptables,开放apache的端口80 阅读全文
posted @ 2013-09-23 20:33 bullsgl 阅读(240) 评论(0) 推荐(0) 编辑

2013年4月24日 #

摘要: private static final BigInteger KEY_VALUE_MOD = new BigInteger("305508269643653255827856366547026610628423058227532461973", 10); private static final BigInteger KEY_VALUE_MODT = new BigInteger("16079382612823855569887177184837249618505895609613015739", 10); 阅读全文
posted @ 2013-04-24 14:40 bullsgl 阅读(140) 评论(0) 推荐(0) 编辑

2012年6月11日 #

摘要: “好记性不如烂笔头”,曾经对这句话不以为然,记忆力不错的自己以为能把全部知识都牢牢记住,可随着岁月增长,发现有些东西还是要写下来,才能记得久。作为一名程序员,良好的记忆力是一项重要的素质。尤其是出色的短期记忆能力,是编程时高效和优质的保证。可是技术的积累和项目的经验,体会,一定要落于笔端,才能真正的牢记和梳理清楚。几次试着培养自己动笔的习惯,可是惰性总是战胜了理性。新开的博客,新的开始,愿这次能坚持下去。 阅读全文
posted @ 2012-06-11 13:40 bullsgl 阅读(152) 评论(0) 推荐(0) 编辑