Python 生成pyc文件
2012-12-17 03:15
369 查看
import os
import sys
import time
import compileall
def pyc():
curPath = os.path.abspath(os.path.curdir)
curTime = time.strftime('%Y%m%d-%H%M%S',time.localtime(time.time()))
compileall.compile_dir(r'%s'%curPath)
if __name__ == '__main__':
pyc()
import sys
import time
import compileall
def pyc():
curPath = os.path.abspath(os.path.curdir)
curTime = time.strftime('%Y%m%d-%H%M%S',time.localtime(time.time()))
compileall.compile_dir(r'%s'%curPath)
if __name__ == '__main__':
pyc()
相关文章推荐
- 禁止python在运行的时候自动生成.pyc文件
- python 字节码文件(.pyc)的作用与生成
- Python什么情况下会生成pyc文件?
- Python运行时,如何不生成.pyc文件
- 通过deb包安装Python库时怎么生成pyc文件?
- python生成pyc文件
- Python——文件内容对比(可以生成HTML来观察结果)
- 生成简单的Makefile文件(Python实现)
- Python:如何将py文件打包生成exe文件
- 【Python】将python的py文件编译成保密的pyc文件
- python生成百万级URL的sitemap文件
- 零基础写python爬虫之打包生成exe文件
- 生成.m文件的python代码中出现的错误
- [python爬虫] 招聘信息定时系统 (二).调用pyinstaller包生成exe文件
- Python脚本如何生成Windows可执行文件.exe
- python处理文本文件并生成指定格式的文件
- python 生成xml文件
- python 将pyc 文件反编译成py源文件
- python生成指定文件名的txt文件
- 【Python】爬图片,Py2exe打包成EXE,并用inno setup生成安装文件