Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.buildout
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
Łukasz Nowak
slapos.buildout
Commits
1fc67a9c
Commit
1fc67a9c
authored
Jun 11, 2012
by
Jim Fulton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Check hygene before importing site or installing distribute.
parent
493394b7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
13 deletions
+14
-13
dev.py
dev.py
+14
-13
No files found.
dev.py
View file @
1fc67a9c
...
...
@@ -26,13 +26,26 @@ for d in 'eggs', 'develop-eggs', 'bin', 'parts':
if
os
.
path
.
isdir
(
'build'
):
shutil
.
rmtree
(
'build'
)
nosite
=
'site'
not
in
sys
.
modules
######################################################################
# Make sure we have a relatively clean environment
try
:
import
pkg_resources
,
setuptools
except
ImportError
:
pass
else
:
raise
SystemError
(
"Buildout development with a pre-installed setuptools or "
"distribute is not supported.%s"
%
(
''
if
nosite
else
' Try running with -S option to Python.'
))
######################################################################
# handle -S
def
normpath
(
p
):
return
p
[:
-
1
]
if
p
.
endswith
(
os
.
path
.
sep
)
else
p
nosite
=
'site'
not
in
sys
.
modules
if
nosite
:
# They've asked not to import site. Cool, but distribute is going to
# import it anyway, so we're going to have to clean up. :(
...
...
@@ -42,18 +55,6 @@ if nosite:
else
:
to_remove
=
()
######################################################################
# Make sure we have a relatively clean environment
try
:
import
pkg_resources
,
setuptools
except
ImportError
:
pass
else
:
raise
SystemError
(
"Buildout development with a pre-installed setuptools or "
"distribute is not supported.%s"
%
(
''
if
nosite
else
' Try running with -S option to Python.'
))
######################################################################
# Install distribute
ez
=
{}
...
...
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