Changes between Initial Version and Version 1 of DevNotes/DevGuide/CondaDevSetup5.0


Ignore:
Timestamp:
Sep 2, 2018 10:34:41 PM (6 years ago)
Author:
wojciech
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • DevNotes/DevGuide/CondaDevSetup5.0

    v1 v1  
     1= Easy Developer Setup for SasView 5.0 Using Anaconda = 
     2== Step 1 - Install Anaconda == 
     3Download the latest '''64-Bit''' Python '''3.6''' Installer from https://repo.continuum.io/archive/ (e.g. Anaconda3-5.2.0-Windows-x86_64.exe) and run it. 
     4 
     5 * The recommended destination folder is as good as any.  If you deviate from this then it's probably worthwhile to make sure the path is short and contains no spaces, and is not the same as any previous installation (one reader installed 64 bit on top of previous 32 bit, not a good idea). 
     6 
     7 * At the Advanced Options screen, you need to consider whether or not you want to make Anaconda your default version of Python.  Developers who do not work on multiple Python projects can just accept the defaults here. 
     8 
     9 * By default of Windows anaconda is installed for single user and not "everyone", which means you cannot run the conda command from an arbitrary command window. If you proceeded with default installation, you need to open Anaconda Prompt from Menu Start. Otherwise you can install anaconda for everyone, which requires root privileges. If "conda" is not a recognised command then add the install directory to your Windows user Path variable.[[BR]] 
     10 * If you have a failing reference to a "conda.binstar.org/!PeterParker/win-64/repodata.json" file, then edit this out of the anaconda start up file at users/username/.condarc as you may still have left it there from an older sasview installation system. 
     11 
     12== Step 2 - Download !SasView and sasmodels from github == 
     13If you don't have git installed, go to the GIT section below ([#anchor1 Step 7]) for instructions, otherwise simply run 
     14 
     15{{{ 
     16git clone https://github.com/SasView/sasview.git sasview 
     17git clone https://github.com/SasView/sasmodels.git sasmodels 
     18}}} 
     19 
     20== Step 3 checkout ESS GUI branch ==  
     21Go to folder:  
     22{{{ 
     23cd sasview  
     24}}} 
     25 
     26and run:  
     27{{{ 
     28git checkout ESS_GUI 
     29}}} 
     30 
     31== Step 4 - Install dependencies == 
     32Go to folder: 
     33 
     34{{{ 
     35sasview/build_tools/ 
     36}}} 
     37and create conda enviroment using yml specific for your platform (needs to be run from top-level not within a conda virtual environment) 
     38 
     39{{{ 
     40#Windows 
     41conda env create -f conda_qt5_win.yml 
     42 
     43#Mac OSX 
     44conda env create -f  conda_qt5_min_osx.yml 
     45 
     46#Linux 
     47conda env create -f conda_qt5_min_ubuntu.yml 
     48}}} 
     49=== Other dependencies === 
     50Note that in order to build the documentation, you will require a version of GNU Make (the `make` command). On Linux, you can obtain this with your package manager. On Windows 7, activate your new conda environment and run the following: 
     51 
     52{{{ 
     53conda install -c conda-forge make 
     54}}} 
     55On Windows 10, you may find that the `make` command does not work with the above method. You can find a Windows-compatible build of GNU Make here: http://gnuwin32.sourceforge.net/packages/make.htm Ensure that you add the install directory to your PATH. 
     56 
     57== Step 5 - activate conda enviroment == 
     58{{{ 
     59#Windows 
     60activate qt5_win 
     61 
     62else if running from inside a Git Bash shell use:  
     63source activate qt5_osx 
     64 
     65#Mac OSX and Linux 
     66source activate qt5_ubuntu 
     67}}} 
     68 
     69== Step 6 - run !SasView == 
     70You should be ready to run sasview.  Go to sasview directory and run 
     71 
     72{{{ 
     73 
     74#Windows 
     75python run.py 
     76 
     77#Mac OSX and Linux 
     78pythonw run.py 
     79 
     80To build the documentation you will still first need to do: 
     81 
     82python setup.py docs  
     83 
     84}}} 
     85 
     86== [=#anchor1 Step 7 - Install Git (Optional)] == 
     87Install Git for your platform by following instructions: 
     88 
     89{{{ 
     90https://git-scm.com/book/en/v2/Getting-Started-Installing-Git 
     91}}} 
     92When installing on Windows, it may be worthwhile to make sure "Use Git from the Windows Command Prompt" is selected, rather than "Use Git from Bash only".  This way you can use git from the same command line as you will use Anaconda. 
     93 
     94Set up your credentials: 
     95 
     96{{{ 
     97git config --global user.name "John Doe" 
     98git config --global user.email johndoe@example.com 
     99}}} 
     100If you work behind proxy remmber to configure 
     101 
     102{{{ 
     103e.g. git config --global http.proxy 192.168.1.1:XXXX  
     104}}}