-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from allanleal/enable-ci
Implement travis and appveyor ci recipes
- Loading branch information
Showing
8 changed files
with
95 additions
and
2 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
language: cpp | ||
|
||
os: | ||
- linux | ||
- osx | ||
|
||
cache: | ||
directories: | ||
- $HOME/miniconda | ||
|
||
install: | ||
- bash ci/travis/install.sh | ||
|
||
script: | ||
- bash ci/travis/test.sh | ||
|
||
before_cache: | ||
- rm -f $HOME/miniconda/envs/thermofun/conda-meta/history* # Delete these history files to prevent a new cache upload step. |
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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
image: | ||
# - Visual Studio 2015 | ||
- Visual Studio 2017 | ||
|
||
build: | ||
parallel: true | ||
|
||
platform: | ||
- x64 | ||
|
||
configuration: | ||
- Release | ||
|
||
environment: | ||
CONDA_DIR: C:\Miniconda36-x64 | ||
|
||
matrix: | ||
fast_finish: true | ||
|
||
init: | ||
- set PATH=%CONDA_DIR%;%CONDA_DIR%\Scripts;%CONDA_DIR%\Library\bin;%PATH% | ||
|
||
install: | ||
- call ci\appveyor\install.bat | ||
|
||
build_script: | ||
- call ci\appveyor\build.bat | ||
|
||
test_script: | ||
- call ci\appveyor\test.bat |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
if "%APPVEYOR_BUILD_WORKER_IMAGE%"=="Visual Studio 2017" ( | ||
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvars64.bat" | ||
) | ||
if "%APPVEYOR_BUILD_WORKER_IMAGE%"=="Visual Studio 2015" ( | ||
call "C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.cmd" /x64 | ||
call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x86_amd64 | ||
) | ||
|
||
echo "Configuring..." | ||
cmake -S . -B build | ||
echo "Building..." | ||
cmake --build build --config %CONFIGURATION% --target install |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
conda config --set always_yes yes --set changeps1 no | ||
conda config --add channels conda-forge | ||
conda install conda-devenv | ||
conda update -q conda | ||
conda info -a | ||
conda devenv | ||
call activate thermofun |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
REM call build\test\%CONFIGURATION%\tests.exe |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
if [ ! -f $HOME/miniconda/bin/conda ]; then | ||
echo "Downloading and installing miniconda" | ||
if [ $TRAVIS_OS_NAME = "linux" ]; then OS=Linux-x86_64; else OS=MacOSX-x86_64; fi | ||
wget -O miniconda.sh https://repo.continuum.io/miniconda/Miniconda3-latest-$OS.sh | ||
rm -rf $HOME/miniconda | ||
bash miniconda.sh -b -p $HOME/miniconda | ||
fi | ||
if [ ! -f $HOME/miniconda/bin/conda ]; then | ||
echo ERROR: conda was not installed. | ||
exit 1 | ||
fi | ||
bash $HOME/miniconda/etc/profile.d/conda.sh | ||
export PATH=$HOME/miniconda/bin/:$PATH | ||
conda config --set always_yes yes --set changeps1 no | ||
conda config --add channels conda-forge | ||
conda install conda-devenv | ||
conda update -q conda | ||
conda info -a | ||
conda devenv | ||
source activate thermofun | ||
mkdir build | ||
cd build | ||
cmake .. -GNinja | ||
ninja |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# ./build/test/tests |