updates code to write config file (.ncbirc) once #310 #96
This file contains hidden or 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 workflow will install RGI dependencies, run tests and lint with a variety of Python versions | |
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python | |
name: Build RGI and test | |
on: | |
push: | |
branches: [ 'master' ] | |
pull_request: | |
branches: [ 'master' ] | |
workflow_dispatch: | |
env: | |
BLAST_VERSION: 2.16.0 | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: ["ubuntu-latest"] | |
python-version: ["3.7","3.8","3.9","3.10","3.11"] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
echo "start installing dependencies ..." | |
sudo apt-get -qq update | |
sudo apt-get -qq install -y prodigal tree | |
sudo apt-get -qq install -y libtbb-dev libbz2-dev liblzma-dev | |
sudo apt-get -qq install -y cmake g++ make | |
echo "install blast ..." | |
wget --quiet http://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/${BLAST_VERSION}/ncbi-blast-${BLAST_VERSION}+-x64-linux.tar.gz | |
tar xzf ncbi-blast-${BLAST_VERSION}+-x64-linux.tar.gz | |
sudo mv ncbi-blast-${BLAST_VERSION}+/bin/* /usr/bin | |
echo "install bowtie2 ..." | |
wget --quiet https://github.com/BenLangmead/bowtie2/releases/download/v2.5.4/bowtie2-2.5.4-linux-x86_64.zip | |
unzip -q bowtie2-2.5.4-linux-x86_64.zip | |
sudo mv bowtie2-2.5.4-linux-x86_64/bowtie2* /usr/bin | |
echo "install diamond ..." | |
wget --quiet http://github.com/bbuchfink/diamond/releases/download/v0.8.36/diamond-linux64.tar.gz | |
tar xzf diamond-linux64.tar.gz | |
sudo mv diamond /usr/bin | |
echo "install bwa ..." | |
git clone --quiet https://github.com/lh3/bwa.git | |
pushd bwa && make --quiet && sudo mv bwa /usr/bin && popd | |
echo "install jellyfish ..." | |
wget --quiet https://github.com/gmarcais/Jellyfish/releases/download/v2.2.10/jellyfish-linux | |
mv jellyfish-linux jellyfish && chmod +x jellyfish && sudo mv jellyfish /usr/bin | |
echo "install samtools ..." | |
wget --quiet https://github.com/samtools/samtools/releases/download/1.21/samtools-1.21.tar.bz2 | |
tar jxf samtools-1.21.tar.bz2 | |
pushd samtools-1.21 && ./configure --enable-silent-rules && make --quiet && sudo mv samtools /usr/bin && popd | |
echo "install bamtools ..." | |
wget --quiet https://github.com/pezmaster31/bamtools/archive/v2.5.2.tar.gz | |
tar xzf v2.5.2.tar.gz | |
pushd bamtools-2.5.2/ && mkdir build && cd build && cmake .. && make --quiet && sudo make install --quiet && popd | |
echo "install bedtools ..." | |
wget --quiet https://github.com/arq5x/bedtools2/releases/download/v2.31.1/bedtools-2.31.1.tar.gz | |
tar xzf bedtools-2.31.1.tar.gz | |
pushd bedtools2 && make --quiet && sudo mv bin/* /usr/bin && popd | |
echo "install kma ..." | |
git clone --quiet https://bitbucket.org/genomicepidemiology/kma.git | |
pushd kma && make --quiet && sudo mv kma /usr/bin && popd | |
python -m pip install --upgrade --quiet pip | |
#python -m pip install --quiet flake8 pytest | |
python -m pip install --quiet pytest | |
python -m pip install --quiet setuptools | |
- name: Install rgi | |
run: | | |
echo "=====> install rgi ..." | |
echo `pwd` | |
pip3 install -r requirements.txt | |
pip3 install setuptools | |
pip3 install . | |
- name: Check versions | |
run: | | |
echo "=====> check versions installed ..." | |
echo `pwd` | |
blastp -version | |
bowtie2 --version | |
diamond --version | |
jellyfish --version | |
samtools --version | |
bamtools --version | |
bedtools --version | |
kma -v | |
rgi main --version | |
prodigal -v | |
- name: Test with pytest | |
run: | | |
bash test.sh |