随笔分类 - python
摘要:import osa = 'var/label/txt/123.txt' print(os.path.splitext(a)) b = 'var/label/txt/123' print(os.path.splitext(b)) 输出 ('var/label/txt/123', '.txt') ('
阅读全文
摘要:code { '.*': 'application/octet-stream', '.tif': 'application/x-tif', '.001': 'application/x-001', '.301': 'application/x-301', '.323': 'text/h323', '
阅读全文
摘要:使用010 editor,编辑C:\Python27\Scripts\pip2.exe, 修改为如下目录程序名称 然后保存即可。
阅读全文
摘要:pip3.7 install pytest-cov
阅读全文
摘要:pip3.7 install portend 参考: https://pypi.org/project/portend/
阅读全文
摘要:pip3.7 install cheroot 参考: https://pypi.org/project/cheroot/
阅读全文
摘要:pip3.7 install zc.lockfile
阅读全文
摘要:pip3.7 install zc.buildout 参考: https://www.cnblogs.com/0xcafedaddy/p/8533781.html
阅读全文
摘要:pip3.7 install jaraco.text 参考: https://pypi.org/project/jaraco.text/
阅读全文
摘要:pip3.7 install jaraco.classes 参考: https://www.cnpython.com/pypi/jaracoclasses
阅读全文
摘要:pyqt https://blog.csdn.net/quantam/article/details/90267824 http://code.py40.com/pyqt5/26.html pyqt 打包为dmg https://www.zhihu.com/question/28374491/ans
阅读全文
摘要:import time import datetime t=datetime.datetime.now() #当前日期 t1 =t.strftime('%Y-%m-%d %H:%M:%S') #转为秒级时间戳 ts1=time.mktime(time.strptime(t1, '%Y-%m-%d %
阅读全文
摘要:>>> import sys >>> sys.platform 'darwin' >>>
阅读全文
摘要:'__main__' 是顶层代码执行的作用域的名称。模块的 __name__ 在通过标准输入、脚本文件或是交互 式命令读入的时候会等于 '__main__'。 模块可以通过检查自己的 __name__ 来得知是否运行在 main 作用域中,这使得模块可以在作为脚本或 是通过python -m运行时条件性地执行一些代码,而在被import时不会执行。 if __name__ == "__main__
阅读全文
摘要:index.html server 运行后,打开浏览器
阅读全文
摘要:macname@bogon ~ % echo '{"json": "obj"}' | python3.7 -m json.tool { "json": "obj" }
阅读全文
摘要:macname@bogon testenv3.7 % cat file.json { "code": 200, "msg": "请求成功", "data": { "username": "abc", "mobile": "18611751121" }, "task":[{ "username": "abc1", "mobile": "1861175
阅读全文

浙公网安备 33010602011771号