Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
85ea5884
Commit
85ea5884
authored
Jun 09, 2003
by
Jens Vagelpohl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- consult other version.txt variations for version information for product
parent
59d8d375
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
2 deletions
+16
-2
doc/CHANGES.txt
doc/CHANGES.txt
+4
-0
lib/python/App/Product.py
lib/python/App/Product.py
+12
-2
No files found.
doc/CHANGES.txt
View file @
85ea5884
...
@@ -57,6 +57,10 @@ Zope Changes
...
@@ -57,6 +57,10 @@ Zope Changes
Bugs Fixed
Bugs Fixed
- Product initialization would only consult a file named "version.txt"
to read version information. Now it will check version.txt, VERSION.txt
and VERSION.TXT.
- Collector #928: DateIndex ignored timezones when indexing and
- Collector #928: DateIndex ignored timezones when indexing and
querying
querying
...
...
lib/python/App/Product.py
View file @
85ea5884
...
@@ -489,12 +489,22 @@ class Distribution:
...
@@ -489,12 +489,22 @@ class Distribution:
def
initializeProduct
(
productp
,
name
,
home
,
app
):
def
initializeProduct
(
productp
,
name
,
home
,
app
):
# Initialize a levered product
# Initialize a levered product
products
=
app
.
Control_Panel
.
Products
products
=
app
.
Control_Panel
.
Products
fver
=
''
if
hasattr
(
productp
,
'__import_error__'
):
ie
=
productp
.
__import_error__
if
hasattr
(
productp
,
'__import_error__'
):
ie
=
productp
.
__import_error__
else
:
ie
=
None
else
:
ie
=
None
try
:
fver
=
open
(
home
+
'/version.txt'
).
read
().
strip
()
# Retrieve version number from any suitable version.txt
except
:
fver
=
''
for
fname
in
(
'version.txt'
,
'VERSION.txt'
,
'VERSION.TXT'
):
try
:
fpath
=
os
.
path
.
join
(
home
,
fname
)
fhandle
=
open
(
fpath
,
'r'
)
fver
=
fhandle
.
read
().
strip
()
fhandle
.
close
()
break
except
IOError
:
continue
old
=
None
old
=
None
try
:
try
:
if
ihasattr
(
products
,
name
):
if
ihasattr
(
products
,
name
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment