摘要: It's just caused of Anaconda's gcc libs was compiled by gcc4.xx. by the system owned gcc version is gcc5.xx... I've hacked this problem with copy libg 阅读全文
posted @ 2017-01-03 16:24 lyjsy 阅读(1454) 评论(0) 推荐(0) 编辑
摘要: Sqlite 不支持直接修改字段的名称。 我们可以使用别的方法来实现修改字段名。 1、修改原表的名称 ALTER TABLE table RENAME TO tableOld; 2、新建修改字段后的表 CREATE TABLE table(ID INTEGER PRIMARY KEY AUTOINC 阅读全文
posted @ 2016-12-20 20:13 lyjsy 阅读(2868) 评论(0) 推荐(0) 编辑
摘要: 1、创建用户 mysql> use mysql;mysql> insert into user(Host,User,Password) values(“localhost”,”wangzh”,password(“123456″));//刷新系统权限表mysql>flush privileges; 创 阅读全文
posted @ 2016-07-24 14:42 lyjsy 阅读(144) 评论(0) 推荐(0) 编辑
摘要: sudo apt-get install python-virtualenv virtualenv --no-site-packages files cd files source ./bin/activate 退出虚拟环境deactivate在虚拟环境安装Python套件Virtualenv 附带 阅读全文
posted @ 2016-07-06 22:33 lyjsy 阅读(240) 评论(0) 推荐(0) 编辑
摘要: sudo vim /etc/resolvconf/resolv.conf.d/base (这个文件默认是空的) 在里面插入: nameserver 8.8.8.8 nameserver 8.8.4.4 nameserver 114.114.114.114 保存退出,然后执行 sudo resolvc 阅读全文
posted @ 2016-07-06 22:24 lyjsy 阅读(220) 评论(0) 推荐(0) 编辑
摘要: sudo iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 8080 阅读全文
posted @ 2016-05-10 14:29 lyjsy 阅读(144) 评论(0) 推荐(0) 编辑
摘要: 获取图片属性详细信息,通过PIL库实现,PIL库为2.9.0(3.0版本以下) python代码实现 #-*-coding:utf8-*- from PIL import Image from PIL.ExifTags import TAGS img = Image.open("img.jpg") 阅读全文
posted @ 2016-02-21 14:35 lyjsy 阅读(4526) 评论(0) 推荐(0) 编辑
摘要: python实现ttf文件属性详细信息 1 import sys 2 from fontTools import ttLib 3 4 def shortName( font ): 5 name = "" 6 7 ret = [] 8 for record in font['name'].names: 阅读全文
posted @ 2016-02-21 14:35 lyjsy 阅读(1615) 评论(0) 推荐(1) 编辑
摘要: Putty 启用putty keepalive putty -> Connection -> Seconds between keepalives ( 0 to turn off ),默认为0,改为60。 更改ssh服务器的配置文件/etc/ssh/sshd_config ClientAliveIn 阅读全文
posted @ 2016-02-21 14:35 lyjsy 阅读(1064) 评论(0) 推荐(0) 编辑
摘要: 1、sudo passwd postgres2、sudo -u postgres createuser -P django_login3、su postgres4、psql5、CREATE DATABASE django_db OWNER django_login ENCODING 'UTF8';6... 阅读全文
posted @ 2016-01-24 21:03 lyjsy 阅读(171) 评论(0) 推荐(0) 编辑