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
Yusei Tahara
slapos.buildout
Commits
be208c05
Commit
be208c05
authored
Jun 20, 2007
by
Jim Fulton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed careless bug in computation of exe file names.
Also rearranged some code to work with emacs python mode. :)
parent
85629419
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
6 deletions
+11
-6
src/zc/buildout/easy_install.py
src/zc/buildout/easy_install.py
+11
-6
No files found.
src/zc/buildout/easy_install.py
View file @
be208c05
...
@@ -28,11 +28,13 @@ import setuptools.package_index
...
@@ -28,11 +28,13 @@ import setuptools.package_index
import
setuptools.archive_util
import
setuptools.archive_util
import
zc.buildout
import
zc.buildout
def
realpath
(
path
):
return
path
try
:
try
:
realpath
=
os
.
path
.
realpath
realpath
=
os
.
path
.
realpath
except
AttributeError
:
except
AttributeError
:
def
realpath
(
path
):
pass
return
path
default_index_url
=
os
.
environ
.
get
(
'buildout-testing-index-url'
)
default_index_url
=
os
.
environ
.
get
(
'buildout-testing-index-url'
)
...
@@ -841,6 +843,7 @@ def _script(module_name, attrs, path, dest, executable, arguments,
...
@@ -841,6 +843,7 @@ def _script(module_name, attrs, path, dest, executable, arguments,
script
=
dest
script
=
dest
if
sys
.
platform
==
'win32'
:
if
sys
.
platform
==
'win32'
:
dest
+=
'-script.py'
dest
+=
'-script.py'
contents
=
script_template
%
dict
(
contents
=
script_template
%
dict
(
python
=
executable
,
python
=
executable
,
path
=
path
,
path
=
path
,
...
@@ -853,10 +856,11 @@ def _script(module_name, attrs, path, dest, executable, arguments,
...
@@ -853,10 +856,11 @@ def _script(module_name, attrs, path, dest, executable, arguments,
if
sys
.
platform
==
'win32'
:
if
sys
.
platform
==
'win32'
:
# generate exe file and give the script a magic name:
# generate exe file and give the script a magic name:
open
(
dest
+
'.exe'
,
'wb'
).
write
(
exe
=
script
+
'.exe'
open
(
exe
,
'wb'
).
write
(
pkg_resources
.
resource_string
(
'setuptools'
,
'cli.exe'
)
pkg_resources
.
resource_string
(
'setuptools'
,
'cli.exe'
)
)
)
generated
.
append
(
dest
+
'.exe'
)
generated
.
append
(
exe
)
if
changed
:
if
changed
:
open
(
dest
,
'w'
).
write
(
contents
)
open
(
dest
,
'w'
).
write
(
contents
)
...
@@ -899,10 +903,11 @@ def _pyscript(path, dest, executable):
...
@@ -899,10 +903,11 @@ def _pyscript(path, dest, executable):
if
sys
.
platform
==
'win32'
:
if
sys
.
platform
==
'win32'
:
# generate exe file and give the script a magic name:
# generate exe file and give the script a magic name:
open
(
dest
+
'.exe'
,
'wb'
).
write
(
exe
=
script
+
'.exe'
open
(
exe
,
'wb'
).
write
(
pkg_resources
.
resource_string
(
'setuptools'
,
'cli.exe'
)
pkg_resources
.
resource_string
(
'setuptools'
,
'cli.exe'
)
)
)
generated
.
append
(
dest
+
'.exe'
)
generated
.
append
(
exe
)
if
changed
:
if
changed
:
open
(
dest
,
'w'
).
write
(
contents
)
open
(
dest
,
'w'
).
write
(
contents
)
...
...
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