Mercurial > repos > rmarenco > hubarchivecreator
diff util/subtools.py @ 10:acc233161f50 draft
planemo upload for repository https://github.com/goeckslab/hub-archive-creator commit 1b1063f90004764bcf504f4340738eca5c4b1f9d
author | rmarenco |
---|---|
date | Thu, 21 Jul 2016 05:58:51 -0400 |
parents | fb5e60d4d18a |
children | 25809f699cb3 |
line wrap: on
line diff
--- a/util/subtools.py Wed Jul 20 12:29:08 2016 -0400 +++ b/util/subtools.py Thu Jul 21 05:58:51 2016 -0400 @@ -39,20 +39,16 @@ return p -def faToTwoBit(fasta_file_name, mySpecieFolder): +def faToTwoBit(fasta_file_name, twoBitFile): """ This function call faToTwoBit UCSC tool, and return the twoBitFile :param fasta_file_name: :param mySpecieFolder: :return: """ - baseNameFasta = os.path.basename(fasta_file_name) - suffixTwoBit, extensionTwoBit = os.path.splitext(baseNameFasta) - nameTwoBit = suffixTwoBit + '.2bit' - with open(os.path.join(mySpecieFolder, nameTwoBit), 'w') as twoBitFile: - array_call = ['faToTwoBit', fasta_file_name, twoBitFile.name] - _handleExceptionAndCheckCall(array_call) + array_call = ['faToTwoBit', fasta_file_name, twoBitFile] + _handleExceptionAndCheckCall(array_call) return twoBitFile