Last active
February 27, 2018 19:24
-
-
Save bonfus/b6c66d7974327b2b61d7e2a19830a260 to your computer and use it in GitHub Desktop.
Install muesr from within a MantidPlot shell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# === This works inside the MantiPlot shell on Win 7 === | |
import subprocess | |
# install phase | |
print(subprocess.Popen("python -m pip install --upgrade pip",shell=True,stdout=subprocess.PIPE,stderr=subprocess.PIPE,stdin=subprocess.PIPE).communicate()) | |
print(subprocess.Popen("python -m pip install --user --upgrade mulfc muesr",shell=True,stdout=subprocess.PIPE,stderr=subprocess.PIPE,stdin=subprocess.PIPE).communicate()) | |
# use phase | |
import sys, site | |
sys.path.insert(0,site.USER_SITE) | |
# === This works on Mantid Notebook === | |
import pip | |
pip.main("install --user --upgrade muLFC muesr".split()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Added upgrade as default