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

mach bootstrap - activate virtual env #24567

Merged
merged 2 commits into from Nov 15, 2019
Merged
Changes from 1 commit
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

Prev

mach bootstrap factor out common is_firefox check

  • Loading branch information
JoshMcguigan committed Oct 28, 2019
commit ecc1244e59507560f2a77d0fe3cd0a2e14d2af8d
@@ -223,14 +223,17 @@ class DummyContext(object):
pass


def bootstrap_command_only(topdir):
# See if we're inside a Firefox checkout.
def is_firefox_checkout(topdir):
parentdir = os.path.normpath(os.path.join(topdir, '..'))
is_firefox = os.path.isfile(os.path.join(parentdir,
'build/mach_bootstrap.py'))
return is_firefox


def bootstrap_command_only(topdir):
# we should activate the venv before importing servo.boostrap
# because the module requires non-standard python packages
_activate_virtualenv(topdir, is_firefox)
_activate_virtualenv(topdir, is_firefox_checkout(topdir))

from servo.bootstrap import bootstrap

@@ -273,10 +276,7 @@ def bootstrap(topdir):
print('You are running Python', platform.python_version())
sys.exit(1)

# See if we're inside a Firefox checkout.
parentdir = os.path.normpath(os.path.join(topdir, '..'))
is_firefox = os.path.isfile(os.path.join(parentdir,
'build/mach_bootstrap.py'))
is_firefox = is_firefox_checkout(topdir)

_activate_virtualenv(topdir, is_firefox)

ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.