Skip to content

Commit

Permalink
Add a new recipe for shigapass (bioconda#47806)
Browse files Browse the repository at this point in the history
* Added a new recipe for shigapass

* Updated tests

* updated build requirements
  • Loading branch information
ramsainanduri authored May 14, 2024
1 parent 957c6af commit 4a79983
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 0 deletions.
29 changes: 29 additions & 0 deletions recipes/shigapass/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#!/bin/bash

# Copy shell script to bin
mkdir -p $PREFIX/bin
cp SCRIPT/ShigaPass.sh $PREFIX/bin

# Create folder to copy database to
target=${PREFIX}/share/${PKG_NAME}-${PKG_VERSION}
mkdir -p ${target}/db
touch ${target}/db/.empty

# Unzip test files
gunzip Example/Input/*.fasta.gz

# Build index
bash SCRIPT/ShigaPass.sh -l Example/Input/ShigaPass_test.txt -o Example/ShigaPass_Results -p SCRIPT/ShigaPass_DataBases -u -k

# Copy ShigaPass db to target
cp -r SCRIPT/ShigaPass_DataBases/* ${target}/db

# Set ShigaPass DB PATH variable on env activation
mkdir -p ${PREFIX}/etc/conda/activate.d ${PREFIX}/etc/conda/deactivate.d
cat <<EOF >> ${PREFIX}/etc/conda/activate.d/shigapass.sh
export SP_DB_PATH=${target}/db/
EOF

cat <<EOF >> ${PREFIX}/etc/conda/deactivate.d/shigapass.sh
unset SP_DB_PATH
EOF
34 changes: 34 additions & 0 deletions recipes/shigapass/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{% set name = "ShigaPass" %}
{% set version = "1.5.0" %}

package:
name: "{{ name|lower }}"
version: {{ version }}

source:
url: https://github.com/imanyass/{{ name }}/archive/refs/tags/v{{ version }}.tar.gz
sha256: b07299943cd7bbe1f778b57152b6cd7e92cc8640ffd7192fde91dd1efcc99ead

build:
number: 0
noarch: generic
run_exports:
- {{ pin_subpackage('shigapass', max_pin="x") }}

requirements:
build:
- blast
run:
- blast

test:
commands:
- blastn -h
- makeblastdb -h
- bash ShigaPass.sh -h

about:
home: https://github.com/imanyass/ShigaPass/
license: GPL3
summary: 'ShigaPass: An in silico tool to predict Shigella serotypes'
license_file: LICENSE

0 comments on commit 4a79983

Please sign in to comment.