Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Franck Pommereau
/
snakes
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
Franck Pommereau
2016-11-16 09:35:35 +0100
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
a96c6718285f758ac5e8a4268e509e08c767fee1
a96c6718
1 parent
6cdce0ee
removed deprecated os.path.walk from setup.py (GitHub issue #11)
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
setup.py
setup.py
View file @
a96c671
#!/usr/bin/env python
import
subprocess
from
distutils.core
import
setup
def
doc_files
()
:
...
...
@@ -18,16 +17,17 @@ def doc_files () :
def
resources
(
root
)
:
collected
=
[
"*.txt"
,
"*.html"
,
"*.css"
,
"*.js"
,
"*.png"
,
"*.jpg"
,
"*.ttf"
,
"*.eot"
,
"*.woff"
,
"*.svg"
,
"*.map"
]
import
fnmatch
,
os.path
import
fnmatch
,
os
,
os
.path
result
=
[]
baselen
=
len
(
root
.
rstrip
(
os
.
sep
)
.
rsplit
(
os
.
sep
,
1
)[
0
])
+
len
(
os
.
sep
)
def
addfiles
(
_
,
dirname
,
filenames
)
:
def
addfiles
(
dirname
,
filenames
)
:
for
name
in
filenames
:
for
glob
in
collected
:
if
fnmatch
.
fnmatch
(
name
,
glob
)
:
result
.
append
(
os
.
path
.
join
(
dirname
[
baselen
:],
name
))
break
os
.
path
.
walk
(
root
,
addfiles
,
None
)
for
dirname
,
_
,
files
in
os
.
walk
(
root
)
:
addfiles
(
dirname
,
files
)
return
result
try
:
...
...
Please
register
or
login
to post a comment