Mercurial > repos > devteam > data_manager_picard_index_builder
comparison data_manager/picard_index_builder.py @ 2:b99040168706 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/data_managers/data_manager_picard_index_builder commit 59ee07d9786f1a090053b4a13192247872389d61
author | iuc |
---|---|
date | Mon, 10 Apr 2017 06:06:23 -0400 |
parents | dc28cd6a1d44 |
children | ae080ff506fd |
comparison
equal
deleted
inserted
replaced
1:dc28cd6a1d44 | 2:b99040168706 |
---|---|
29 # TODO: allow multiple FASTA input files | 29 # TODO: allow multiple FASTA input files |
30 fasta_base_name = os.path.split( fasta_filename )[-1] | 30 fasta_base_name = os.path.split( fasta_filename )[-1] |
31 prefix = os.path.splitext( fasta_base_name )[0] | 31 prefix = os.path.splitext( fasta_base_name )[0] |
32 sym_linked_fasta_filename = os.path.join( target_directory, fasta_base_name ) | 32 sym_linked_fasta_filename = os.path.join( target_directory, fasta_base_name ) |
33 os.symlink( fasta_filename, sym_linked_fasta_filename ) | 33 os.symlink( fasta_filename, sym_linked_fasta_filename ) |
34 args = [ 'java', '-Xmx4G', '-jar', os.path.join( os.environ[ 'JAVA_JAR_PATH' ], 'CreateSequenceDictionary.jar' ), 'R=%s' % sym_linked_fasta_filename, 'O=%s.dict' % prefix ] | 34 args = [ 'picard', 'CreateSequenceDictionary', 'R=%s' % sym_linked_fasta_filename, 'O=%s.dict' % prefix ] |
35 proc = subprocess.Popen( args=args, shell=False, cwd=target_directory ) | 35 proc = subprocess.Popen( args=args, shell=False, cwd=target_directory ) |
36 return_code = proc.wait() | 36 return_code = proc.wait() |
37 if return_code: | 37 if return_code: |
38 print("Error building index.", file=sys.stderr) | 38 print("Error building index.", file=sys.stderr) |
39 sys.exit( return_code ) | 39 sys.exit( return_code ) |