Mercurial > repos > peterjc > mira4_assembler
comparison tools/mira4_0/mira4_make_bam.py @ 31:fd95aaef8818 draft
planemo upload for repository https://github.com/peterjc/galaxy_mira/tree/master/tools/mira4_0 commit bc3d484c5cd68ddcf456db2fff489d584aa2034c
author | peterjc |
---|---|
date | Wed, 10 Feb 2016 09:07:39 -0500 |
parents | 55ae131c5862 |
children | 56b421d59805 |
comparison
equal
deleted
inserted
replaced
30:b506e3b779fa | 31:fd95aaef8818 |
---|---|
4 import os | 4 import os |
5 import sys | 5 import sys |
6 import shutil | 6 import shutil |
7 import subprocess | 7 import subprocess |
8 import tempfile | 8 import tempfile |
9 | |
10 def sys_exit(msg, err=1): | |
11 sys.stderr.write(msg+"\n") | |
12 sys.exit(err) | |
13 | 9 |
14 def run(cmd, log_handle): | 10 def run(cmd, log_handle): |
15 try: | 11 try: |
16 child = subprocess.Popen(cmd, shell=True, | 12 child = subprocess.Popen(cmd, shell=True, |
17 stdout=subprocess.PIPE, | 13 stdout=subprocess.PIPE, |
87 | 83 |
88 if __name__ == "__main__": | 84 if __name__ == "__main__": |
89 mira_convert, maf_file, fasta_file, bam_file = sys.argv[1:] | 85 mira_convert, maf_file, fasta_file, bam_file = sys.argv[1:] |
90 msg = make_bam(mira_convert, maf_file, fasta_file, bam_file, sys.stdout) | 86 msg = make_bam(mira_convert, maf_file, fasta_file, bam_file, sys.stdout) |
91 if msg: | 87 if msg: |
92 sys_exit(msg) | 88 sys.exit(msg) |