summaryrefslogtreecommitdiffstats
path: root/Mac/scripts/MkDistr.py
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>2000-05-05 23:07:43 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>2000-05-05 23:07:43 (GMT)
commit68552ddece3246548633756d62433b723cbc1bce (patch)
treecdf4a83314a156d569f62fa73b6b1f8b34e5c974 /Mac/scripts/MkDistr.py
parentb8f820c5a98a10c5ad94cfec1569b7b80829c55d (diff)
downloadcpython-68552ddece3246548633756d62433b723cbc1bce.zip
cpython-68552ddece3246548633756d62433b723cbc1bce.tar.gz
cpython-68552ddece3246548633756d62433b723cbc1bce.tar.bz2
Automatically dump distribution folders where I want them, next to the vise scripts.
Diffstat (limited to 'Mac/scripts/MkDistr.py')
-rw-r--r--Mac/scripts/MkDistr.py15
1 files changed, 7 insertions, 8 deletions
diff --git a/Mac/scripts/MkDistr.py b/Mac/scripts/MkDistr.py
index a9c7937..028a422 100644
--- a/Mac/scripts/MkDistr.py
+++ b/Mac/scripts/MkDistr.py
@@ -208,15 +208,12 @@ class Main:
def __init__(self):
InitUI()
- fss, ok = macfs.GetDirectory('Source directory:')
- if not ok:
- sys.exit(0)
- os.chdir(fss.as_pathname())
+ os.chdir(sys.prefix)
if not os.path.isdir(':Mac:Distributions'):
os.mkdir(':Mac:Distributions')
- typedist = GetType()
- self.inc = IncMatcher(':Mac:Distributions:%s.include'%typedist)
- self.exc = ExcMatcher(':Mac:Distributions:%s.exclude'%typedist)
+ self.typedist = GetType()
+ self.inc = IncMatcher(':Mac:Distributions:%s.include'%self.typedist)
+ self.exc = ExcMatcher(':Mac:Distributions:%s.exclude'%self.typedist)
self.ui = MkDistrUI(self)
self.ui.mainloop()
@@ -259,7 +256,7 @@ class Main:
rv = rv + self.checkdir(d, 0)
return rv
- def run(self, destprefix):
+ def run(self):
missing = self.inc.checksourcetree()
if missing:
print '==== Missing source files ===='
@@ -267,6 +264,8 @@ class Main:
print i
print '==== Fix and retry ===='
return
+ destprefix = os.path.join(sys.prefix, ':Mac:Distributions:vise')
+ destprefix = os.path.join(destprefix, '%s Distribution'%self.typedist)
if not self.rundir(':', destprefix, 0):
return
self.rundir(':', destprefix, 1)