摘要: 1. In setting file: ROOT_PATH='/home/ronglian/project/taskschedule' STATIC_URL = '/static/' STATICFILES_DIRS=( # P... 阅读全文
posted @ 2015-08-24 22:58 自由清风 阅读(222) 评论(0) 推荐(0) 编辑
摘要: from django.db.models import get_app, get_models, get_modelfrom django.db import models#get the certain modelsisense_model=get_model('fastlogin','sis_... 阅读全文
posted @ 2015-08-24 22:54 自由清风 阅读(130) 评论(0) 推荐(0) 编辑
摘要: For we need to connect the postgres db in project very frequently, so write the follows class: 1 import psycopg2 2 #finish the work with task schedule... 阅读全文
posted @ 2015-08-24 22:33 自由清风 阅读(126) 评论(0) 推荐(0) 编辑
摘要: In everbright task schedule project, we need some daemon process to do certain work, here is a example of daemon class: 1 #encoding=utf-8 2 #!/usr/b... 阅读全文
posted @ 2015-08-24 22:25 自由清风 阅读(225) 评论(0) 推荐(0) 编辑
摘要: 今天帮同事用Python写了一个小工具,实现了在linux下批量文件名和去掉windows 文件到linux过程中产生^M的脚本,代码如下: 1 !/opt/exptools/bin/python 2 import os,os.path,sys 3 import shutil,string 4 di... 阅读全文
posted @ 2015-08-24 21:38 自由清风 阅读(192) 评论(0) 推荐(0) 编辑
摘要: When working ALU IMS Patch team, we need to static the SU duration to add it to the patch report, the duration time alway is hard work, so I write the... 阅读全文
posted @ 2015-08-24 21:31 自由清风 阅读(185) 评论(0) 推荐(0) 编辑
摘要: Some time we need to record the logging information in multiple module, however if we use the follows logging configuration would lead the log cannot ... 阅读全文
posted @ 2015-08-24 21:20 自由清风 阅读(278) 评论(0) 推荐(0) 编辑
摘要: 安装完成后,还需要最后一步设置,在命令行输入:$ git config --global user.name "Allen Zhong"$ git config --global user.email "zhongyu211@126.com"git initInitialized empty Git... 阅读全文
posted @ 2015-08-24 18:05 自由清风 阅读(159) 评论(0) 推荐(0) 编辑
摘要: Install pyodbc in OpenSUSE:Install unixODBC-2.3.2./configure --prefix=/usr/local/unixODBC --enable-gui=no --enable-drivers=no --with-qt-dir=/usr/lib... 阅读全文
posted @ 2015-08-24 00:16 自由清风 阅读(213) 评论(0) 推荐(0) 编辑