Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add new recipes for itolapi #21072

Merged
merged 10 commits into from
Mar 26, 2020
68 changes: 68 additions & 0 deletions recipes/itolapi/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
{% set name = "itolapi" %}
{% set version = "4.0.0" %}

package:
name: '{{ name|lower }}'
version: '{{ version }}'

source:
url: https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz
sha256: 161759384603664ff21ad6ae412a01549ce19436fc6959478d932d9b6c9915c4

build:
noarch: generic
cokelaer marked this conversation as resolved.
Show resolved Hide resolved
number: 0
script: python setup.py install --single-version-externally-managed --record=record.txt
marcelm marked this conversation as resolved.
Show resolved Hide resolved

requirements:
host:
- python<3.8
marcelm marked this conversation as resolved.
Show resolved Hide resolved
- setuptools
- requests >=2.0,<3.0
marcelm marked this conversation as resolved.
Show resolved Hide resolved
run:
- python<3.8
- requests >=2.0,<3.0

test:
imports:
- itolapi
- itolapi.tests
requires:
- codecov >=2.0.9,<3.0.0
- coverage >=4.5.0,<5.0.0
- mock >=3.0.0,<4.0.0

about:
home: https://github.com/albertyw/itolapi
license: MIT License
license_family: MIT
license_file: ''
marcelm marked this conversation as resolved.
Show resolved Hide resolved
summary: API for interacting with itol.embl.de
description: "iTOL Python API\n===============\n\n|PyPI|\n|Python Version|\n|License|\n\n|Codeship|\n|CodeCov|\n|Code Climate|\n|Dependency Status|\n\n\nPython API for the Interactive Tree of Life (iTOL)\n\
marcelm marked this conversation as resolved.
Show resolved Hide resolved
\nCreated by Albert Wang (git at albertyw.com)\n\nWith Complements to: `iTOL (Interactive Tree of Life)`_, `Python requests package`.\n\nThis iTOL API allows local software to upload trees to iTOL using\
\ ``itol.py``\nand export uploaded trees using ``itolexport.py`` using direct Python\ncalls or through shell. An active internet connection to the\n`iTOL website`_ is required.\n\nInstallation\n------------\n\
\n``pip install itolapi``\n\nUploading Trees To iTOL (itol.py)\n---------------------------------\n\nFrom Command Line\n~~~~~~~~~~~~~~~~~\n\n(If you need to do anything more than displaying basic tree\
\ structures,\nyou must call the Python iTOL API from within a Python program)\n\n::\n\n $ itol.py /path/to/example.tree\n http://itol.embl.de/external.cgi?tree=1234567890&restore_saved=1\n\n\
From Python\n~~~~~~~~~~~\n\nRunning from a python program is much more flexible than running from\ncommand line and allows access to all `iTOL options`_\n\n::\n\n from itolapi import Itol\n itol_uploader\
\ = Itol()\n itol_uploader.add_file('/path/to/example.tree')\n itol_uploader.params['treeName'] = 'apple'\n status = itol_uploader.upload()\n assert status != False\n itol_uploader.comm.upload_output\n\
\ # SUCCESS: 1234567890\n itol_uploader.comm.tree_id\n # 1234567890\n itol_uploader.get_webpage()\n # http://itol.embl.de/external.cgi?tree=1234567890&restore_saved=1\n itol_uploader.get_itol_export()\n\
\ # <ItolExport.ItolExport instance at 0x207c5f0>\n\nAn example for using the Python iTOL API can found in\n``examples/example.py``.\n\nDownloading Trees From iTOL (itolexport.py)\n-------------------------------------------\n\
\nFrom Command Line\n~~~~~~~~~~~~~~~~~\n\n(If you would like to set any parameters other than the tree id,\nlocation to save the file, file format, and whether to display datasets,\nyou must use ItolExport\
\ from a Python program)\n\n::\n\n $ itolexport.py TREEID FILELOCATION FORMAT [OPTIONS]\n\nOptions include:\n * ``-d``: show datasets\n * ``-v``: verbose output\n * ``-h``: help\n\nFrom Python\n\
~~~~~~~~~~~\n\nRunning itolexport.py from a Python program allows you to use all the\noptions that iTOL has available.\n\n::\n\n from itolapi import ItolExport\n itol_exporter = ItolExport()\n\
\ itol_exporter.add_export_param_value('tree', tree_id)\n assert format in ['png', 'svg', 'eps', 'ps', 'pdf', 'nexus', 'newick']\n itol_exporter.add_export_param_value('format', format)\n \
\ itol_exporter.add_export_param_value(param_key, param_value)\n itol_exporter.export(file_location)\n\nValid ``param_key`` and ``param_value`` values can be found on `the iTOL API page`_.\n\n\
Bugs/Comments\n-------------\nSend bugs and comments as issues on the `Github`_ repository.\n\nDevelopment\n-----------\nTo run tests:\n\n::\n\n python setup.py install\n pip install -r requirements-test.txt\n\
\ mypy itolapi\n coverage run setup.py test\n coverage report -m\n\nTo update PyPI:\n\n::\n\n pip install twine\n python setup.py sdist bdist_wheel\n twine upload dist/*\n\n.. _iTOL\
\ (Interactive Tree of Life): http://itol.embl.de/\n.. _iTOL website: http://itol.embl.de/\n.. _iTOL options: http://itol.embl.de/help.cgi#batch\n.. _the iTOL API page: http://itol.embl.de/help.cgi#batch\n\
.. _Github: https://github.com/albertyw/itolapi/\n\n\n.. |PyPI| image:: https://img.shields.io/pypi/v/itolapi.svg\n :target: https://pypi.python.org/pypi/itolapi/\n :alt: Latest Version\n\n.. |Python\
\ Version| image:: https://img.shields.io/pypi/pyversions/itolapi.svg\n\n.. |License| image:: https://img.shields.io/pypi/l/itolapi.svg\n :target: https://pypi.python.org/pypi/itolapi/\n :alt: License\n\
\n\n.. |Codeship| image:: https://codeship.com/projects/d6470c00-c832-0132-4536-627bbcd2f5ed/status?branch=master\n :target: https://codeship.com/projects/75058\n :alt: Codeship\n\n.. |CodeCov|\
\ image:: https://codecov.io/github/albertyw/itolapi/coverage.svg?branch=master\n :target: https://codecov.io/github/albertyw/itolapi?branch=master\n\n.. |Code Climate| image:: https://codeclimate.com/github/albertyw/itolapi/badges/gpa.svg\n\
\ :target: https://codeclimate.com/github/albertyw/itolapi\n :alt: CodeClimate\n\n.. |Dependency Status| image:: https://pyup.io/repos/github/albertyw/itolapi/shield.svg\n :target: https://pyup.io/repos/github/albertyw/itolapi/\n\
\n\n"
doc_url: ''
cokelaer marked this conversation as resolved.
Show resolved Hide resolved
dev_url: ''

extra:
recipe-maintainers: ''
cokelaer marked this conversation as resolved.
Show resolved Hide resolved