上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 17 下一页
摘要: Debian 7(wheezy)的内核是3.2,要想把内核升级到3.16怎么办呢?使用backports源!一、添加backports源打开/etc/apt/source.list文件,加入以下:deb http://ftp.debian.org/debian/ wheezy-backports m... 阅读全文
posted @ 2014-11-21 22:22 ibg 阅读(8380) 评论(0) 推荐(0) 编辑
摘要: 有时想按日或月生成一个序列,就像2014-1-1、2014-1-2、2014-1-3...在sql server中可以写个函数来实现。/*生成一个日期范围,如2014.01、2014.02...@Increment 步进值@StartDate 开始日期@EndDate 结束日期---------... 阅读全文
posted @ 2014-11-18 18:31 ibg 阅读(5164) 评论(1) 推荐(1) 编辑
摘要: 一、 安装依赖包sudo apt-get build-dep emacs23正在读取软件包列表... 完成正在分析软件包的依赖关系树 正在读取状态信息... 完成 下列软件包将被【卸载】: libtiff5-dev下列【新】软件包将被安装: bsd-mailx diffs... 阅读全文
posted @ 2014-10-27 14:14 ibg 阅读(1562) 评论(0) 推荐(0) 编辑
摘要: jsTree版本:3.0.4在ASP.NET MVC中使用jsTreeModel: public class Department { public int Id { get; set; } public string Name { get; set; } ... 阅读全文
posted @ 2014-10-14 19:09 ibg 阅读(52725) 评论(5) 推荐(0) 编辑
摘要: 今天发现在终端里输入apt-get inst后按Tab键无法自动补全成 install,纳闷之余google了一下(我承认开始是baidu...),原来是没有安装 bash-completion。sudo apt-get install bash-completion然后注销一下就可以了。 阅读全文
posted @ 2014-10-07 21:08 ibg 阅读(466) 评论(0) 推荐(0) 编辑
摘要: 思路是把字典转为列表后再排序d={'z':1,'y':2,'x':3} # 字典s=d.items() # [('y', 2), ('x', 3), ('z', 1)] 列表s.sort() # [('x', 3), ('y', 2), ('z', 1)] 排序列表# 或者连起来写(sort是... 阅读全文
posted @ 2014-09-30 11:37 ibg 阅读(245) 评论(0) 推荐(0) 编辑
摘要: string类型是不可变的,因此不能采用直接赋值的方式。比如一个字符串 helloworld,想把o替换成z,那么只有先替换,然后再迭代。strings="helloworld"hello=strings.replace('o','z')for index,string in enumerate(h... 阅读全文
posted @ 2014-09-30 11:31 ibg 阅读(343) 评论(0) 推荐(0) 编辑
摘要: 一、安装1、# apt-get install wine安装完后在终端里运行wine:# wine会弹出一个对话框:This is the wine64-bin helper package, which does not provide wine itself,but instead exists... 阅读全文
posted @ 2014-09-21 19:28 ibg 阅读(2610) 评论(0) 推荐(0) 编辑
摘要: 在python2和python3共存的机器上做开发,要想互不干扰,虚拟环境很重要。Debian7 默认是python2.7.3,装好python3.4.1后怎么建立虚拟环境呢?$ pyvenv myVenv$ source myVenv/bin/activate然后就可以在虚拟环境中安装程序了。如:... 阅读全文
posted @ 2014-09-11 20:13 ibg 阅读(429) 评论(0) 推荐(0) 编辑
摘要: 添加一个模型状态:ModelState.Add("IamKey", new ModelState { Value = new ValueProviderResult("", "HelloKey,IamValue", System.Globalization.Cultu... 阅读全文
posted @ 2014-08-15 13:56 ibg 阅读(446) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 17 下一页