[Zope-CVS] CVS: Packages/zpkgtools/zpkgtools - app.py:1.26
Fred L. Drake, Jr.
fred at zope.com
Fri Apr 16 14:42:07 EDT 2004
Update of /cvs-repository/Packages/zpkgtools/zpkgtools
In directory cvs.zope.org:/tmp/cvs-serv12688
Modified Files:
app.py
Log Message:
For collection and application distributions, use the provided README
or README.txt as a top-level README.txt; this overrides the cruddy
generated README.txt.
=== Packages/zpkgtools/zpkgtools/app.py 1.25 => 1.26 ===
--- Packages/zpkgtools/zpkgtools/app.py:1.25 Thu Apr 15 15:13:52 2004
+++ Packages/zpkgtools/zpkgtools/app.py Fri Apr 16 14:42:05 2004
@@ -120,9 +120,11 @@
"PACKAGE_VERSION": self.options.version,
}
appsupport = os.path.join(zpkgtools.__path__[0], "appsupport")
+ readme_txt = os.path.join(self.destination, "README.txt")
+ if not os.path.exists(readme_txt):
+ self.copy_template(appsupport, "README.txt", metavars)
self.copy_template(appsupport, "configure", metavars)
self.copy_template(appsupport, "Makefile.in", metavars)
- self.copy_template(appsupport, "README.txt", metavars)
self.generate_collection_setup(self.destination, self.resource_name,
packages, collections,
filename="install.py")
@@ -151,6 +153,15 @@
deps = self.add_component("collection",
self.resource_name,
self.source)
+ readme = os.path.join(self.source, "README")
+ readme_txt = readme + ".txt"
+ output_readme_txt = os.path.join(self.destination, "README.txt")
+ if os.path.isfile(readme_txt):
+ shutil.copy2(readme_txt, output_readme_txt)
+ self.ip.add_output(output_readme_txt)
+ elif os.path.isfile(readme):
+ shutil.copy2(readme, output_readme_txt)
+ self.ip.add_output(output_readme_txt)
remaining = deps - self.handled_resources
collections = []
packages = []
More information about the Zope-CVS
mailing list