Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using our own utils.system() for the setup.py cal #58

Merged
merged 2 commits into from
Jul 17, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@ Changelog for zest.releaser
3.52 (unreleased)
-----------------

- Nothing changed yet.
- Fixed "longtest" command when run with a python without setuptools
installed. Similar fix to the one in 3.51.
See https://github.com/zestsoftware/zest.releaser/issues/57
[reinout]


3.51 (2014-07-17)
Expand Down
16 changes: 9 additions & 7 deletions zest/releaser/longtest.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
"""Do the checks and tasks that have to happen before doing a release.
"""
import logging
import os
import sys
import webbrowser
import tempfile
import os
import webbrowser

from zest.releaser import utils
from zest.releaser.utils import system

logger = logging.getLogger(__name__)

Expand All @@ -15,11 +16,12 @@ def show_longdesc():
filename1 = tempfile.mktemp()
filename2 = tempfile.mktemp()
filename2 = filename2 + '.html'
error = os.system(utils.setup_py('--long-description > %s' %
filename1))
if error:
logging.error('Error generating long description.')
sys.exit()
# Note: for the setup.py call we use system() from our utils module. This
# makes sure the python path is set up right.
# For the other calls we use os.system(), because that returns an error
# code which we need.
system(utils.setup_py('--long-description > %s' %
filename1))
error = os.system('rst2html.py %s > %s' % (filename1, filename2))
if error:
# On Linux it needs to be 'rst2html', without the '.py'
Expand Down