Skip to content

Commit

Permalink
Travis scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
mmcauliffe committed Jun 15, 2016
1 parent 130c9f0 commit 4ca2ddf
Show file tree
Hide file tree
Showing 3 changed files with 92 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
language: python
python:
- 3.5
branches:
only:
- master
notifications:
email: false

sudo: true

before_install:
- sudo rm -rf /dev/shm
- sudo ln -s /run/shm /dev/shm
- bash continuous-integration/travis/install.sh

# Install packages
install:
- export PATH="$HOME/miniconda/miniconda/bin:$PATH"
- source activate test-environment
- which python
- conda list

before_script:
- python thirdparty/kaldibinaries $HOME/kaldi

# Run test
script:
- "coverage run --source=aligner setup.py test"

# Calculate coverage
after_success:
- coveralls

cache:
directories:
- $HOME/miniconda
- $HOME/tools
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
Copyright (c) 2016 Montreal Corpus Tools


Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
33 changes: 33 additions & 0 deletions continuous-integration/travis/install.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/bin/sh
set -e
#check to see if miniconda folder is empty
if [ ! -d "$HOME/miniconda/miniconda/envs/test-environment" ]; then
wget http://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh
chmod +x miniconda.sh
./miniconda.sh -b -p $HOME/miniconda/miniconda
export PATH="$HOME/miniconda/miniconda/bin:$PATH"
conda config --set always_yes yes --set changeps1 no
conda update -q conda
conda info -a
conda create -q -n test-environment python=3.5 scipy pytest setuptools
source activate test-environment
which python
pip install -q coveralls coverage textgrid tqdm
else
echo "Miniconda already installed."
fi

if [ ! -d "$HOME/tools/kaldi" ]; then
mkdir -p $HOME/tools
cd tools
git clone https://github.com/kaldi-asr/kaldi.git kaldi --origin upstream
cd kaldi/tools
extras/check_dependencies.sh
make
cd ../src
./configure
make depend
make
else
echo "Kaldi already installed."
fi

0 comments on commit 4ca2ddf

Please sign in to comment.