Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
apachedex
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
2
Merge Requests
2
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
apachedex
Commits
06b24373
Commit
06b24373
authored
Apr 14, 2013
by
Vincent Pelletier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Enable Python3 support in setup.py .
parent
4a9737a9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
5 deletions
+13
-5
setup.py
setup.py
+13
-5
No files found.
setup.py
View file @
06b24373
from
os.path
import
join
,
exists
from
setuptools
import
setup
,
find_packages
import
hashlib
import
os
import
sys
import
urllib
extra
=
{}
if
sys
.
version_info
>=
(
3
,
):
extra
[
'use_2to3'
]
=
True
from
urllib.request
import
urlretrieve
else
:
from
urllib
import
urlretrieve
FLOT_SHA
=
'aefe4e729b2d14efe6e8c0db359cb0e9aa6aae52'
FLOT_AXISLABELS_SHA
=
'80453cd7fb8a9cad084cf6b581034ada3339dbf8'
...
...
@@ -38,8 +44,8 @@ _file_dirname = os.path.dirname(__file__)
def
download
(
url
,
filename
,
hexdigest
):
filename
=
join
(
_file_dirname
,
'apachedex'
,
filename
)
if
not
exists
(
filename
):
url
lib
.
url
retrieve
(
url
,
filename
)
if
hashlib
.
md5
(
open
(
filename
).
read
()).
hexdigest
()
!=
hexdigest
:
urlretrieve
(
url
,
filename
)
if
hashlib
.
md5
(
open
(
filename
,
'rb'
).
read
()).
hexdigest
()
!=
hexdigest
:
raise
EnvironmentError
(
'Checksum mismatch downloading %r'
%
filename
)
for
filename
,
(
url
,
hexdigest
)
in
DEPS
.
items
():
...
...
@@ -54,7 +60,7 @@ description = open(join(_file_dirname, 'README')).read()
setup
(
name
=
'APacheDEX'
,
version
=
'1.3.2'
,
description
=
(
x
for
x
in
description
.
splitlines
()
if
x
.
strip
()).
next
(
),
description
=
next
(
x
for
x
in
description
.
splitlines
()
if
x
.
strip
()
),
long_description
=
".. contents::
\
n
\
n
"
+
description
,
author
=
'Vincent Pelletier'
,
author_email
=
'vincent@nexedi.com'
,
...
...
@@ -66,6 +72,7 @@ setup(
'License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)'
,
'Operating System :: OS Independent'
,
'Programming Language :: Python :: 2.7'
,
'Programming Language :: Python :: 3'
,
'Programming Language :: Python :: Implementation :: PyPy'
,
'Programming Language :: Python :: Implementation :: CPython'
,
'Topic :: System :: Logging'
,
...
...
@@ -79,7 +86,8 @@ setup(
],
},
package_data
=
{
'apachedex'
:
DEPS
.
keys
(
)
+
[
'apachedex.js'
,
'apachedex.css'
],
'apachedex'
:
list
(
DEPS
.
keys
()
)
+
[
'apachedex.js'
,
'apachedex.css'
],
},
zip_safe
=
True
,
**
extra
)
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