Re: [問題] 新手問題請教,關於發行套件

看板Python作者 (撞牆期)時間13年前 (2012/02/21 18:20), 編輯推噓0(005)
留言5則, 2人參與, 最新討論串2/3 (看更多)
※ 引述《guitarpl (撞牆期)》之銘言: : 小弟剛接觸Python不久 : 用的是Python3.2 : 教材是深入淺出Python這本書 : 在做第二章套件的部分時 : 將setup.py(安裝) : 與nester.py(模組) 放入nester資料夾 : 並將nester放置於Python資料夾中 : 然後再cmd中輸入 : C:\Python32\nester\setup.py install : 會執行一小段 然後出現 : file nester.py(for module nester) not found 的訊息 : 到這邊就卡關了,不管nester放到哪 改路徑都一樣, : 請問我的步驟上面有甚麼問題?? : 謝謝 from distutils.core import setup setup{ name = 'nester', version = '1.0.0', PY_module = ['nester'], author = 'hfpython', author_email = 'hfpython@headfirstlabs.com', url = 'http://www.headfirstlabs.com', discription = 'A simple printer of nested lists', } 以上是setup.py的內容 是照著書上的範例打的@@ 不知道是哪邊有錯誤?? -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 219.85.185.14

02/21 20:56, , 1F
steup 後面是小括號()吧?
02/21 20:56, 1F

02/21 21:28, , 2F
喔對 是小括號XD 不過我原本程式也是小括號 這是另外
02/21 21:28, 2F

02/21 21:28, , 3F
打的
02/21 21:28, 3F

02/21 21:29, , 4F
發現原因了..cmd必須要在該目錄下面執行 直接打路徑就會
02/21 21:29, 4F

02/21 21:29, , 5F
發生找不到的情況 XD
02/21 21:29, 5F
文章代碼(AID): #1FGt092m (Python)
文章代碼(AID): #1FGt092m (Python)