Skip to content

Commit

Permalink
Merge pull request #38 from elifesciences/develop
Browse files Browse the repository at this point in the history
PR for version 0.2.0 release
  • Loading branch information
gnott committed Jun 22, 2022
2 parents aabec21 + 523811e commit b3be08b
Show file tree
Hide file tree
Showing 18 changed files with 57 additions and 29 deletions.
1 change: 0 additions & 1 deletion .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,5 @@
omit =
*/virtualenv/*
*/venv/*
*/.tox/*
exclude_lines =
if __name__ == .__main__.:
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
*.pyc
*.py~
venv/*
.tox/*
build/
dist/
jatsgenerator.egg-info
Expand Down
2 changes: 1 addition & 1 deletion jatsgenerator/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.1.2"
__version__ = "0.2.0"
24 changes: 24 additions & 0 deletions mkvenv.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/bin/bash
set -e

python=''
pybinlist=("python3.8" "python3.6")

for pybin in ${pybinlist[*]}; do
which "$pybin" &> /dev/null || continue
python=$pybin
break
done

if [ -z "$python" ]; then
echo "no usable python found, exiting"
exit 1
fi

if [ ! -e "venv/bin/$python" ]; then
echo "could not find venv/bin/$python, recreating venv"
rm -rf venv
$python -m venv venv
else
echo "using $python"
fi
10 changes: 5 additions & 5 deletions project_tests.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
set -e

tox
. .tox/py3/bin/activate
pip install coveralls
COVERALLS_REPO_TOKEN=$(cat /etc/coveralls/tokens/jats-generator) coveralls
. mkvenv.sh
source venv/bin/activate
pip install pip wheel pytest coverage --upgrade
pip install -r requirements.txt
coverage run -m pytest
9 changes: 4 additions & 5 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
git+https://github.com/elifesciences/elife-tools.git@f9ed819e137b8ec96900d8cab59f4a8c9911ce45#egg=elifetools
git+https://github.com/elifesciences/elife-article.git@a3cc8244d3ddcb45039d8a3d876dfd4673c9975e#egg=elifearticle
git+https://github.com/elifesciences/ejp-csv-parser.git@2e07c7a9bf60c435dac78207858b4c80d250511a#egg=ejpcsvparser
GitPython==3.1.2
configparser==3.5.0
ejpcsvparser==0.1.2
elifearticle==0.7.0
elifetools==0.13.1
GitPython==3.1.2
mock==1.3.0
coverage==5.1
2 changes: 1 addition & 1 deletion tests/test_data/elife_poa_e00003.xml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion tests/test_data/elife_poa_e00007.xml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?xml version="1.0" encoding="utf-8"?><!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.1d3 20150301//EN" "JATS-archivearticle1.dtd"><article article-type="research-article" dtd-version="1.1d3" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink"><front><journal-meta><journal-id journal-id-type="nlm-ta">elife</journal-id><journal-id journal-id-type="publisher-id">eLife</journal-id><journal-title-group><journal-title>eLife</journal-title></journal-title-group><issn publication-format="electronic">2050-084X</issn><publisher><publisher-name>eLife Sciences Publications, Ltd</publisher-name></publisher></journal-meta><article-meta><article-id pub-id-type="publisher-id">00007</article-id><article-id pub-id-type="doi">10.7554/eLife.00007</article-id><article-categories><subj-group subj-group-type="display-channel"><subject>Research Article</subject></subj-group><subj-group subj-group-type="heading"><subject>Genomics and evolutionary biology</subject></subj-group><subj-group subj-group-type="heading"><subject>Plant biology</subject></subj-group></article-categories><title-group><article-title>Herbivory-induced &quot;volatiles&quot; function as defenses increasing fitness of the native plant <italic>Nicotiana attenuata</italic> in nature</article-title></title-group><contrib-group><contrib contrib-type="author" id="author-1399"><name><surname>Schuman</surname><given-names>Meredith C</given-names><suffix>Jnr</suffix></name><xref ref-type="aff" rid="aff1">1</xref><xref ref-type="other" rid="par-1"/><xref ref-type="fn" rid="conf1"/></contrib><contrib contrib-type="author" corresp="yes" id="author-1400"><name><surname>Barthel</surname><given-names>Kathleen</given-names></name><xref ref-type="aff" rid="aff2">2</xref><xref ref-type="corresp" rid="cor1">*</xref><xref ref-type="fn" rid="conf1"/></contrib><contrib contrib-type="author" corresp="yes" id="author-1013"><name><surname>Baldwin</surname><given-names>Ian T</given-names></name><xref ref-type="aff" rid="aff1">1</xref><xref ref-type="corresp" rid="cor2">*</xref><xref ref-type="fn" rid="conf2"/></contrib><aff id="aff1"><institution content-type="dept">Department of Molecular Ecology</institution>, <institution>Max Planck Institute for Chemical Ecology</institution>, <addr-line><named-content content-type="city">Jena</named-content></addr-line>, <country>Germany</country></aff><aff id="aff2"><institution content-type="dept">Federal Research Center for Cultivated Plants Institute for Breeding Research on Horticultural And Fruit Crops</institution>, <institution>Julius Kühn Institute</institution>, <addr-line><named-content content-type="city">Dresden</named-content></addr-line>, <country>Germany</country></aff></contrib-group><contrib-group content-type="section"><contrib contrib-type="editor" id="author-1030"><name><surname>Weigel</surname><given-names>Detlef</given-names><suffix>Jnr</suffix></name><role>Reviewing editor</role><aff><institution>Max Planck Institute for Developmental Biology</institution>, <country>Germany</country></aff></contrib></contrib-group><author-notes><corresp id="cor1"><label>*</label>For correspondence: <email>k@example.com</email> (KB);</corresp><corresp id="cor2"><label>*</label>For correspondence: <email>b@example.com</email> (IB);</corresp></author-notes><elocation-id>e00007</elocation-id><history><date date-type="received"><day>07</day><month>05</month><year>2012</year></date><date date-type="accepted"><day>11</day><month>07</month><year>2012</year></date></history><permissions><copyright-statement>© 2012, Schuman et al</copyright-statement><copyright-year>2012</copyright-year><copyright-holder>Schuman et al</copyright-holder><license xlink:href="http://creativecommons.org/licenses/by/4.0/"><license-p>This article is distributed under the terms of the <ext-link ext-link-type="uri" xlink:href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution License</ext-link> permitting unrestricted use and redistribution provided that the original author and source are credited.</license-p></license></permissions><abstract><p>An abstract with some &quot;quotation&quot; marks</p></abstract><kwd-group kwd-group-type="research-organism"><title>Research organism</title><kwd>Other</kwd></kwd-group><funding-group><award-group id="par-1"><funding-source><institution-wrap><institution>The Cöffee Høuse Foundation</institution></institution-wrap></funding-source><principal-award-recipient><name><surname>Schuman</surname><given-names>Meredith C</given-names><suffix>Jnr</suffix></name></principal-award-recipient></award-group><funding-statement>R.D., F.M., G.M., Z.W., P.B., S.L., E.F., J.A., J.R-H., A.L., J.K., C.R., J.K., W.C., M.B., G.R., J.T., J.P., C.M., L.M., G.H. and B.N. are employees in this test data.</funding-statement></funding-group></article-meta></front><back><sec id="s1" sec-type="additional-information"><title>Additional information</title><fn-group content-type="competing-interest"><title>Competing interest</title><fn fn-type="conflict" id="conf2"><p>Ian T Baldwin, Senior Editor, <italic>eLife</italic>.</p></fn><fn fn-type="conflict" id="conf1"><p>The other authors declare that no competing interests exist.</p></fn></fn-group></sec><sec id="s2" sec-type="supplementary-material"><title>Additional Files</title><sec id="s3" sec-type="data-availability"><title>Data availability</title><p>Only availability text</p></sec></sec></back></article>
<?xml version="1.0" encoding="utf-8"?><!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.1d3 20150301//EN" "JATS-archivearticle1.dtd"><article xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink" article-type="research-article" dtd-version="1.1d3"><front><journal-meta><journal-id journal-id-type="nlm-ta">elife</journal-id><journal-id journal-id-type="publisher-id">eLife</journal-id><journal-title-group><journal-title>eLife</journal-title></journal-title-group><issn publication-format="electronic">2050-084X</issn><publisher><publisher-name>eLife Sciences Publications, Ltd</publisher-name></publisher></journal-meta><article-meta><article-id pub-id-type="publisher-id">00007</article-id><article-id pub-id-type="doi">10.7554/eLife.00007</article-id><article-categories><subj-group subj-group-type="display-channel"><subject>Research Article</subject></subj-group><subj-group subj-group-type="heading"><subject>Genomics and evolutionary biology</subject></subj-group><subj-group subj-group-type="heading"><subject>Plant biology</subject></subj-group></article-categories><title-group><article-title>Herbivory-induced &quot;volatiles&quot; function as defenses increasing fitness of the native plant <italic>Nicotiana attenuata</italic> in nature</article-title></title-group><contrib-group><contrib contrib-type="author" id="author-1399"><name><surname>Schuman</surname><given-names>Meredith C</given-names><suffix>Jnr</suffix></name><xref ref-type="aff" rid="aff1">1</xref><xref ref-type="other" rid="par-1"/><xref ref-type="fn" rid="conf1"/></contrib><contrib contrib-type="author" corresp="yes" id="author-1400"><name><surname>Barthel</surname><given-names>Kathleen</given-names></name><xref ref-type="aff" rid="aff2">2</xref><xref ref-type="corresp" rid="cor1">*</xref><xref ref-type="fn" rid="conf1"/></contrib><contrib contrib-type="author" corresp="yes" id="author-1013"><name><surname>Baldwin</surname><given-names>Ian T</given-names></name><xref ref-type="aff" rid="aff1">1</xref><xref ref-type="corresp" rid="cor2">*</xref><xref ref-type="fn" rid="conf2"/></contrib><aff id="aff1"><institution content-type="dept">Department of Molecular Ecology</institution>, <institution>Max Planck Institute for Chemical Ecology</institution>, <addr-line><named-content content-type="city">Jena</named-content></addr-line>, <country>Germany</country></aff><aff id="aff2"><institution content-type="dept">Federal Research Center for Cultivated Plants Institute for Breeding Research on Horticultural And Fruit Crops</institution>, <institution>Julius Kühn Institute</institution>, <addr-line><named-content content-type="city">Dresden</named-content></addr-line>, <country>Germany</country></aff></contrib-group><contrib-group content-type="section"><contrib contrib-type="editor" id="author-1030"><name><surname>Weigel</surname><given-names>Detlef</given-names><suffix>Jnr</suffix></name><role>Reviewing editor</role><aff><institution>Max Planck Institute for Developmental Biology</institution>, <country>Germany</country></aff></contrib></contrib-group><author-notes><corresp id="cor1"><label>*</label>For correspondence: <email>k@example.com</email> (KB);</corresp><corresp id="cor2"><label>*</label>For correspondence: <email>b@example.com</email> (IB);</corresp></author-notes><elocation-id>e00007</elocation-id><history><date date-type="received"><day>07</day><month>05</month><year>2012</year></date><date date-type="accepted"><day>11</day><month>07</month><year>2012</year></date></history><permissions><copyright-statement>© 2012, Schuman et al</copyright-statement><copyright-year>2012</copyright-year><copyright-holder>Schuman et al</copyright-holder><license xlink:href="http://creativecommons.org/licenses/by/4.0/"><license-p>This article is distributed under the terms of the <ext-link ext-link-type="uri" xlink:href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution License</ext-link> permitting unrestricted use and redistribution provided that the original author and source are credited.</license-p></license></permissions><abstract><p>An abstract with some &quot;quotation&quot; marks</p></abstract><kwd-group kwd-group-type="research-organism"><title>Research organism</title><kwd>Other</kwd></kwd-group><funding-group><award-group id="par-1"><funding-source><institution-wrap><institution>The Cöffee Høuse Foundation</institution></institution-wrap></funding-source><principal-award-recipient><name><surname>Schuman</surname><given-names>Meredith C</given-names><suffix>Jnr</suffix></name></principal-award-recipient></award-group><funding-statement>R.D., F.M., G.M., Z.W., P.B., S.L., E.F., J.A., J.R-H., A.L., J.K., C.R., J.K., W.C., M.B., G.R., J.T., J.P., C.M., L.M., G.H. and B.N. are employees in this test data.</funding-statement></funding-group></article-meta></front><back><sec id="s1" sec-type="additional-information"><title>Additional information</title><fn-group content-type="competing-interest"><title>Competing interest</title><fn fn-type="conflict" id="conf2"><p>Ian T Baldwin, Senior Editor, <italic>eLife</italic>.</p></fn><fn fn-type="conflict" id="conf1"><p>The other authors declare that no competing interests exist.</p></fn></fn-group></sec><sec id="s2" sec-type="supplementary-material"><title>Additional Files</title><sec id="s3" sec-type="data-availability"><title>Data availability</title><p>Only availability text</p></sec></sec></back></article>
Loading

0 comments on commit b3be08b

Please sign in to comment.