Mercurial > repos > peterjc > blast2go
changeset 24:05eef6b222af draft
planemo upload for repository https://github.com/peterjc/galaxy_blast/tools/blast2go commit 6f3c1a8da279f3b34d3bc627c97713d8dfe5f8ed
author | peterjc |
---|---|
date | Fri, 15 May 2015 06:01:16 -0400 |
parents | 31cb702eb5a8 |
children | 242cf17c3bf9 |
files | tools/blast2go/README.rst tools/blast2go/blast2go.xml tools/blast2go/massage_xml_for_blast2go.py tools/blast2go/repository_dependencies.xml |
diffstat | 4 files changed, 47 insertions(+), 34 deletions(-) [+] |
line wrap: on
line diff
--- a/tools/blast2go/README.rst Thu Jul 31 05:40:57 2014 -0400 +++ b/tools/blast2go/README.rst Fri May 15 06:01:16 2015 -0400 @@ -1,7 +1,7 @@ Galaxy wrapper for Blast2GO for pipelines, b2g4pipe =================================================== -This wrapper is copyright 2011-2014 by Peter Cock, The James Hutton Institute +This wrapper is copyright 2011-2015 by Peter Cock, The James Hutton Institute (formerly SCRI, Scottish Crop Research Institute), UK. All rights reserved. See the licence text below (MIT licence). @@ -16,8 +16,10 @@ http://toolshed.g2.bx.psu.edu/view/peterjc/blast2go -References -========== +Citation +======== + +Please cite the following papers: Peter Cock, Bjoern Gruening, Konrad Paszkiewicz and Leighton Pritchard (2013). Galaxy tools and workflows for sequence analysis with applications @@ -46,8 +48,8 @@ ====================== Installation via the Galaxy Tool Shed should take care of the Galaxy side of -things, including the dependency on 'blast_datatypes' which defines the -'blastxml' file format. However, you will also probably need to configure +things, including the dependency on ``blast_datatypes`` which defines the +``blastxml`` file format. However, you will also probably need to configure the Blast2GO property file(s), for example if you have a local Blast2GO database (which we recommend for speed). @@ -62,30 +64,30 @@ * http://www.blast2go.com/data/blast2go/b2g4pipe_v2.5.zip -You can change the path by setting the B2G4PIPE environement variable to +You can change the path by setting the ``$B2G4PIPE`` environment variable to the desired folder, but by default the script looks for the JAR file here:: /opt/b2g4pipe_v2.5/blast2go.jar -To install the wrapper manually, first install 'blast_datatypes', then +To install the wrapper manually, first install ``blast_datatypes``, then copy or move the following files under the Galaxy tools folder, e.g. in a -tools/blast2go/ folder: +``tools/blast2go/`` folder: -* blast2go.xml (the Galaxy tool definition) -* blast2go.py (the Python wrapper script) -* massage_xml_for_blast2go.py (Python XML reformatting script) -* README.rst (this file) +- ``blast2go.xml`` (the Galaxy tool definition) +- ``blast2go.py`` (the Python wrapper script) +- ``massage_xml_for_blast2go.py`` (Python BLAST XML reformatting script) +- ``README.rst`` (this file) For a manual installation of the wrapper you will also need to modify the -tools_conf.xml file to tell Galaxy to offer the tool. We suggest putting +``tools_conf.xml`` file to tell Galaxy to offer the tool. We suggest putting it next to the NCBI BLAST+ wrappers. Just add the line:: <tool file="blast2go/blast2go.xml" /> -If you wish to run the unit tests, also add this to tools_conf.xml.sample -and move/copy the test-data files under Galaxy's test-data folder. Then:: +If you wish to run the unit tests, also move/copy the ``test-data/`` files +under Galaxy's ``test-data/`` folder. Then:: - $ ./run_functional_tests.sh -id blast2go + $ ./run_tests.sh -id blast2go Configuration @@ -162,6 +164,8 @@ of the Blast2GO command line tool. For now b2g4pipe v2.5 is still available as a free download. - Tool definition now embeds citation information. +v0.0.10 - Reorder XML elements (internal change only). + - Planemo for Tool Shed upload (``.shed.yml``, internal change only). ======= ====================================================================== @@ -175,23 +179,33 @@ As of September 2013, development is continuing on a dedicated GitHub repository: https://github.com/peterjc/galaxy_blast -For making the "Galaxy Tool Shed" http://toolshed.g2.bx.psu.edu/ tarball I use -the following command from the Galaxy root folder:: +For pushing a release to the test or main "Galaxy Tool Shed", use the following +Planemo commands (which requires you have set your Tool Shed access details in +``~/.planemo.yml`` and that you have access rights on the Tool Shed):: - $ tar -czf blast2go.tar.gz tools/blast2go/README.rst tools/blast2go/blast2go.xml tools/blast2go/blast2go.py tools/blast2go/massage_xml_for_blast2go.py tools/blast2go/repository_dependencies.xml tools/blast2go/tool_dependencies.xml tool-data/blast2go.loc.sample test-data/blastp_sample.xml test-data/blastp_sample.blast2go.tabular + $ planemo shed_upload --shed_target testtoolshed --check_diff ~/repositories/galaxy_blast/tools/blast2go/ + ... + +or:: + + $ planemo shed_upload --shed_target toolshed --check_diff ~/repositories/galaxy_blast/tools/blast2go/ + ... -Check this worked:: +To just build and check the tar ball, use:: - $ tar -tzf blast2go.tar.gz + $ planemo shed_upload --tar_only ~/repositories/galaxy_blast/tools/blast2go/ + ... + $ tar -tzf shed_upload.tar.gz + test-data/blastp_sample.blast2go.tabular + test-data/blastp_sample.xml + tool-data/blast2go.loc.sample tools/blast2go/README.rst + tools/blast2go/blast2go.py tools/blast2go/blast2go.xml - tools/blast2go/blast2go.py tools/blast2go/massage_xml_for_blast2go.py tools/blast2go/repository_dependencies.xml tools/blast2go/tool_dependencies.xml - tool-data/blast2go.loc.sample - test-data/blastp_sample.xml - test-data/blastp_sample.blast2go.tabular + Licence (MIT)
--- a/tools/blast2go/blast2go.xml Thu Jul 31 05:40:57 2014 -0400 +++ b/tools/blast2go/blast2go.xml Fri May 15 06:01:16 2015 -0400 @@ -1,16 +1,16 @@ -<tool id="blast2go" name="Blast2GO" version="0.0.9"> +<tool id="blast2go" name="Blast2GO" version="0.0.10"> <description>Maps BLAST results to GO annotation terms</description> <requirements> <requirement type="package" version="2.5">b2g4pipe</requirement> </requirements> - <command interpreter="python"> - blast2go.py "${xml}" "${prop.fields.path}" "${tab}" - </command> <stdio> <!-- Wrapper ensures anything other than zero is an error --> <exit_code range="1:" /> <exit_code range=":-1" /> </stdio> + <command interpreter="python"> + blast2go.py "${xml}" "${prop.fields.path}" "${tab}" + </command> <inputs> <param name="xml" type="data" format="blastxml" label="BLAST XML results" description="You must have run BLAST against a protein database such as the NCBI non-redundant (NR) database. Use BLASTX for nucleotide queries, BLASTP for protein queries." /> <param name="prop" type="select" label="Blast2GO settings" description="One or more configurations can be setup, such as using the Blast2GO team's server in Spain, or a local database.">
--- a/tools/blast2go/massage_xml_for_blast2go.py Thu Jul 31 05:40:57 2014 -0400 +++ b/tools/blast2go/massage_xml_for_blast2go.py Fri May 15 06:01:16 2015 -0400 @@ -21,7 +21,6 @@ """ import sys import os -import subprocess def stop_err(msg, error_level=1): """Print error message to stdout and quit with given error level.""" @@ -52,9 +51,9 @@ header += line if "<BlastOutput_program>blastx</BlastOutput_program>" in header: - print "BLASTX output identified" + print("BLASTX output identified") elif "<BlastOutput_program>blastp</BlastOutput_program>" in header: - print "BLASTP output identified" + print("BLASTP output identified") else: in_handle.close() stop_err("Expect BLASTP or BLASTX output") @@ -76,7 +75,7 @@ out_handle.close() in_handle.close() - print "Input has %i queries" % count + print("Input has %i queries" % count) if __name__ == "__main__":
--- a/tools/blast2go/repository_dependencies.xml Thu Jul 31 05:40:57 2014 -0400 +++ b/tools/blast2go/repository_dependencies.xml Fri May 15 06:01:16 2015 -0400 @@ -1,4 +1,4 @@ <?xml version="1.0"?> <repositories description="Requires BLAST XML and database datatype definitions."> - <repository changeset_revision="939a600f45e9" name="blast_datatypes" owner="devteam" toolshed="https://testtoolshed.g2.bx.psu.edu" /> + <repository changeset_revision="da92fef90117" name="blast_datatypes" owner="devteam" toolshed="https://testtoolshed.g2.bx.psu.edu" /> </repositories>