随笔分类 -  pythonWindows相关

摘要:import os import logging import time import sys import threading # print(sys.path) # from lib.run_cmd import runCommand_wait,runCommand logger = loggi 阅读全文
posted @ 2022-08-09 14:26 该显示昵称已被使用了 阅读(194) 评论(0) 推荐(0)
摘要:1. pip install xlwings https://zhuanlan.zhihu.com/p/82783751?utm_source=wechat_session&utm_medium=social&utm_oi=1087267078251094016&utm_campaign=share 阅读全文
posted @ 2021-07-28 17:38 该显示昵称已被使用了 阅读(127) 评论(0) 推荐(0)
摘要:【原始】打开记事本 def createFile(filename): if os.path.exists(filename) == False: open(filename, "a").close() if os.path.getsize(filename): pass else: f = ope 阅读全文
posted @ 2021-07-20 14:24 该显示昵称已被使用了 阅读(120) 评论(0) 推荐(0)
摘要:smbclient方法 def check_smb_img(): smbclient.register_session("1.1.1.1", username="name", password="password") img_path = smbclient.listdir(r"\\1.1.1.1\ 阅读全文
posted @ 2021-07-13 17:35 该显示昵称已被使用了 阅读(544) 评论(0) 推荐(0)
摘要:指定启动参数 -X utf8 C:\Users\python.exe -X utf8 C:\Scripts\ride.py 重写函数 # Python 和 encoding 相关的配置主要有下面几个: locale.getpreferredencoding() 这个用的是最广的。 这是 Python 阅读全文
posted @ 2021-03-10 14:10 该显示昵称已被使用了 阅读(112) 评论(0) 推荐(0)
摘要:import platform os_platform = platform.platform() # Windows-10-10.0.18362-SP0 阅读全文
posted @ 2021-01-19 09:41 该显示昵称已被使用了 阅读(697) 评论(0) 推荐(0)
摘要:以下写法都可以 file = r'C:\config.yaml' file = 'C:\config.yaml' file = 'C:\\config.yaml' file = r'C:\\config.yaml' file = r'C:/config_auto_ui.yaml' file = 'C 阅读全文
posted @ 2021-01-19 09:38 该显示昵称已被使用了 阅读(1922) 评论(0) 推荐(0)