日韩av黄I国产麻豆传媒I国产91av视频在线观看I日韩一区二区三区在线看I美女国产在线I麻豆视频国产在线观看I成人黄色短片

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 >

pythondistutils安装_安装msi后的python distutils

發布時間:2024/2/28 59 豆豆
生活随笔 收集整理的這篇文章主要介紹了 pythondistutils安装_安装msi后的python distutils 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

我正在用distutilsbdist_msi命令創建一個msi安裝程序。在我的設置文件中,

我想在msi安裝程序包后運行代碼,請幫助。。在from distutils.core import setup

from distutils.command.bdist_msi import bdist_msi

import os

import shutil

STARTMENU = "C:/ProgramData/Microsoft/Windows/Start Menu/Programs/ShotExplorer"

STARTUP = "C:/ProgramData/Microsoft/Windows/Start Menu/Programs/Startup"

LINK = r"C:\Python27\Lib\site-packages\shotexplorer\ShotExplorer.lnk"

class MyCommand(bdist_msi):

def run(self):

bdist_msi.run(self)

print "Creating Start Menu Entries"

if not os.path.exists(STARTMENU):

os.makedirs(STARTMENU)

shutil.copy(LINK, STARTMENU)

shutil.copy(LINK, STARTUP)

setup(

name = "shotexplorer",

version = "1.0",

description = "Tool to explore shots on isilon",

author = "abhishek.garg",

author_email = "abhishekgarg12@yahoo.com",

packages = ["shotexplorer", "shotexplorer.pyHook"],

package_data = {"":["explorer.ico","quicktime.png","ShotExplorer.lnk","pyHook/_cpyHook.pyd"]},

include_package_data = True,

cmdclass = {'bdist_msi':MyCommand}

)

總結

以上是生活随笔為你收集整理的pythondistutils安装_安装msi后的python distutils的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。