会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
百变小超
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
4
5
6
下一页
2017年11月8日
python 读写XML
摘要: 参考 http://yshblog.com/blog/151 遇到的问题有: 写入时候的编码问题,将str类型转换为 unicode类型即可。
阅读全文
posted @ 2017-11-08 21:38 百变小超
阅读(1320)
评论(1)
推荐(0)
2017年11月7日
js加载json数据成表格
摘要: 根据json文件,读取并自动生成表格; 处理JSON的文件是将JSON串保存在js文件中,定义了一个变量名等于这个JSON串(数组)。 参考: https://my.oschina.net/TOW/blog/734589 http://www.cnblogs.com/rainlam163/p/325
阅读全文
posted @ 2017-11-07 13:04 百变小超
阅读(8442)
评论(0)
推荐(0)
2017年10月16日
python 比较两个数据库postgresql
摘要: 比较两个postgresql数据库,原理 比较数据库中各表的大小 1. 数据库查询语句 2. python字典比较
阅读全文
posted @ 2017-10-16 13:22 百变小超
阅读(1903)
评论(0)
推荐(0)
2017年10月12日
python 压缩 解压
摘要: unrar在Linux机器中对中文的支持有漏洞 components.py 利用python 对各种格式的文件压缩 解压 操作,文件的一些操作,目录结构读成字典的形式,字典的比较方法(http://www.runoob.com/python/att-dictionary-cmp.html)。
阅读全文
posted @ 2017-10-12 13:21 百变小超
阅读(677)
评论(0)
推荐(0)
2017年10月10日
linux 安装 rar命令
摘要: 参考 http://blog.chinaunix.net/uid-26719405-id-3450447.html 如果 /user/bin 中有 rar 删除后重新创建软连接 如果出现 “-bash: /usr/local/bin/rar: /lib/ld-linux.so.2: bad ELF
阅读全文
posted @ 2017-10-10 01:12 百变小超
阅读(3914)
评论(1)
推荐(0)
python 离线安装unrar库
摘要: 离线安装python库参考: http://www.cnblogs.com/michael-xiang/p/5690746.html 安装 unrar 的错误问题 参考: https://github.com/matiasb/python-unrar/blob/master/README.md ht
阅读全文
posted @ 2017-10-10 00:48 百变小超
阅读(2392)
评论(1)
推荐(0)
2017年10月9日
python 读取文件夹,目录中出现中文的问题
摘要: 在使用python读取中文目录的名称的时候,会出现中文乱码的问题,该问题很严重,因为使用os.path.isdir('乱码名称')和ospath.isfile('乱码名称')是判断不正确,都为false。 即使有时候采用 filename.decode("gbk").encode("utf-8")
阅读全文
posted @ 2017-10-09 19:18 百变小超
阅读(30268)
评论(1)
推荐(0)
2017年9月28日
python 采用paramiko 远程执行命令
摘要: 参考 http://www.developerq.com/article/1493123866 报错1: 是由于 没有设置 报错2: 会卡死在 该种方式进行交互,注意必须要换行"\n",和前面必须不能有空格等其他字符,确保密码正确
阅读全文
posted @ 2017-09-28 13:19 百变小超
阅读(4316)
评论(2)
推荐(0)
2017年9月25日
python unrar 解压缩
摘要: class UNRARModel: def __init__(self, filepath): self.rar = rarfile.RarFile(filepath) self.infolist = self.rar.infolist() def extral_list(self, selected_dir): selected...
阅读全文
posted @ 2017-09-25 20:31 百变小超
阅读(1203)
评论(0)
推荐(0)
python远程下载
摘要: class SFTPModel: def __init__(self, host, user, password): t = paramiko.Transport((host, 22)) t.connect(username=user, password=password) self.sftp = paramiko.SFTPClient.f...
阅读全文
posted @ 2017-09-25 20:29 百变小超
阅读(280)
评论(0)
推荐(0)
上一页
1
2
3
4
5
6
下一页
公告