forked from iiasa/ixmp
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathinstall.bat
39 lines (31 loc) · 834 Bytes
/
install.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
cd > .foo
set /p IXMP=<.foo
del .foo
echo %IXMP%
python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())" > .foo
set /p RPTH=<.foo
del .foo
echo %RPTH%
@echo off
python setup.py install
if %errorlevel% neq 0 GOTO InstallError
where /q r
IF ERRORLEVEL 1 (
ECHO No valid installation of R found, skipped build and installation of R package.
) ELSE (
rscript rixmp/build_rixmp.R [--verbose]
rscript retixmp/build_retixmp.R [--verbose]
)
setx IXMP_PATH "%IXMP%"
setx IXMP_R_PATH "%RPTH%/ixmp"
py.test tests/
pause
exit
@rem install error
:InstallError
echo =====================================================
echo There was an error during the install process!
echo Make sure that there is no instance of ixmp running
echo =====================================================
pause
exit