Skip to content

Commit

Permalink
CLI changes to match bioconda release (#60)
Browse files Browse the repository at this point in the history
* Use env variable for version

* capture version from task_versioning

* fix typo

* add variable to github env

* rename to titan-gc to match bioconda release

* Update test_clearlabs.yml

* Update test_illumina_pe.yml

* Update test_illumina_se.yml

* Update test_ont.yml

* Update titan-gc.yml

* CI kicking my butt

* make pangolin docker match workflows

* match pangolin docker image
  • Loading branch information
rpetit3 authored Aug 17, 2021
1 parent 9b0c682 commit e75c864
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 17 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/titan-gc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
- name: Setup miniconda
uses: conda-incubator/setup-miniconda@v2
with:
activate-environment: titan-gc-cli
activate-environment: titan-gc
auto-activate-base: false

- name: Setup Titan CI Environment
Expand All @@ -30,13 +30,13 @@ jobs:
chmod 755 bin/*
cp bin/* ${CONDA_PREFIX}/bin
TITAN_GC_VERSION=$(grep "PHVG_Version=" tasks/task_versioning.wdl | sed -E 's/.*="PHVG v(.*)"/\1/')
export TITAN_GC_VERSION=$(TITAN_GC_VERSION)
TITAN_SHARE="${CONDA_PREFIX}/share/titan-gc-cli-${TITAN_GC_VERSION}"
echo "TITAN_GC_VERSION=${TITAN_GC_VERSION}" >> $GITHUB_ENV
TITAN_SHARE="${CONDA_PREFIX}/share/titan-gc-${TITAN_GC_VERSION}"
mkdir -p ${TITAN_SHARE}
mv conf/ tasks/ workflows/ ${TITAN_SHARE}
- name: Environment Information
run: uname -a && env && titan-gc-cli -h
run: uname -a && env && titan-gc -h

- name: Test Titan-GC Workflows
run: |
Expand Down
15 changes: 7 additions & 8 deletions bin/titan-gc-cli → bin/titan-gc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#! /bin/bash
# usage: titan-gc-cli [-h] [-i STR] [--inputs STR] [-o STR] [--outdir STR] [--options STR] [--verbose]
# usage: titan-gc [-h] [-i STR] [--inputs STR] [-o STR] [--outdir STR] [--options STR] [--verbose]
#
# titan-gc-cli - Run Titan GC on a set of samples.
# titan-gc - Run Titan GC on a set of samples.
#
# required arguments:
# -i STR, --inputs STR The JSON file to be used with Cromwell for inputs.
Expand All @@ -18,23 +18,22 @@ OPTIONS="0"
QUIET="0"
PROFILE="docker"
CONFIG="0"
VERSION="1.4.4"
TITAN_PATH=$(which titan-gc-cli | sed 's=bin/titan-gc-cli==')
TITAN_SHARE=${TITAN_PATH}/share/titan-gc-cli-${VERSION}
TITAN_PATH=$(which titan-gc | sed 's=bin/titan-gc==')
TITAN_SHARE=${TITAN_PATH}/share/titan-gc-${TITAN_GC_VERSION}
CROMWELL_JAR=$(which cromwell | sed 's=bin/cromwell=share/cromwell/cromwell.jar=')
LOG_LEVEL=ERROR
SINGULARITY_CACHE="${HOME}/.singularity/titan-cache"
CROMWELL_OPTS="${TITAN_SHARE}/conf/options.json"

version() {
echo "titan-gc-cli ${VERSION}"
echo "titan-gc ${TITAN_GC_VERSION}"
exit 0
}

usage() {
echo "usage: titan-gc-cli [-h] [-i STR] [--inputs STR] [-o STR] [--outdir STR] [--options STR] [--quiet]"
echo "usage: titan-gc [-h] [-i STR] [--inputs STR] [-o STR] [--outdir STR] [--options STR] [--quiet]"
echo ""
echo "titan-gc-cli - Run Titan GC on a set of samples."
echo "titan-gc - Run Titan GC on a set of samples."
echo ""
echo "required arguments:"
echo " -i STR, --inputs STR The JSON file to be used with Cromwell for inputs."
Expand Down
2 changes: 1 addition & 1 deletion tests/workflows/titan-gc/test_clearlabs.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
- name: titan_clearlabs
command: titan-gc-cli -i titan/clearlabs.json -o titan/clearlabs
command: titan-gc -i titan/clearlabs.json -o titan/clearlabs
tags:
- titan_gc
- titan_clearlabs
Expand Down
2 changes: 1 addition & 1 deletion tests/workflows/titan-gc/test_illumina_pe.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
- name: titan_illumina_pe
command: titan-gc-cli -i titan/illumina_pe.json -o titan/illumina_pe
command: titan-gc -i titan/illumina_pe.json -o titan/illumina_pe
tags:
- titan_gc
- titan_illumina_pe
Expand Down
2 changes: 1 addition & 1 deletion tests/workflows/titan-gc/test_illumina_se.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
- name: titan_illumina_se
command: titan-gc-cli -i titan/illumina_se.json -o titan/illumina_se
command: titan-gc -i titan/illumina_se.json -o titan/illumina_se
tags:
- titan_gc
- titan_illumina_se
Expand Down
2 changes: 1 addition & 1 deletion tests/workflows/titan-gc/test_ont.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
- name: titan_ont
command: titan-gc-cli -i titan/ont.json -o titan/ont
command: titan-gc -i titan/ont.json -o titan/ont
tags:
- titan_gc
- titan_ont
Expand Down
2 changes: 1 addition & 1 deletion workflows/wf_titan_gc.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ workflow titan_gc {

input {
Array[parseJSON] samples
String pangolin_docker_image = "staphb/pangolin:3.1.3-pangolearn-2021-06-15"
String pangolin_docker_image = "staphb/pangolin:3.1.11-pangolearn-2021-08-09"
}

scatter (sample in samples) {
Expand Down

0 comments on commit e75c864

Please sign in to comment.