Skip to content

Latest commit

 

History

History
55 lines (43 loc) · 2.42 KB

mozphab-windows.rst

File metadata and controls

55 lines (43 loc) · 2.42 KB

Windows 10 MozPhab Installation Guide

Installing MozPhab including arcanist setup

Here are step-by-step instructions to getting MozPhab working on Windows 10 in a MozillaBuild environment. They should work for Git Bash and PowerShell as well. For the sake of this documentation we will use the terminal provided by running the C:\mozilla-build\start-shell.bat.

  1. Install the Microsoft Visual C++ 2017 Redistributable (x64) if you don't already have it. You can see if you have it through Settings -> Apps -> App & features. It is available at https://support.microsoft.com/en-ca/help/2977003/the-latest-supported-visual-c-downloads (vc_redist.x64.exe).

  2. If you don't have Git already installed (note that it is not currently packaged with MozillaBuild), you'll need to grab it from https://git-scm.com/download/win and install it.

  3. Run pip3 install MozPhab.

  4. Install PHP. The latest should work, e.g. PHP 7.2, VC15 x64 Non Thread Safe, from https://windows.php.net/download/. Download the Zip. Unzip it somewhere; the following instructions presume C:\PHP.

  5. Copy php.ini-development to php.ini in that same directory.

  6. Edit php.ini. The Arcanist docs say to remove the leading ; before ;extension=php_curl.dll. In PHP 7.2, this line is just ;extension=curl. Then find the line ;extension_dir = "ext" and change it to extension_dir = "C:\PHP\ext".

  7. Add moz-phab, php, and git to the $PATH variable. If you use MSYS (including MozillaBuild) exclusively, you can add this to ~/.bash_profile:

    export PATH=$PATH:/c/PHP/:/c/Program\ Files/Git/bin:/c/mozilla-build/Python3/Scripts
    
  8. Run php -i to verify that it is working. You should see "curl" listed in the Configuration section.

  9. Ensure running arc and moz-phab both work:

    $ moz-phab arc -h
    $ moz-phab -h
    

Upgrading a previous non-pip install of moz-phab to use pip

  1. Run pip3 install MozPhab.
  2. Ensure that your non-pip install of moz-phab is removed or renamed
  3. You may need to restart your shell for your changes to take effect. You can check using moz-phab version - if it works, you've successfully switched to moz-phab using pip.