-
Notifications
You must be signed in to change notification settings - Fork 185
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* [fix] (template): Missing code in wrappers' doc. Error #187 * Wrapper tested * test written * format * file extension set to tsv * Update bio/bustools/text/environment.yaml Co-authored-by: tdayris <tdayris@gustaveroussy.fr> Co-authored-by: tdayris <thibault.dayris@gustaveroussy.fr> Co-authored-by: Johannes Köster <johannes.koester@uni-due.de>
- Loading branch information
1 parent
0ea245b
commit 00f60b7
Showing
7 changed files
with
78 additions
and
0 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,6 @@ | ||
channels: | ||
- conda-forge | ||
- bioconda | ||
- nodefaults | ||
dependencies: | ||
- bustools =0.41 |
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,13 @@ | ||
name: bustools text | ||
description: convert bus to tsv files | ||
url: https://github.com/BUStools/bustools#text | ||
author: | ||
- Thibault Dayris | ||
input: | ||
- list of bus files | ||
output: | ||
- Path to TSV output | ||
params: | ||
- extra: Optional parameters, besides `--o/-output` | ||
notes: | | ||
When multiple bus files are provided, only one TSV file is produced. |
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,26 @@ | ||
rule test_bustools_text: | ||
input: | ||
"file.bus", | ||
output: | ||
"file.tsv", | ||
threads: 1 | ||
params: | ||
extra="", | ||
log: | ||
"logs/bustools.log", | ||
wrapper: | ||
"master/bio/bustools/text" | ||
|
||
|
||
rule test_bustools_text_list: | ||
input: | ||
["file.bus", "file2.bus"], | ||
output: | ||
"file2.tsv", | ||
threads: 1 | ||
params: | ||
extra="--flags --pad", | ||
log: | ||
"logs/bustools.log", | ||
wrapper: | ||
"master/bio/bustools/text" |
Binary file not shown.
Binary file not shown.
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,21 @@ | ||
#!/usr/bin/env python3 | ||
# conding: utf-8 | ||
|
||
"""snakemake wrapper for bustool text""" | ||
|
||
|
||
__author__ = "Thibault Dayris" | ||
__copyright__ = "Copyright 2022, Thibault Dayris" | ||
__email__ = "thibault.dayris@gustaveroussy.fr" | ||
__license__ = "MIT" | ||
|
||
from snakemake.shell import shell | ||
|
||
log = snakemake.log_fmt_shell(stdout=True, stderr=True) | ||
extra = snakemake.params.get("extra", "") | ||
|
||
bus_files = snakemake.input[0] | ||
if isinstance(bus_files, list): | ||
bus_files = " ".join(bus_files) | ||
|
||
shell("bustools text --output {snakemake.output[0]} {extra} {bus_files} {log}") |
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