[med-svn] [python-treetime] 02/06: Add initial packaging
Andreas Tille
tille at debian.org
Thu Jun 15 12:08:48 UTC 2017
This is an automated email from the git hooks/post-receive script.
tille pushed a commit to branch master
in repository python-treetime.
commit a82954d4b8b91d0e7b94a01148ea2c69b1b49019
Author: Andreas Tille <tille at debian.org>
Date: Thu Jun 15 09:37:16 2017 +0200
Add initial packaging
---
debian/changelog | 5 +++++
debian/compat | 1 +
debian/control | 50 +++++++++++++++++++++++++++++++++++++++++++
debian/copyright | 30 ++++++++++++++++++++++++++
debian/createmanpages | 34 +++++++++++++++++++++++++++++
debian/examples | 1 +
debian/get-orig-source | 24 +++++++++++++++++++++
debian/install | 2 ++
debian/links | 3 +++
debian/patches/fix_test.patch | 24 +++++++++++++++++++++
debian/patches/series | 1 +
debian/rules | 15 +++++++++++++
debian/source/format | 1 +
debian/upstream/metadata | 12 +++++++++++
debian/watch | 4 ++++
15 files changed, 207 insertions(+)
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..5d2975b
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,5 @@
+python-treetime (0.0+20170607-1) UNRELEASED; urgency=medium
+
+ * Initial release (Closes: #<bug>)
+
+ -- Andreas Tille <tille at debian.org> Wed, 14 Jun 2017 17:20:26 +0200
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..f599e28
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+10
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..149c647
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,50 @@
+Source: python-treetime
+Maintainer: Debian Med Packaging Team <debian-med-packaging at lists.alioth.debian.org>
+Uploaders: Andreas Tille <tille at debian.org>
+Section: science
+Priority: optional
+Build-Depends: debhelper (>= 10),
+ python-all-dev,
+ python-setuptools
+Standards-Version: 3.9.8
+Vcs-Browser: https://anonscm.debian.org/cgit/debian-med/treetime.git
+Vcs-Git: https://anonscm.debian.org/git/debian-med/treetime.git
+Homepage: https://github.com/neherlab/treetime
+
+Package: python-treetime
+Architecture: any
+Section: python
+Depends: ${python:Depends},
+ ${misc:Depends},
+ python-numpy,
+ python-scipy,
+ python-biopython,
+ python-pandas
+Description: inference of time stamped phylogenies and ancestral reconstruction
+ TreeTime provides routines for ancestral sequence reconstruction and the
+ maximum likelihoo inference of molecular-clock phylogenies, i.e., a tree
+ where all branches are scaled such that the locations of terminal nodes
+ correspond to their sampling times and internal nodes are placed at the
+ most likely time of divergence.
+ .
+ TreeTime aims at striking a compromise between sophisticated
+ probabilistic models of evolution and fast heuristics. It implements GTR
+ models of ancestral inference and branch length optimization, but takes
+ the tree topology as given. To optimize the likelihood of time-scaled
+ phylogenies, treetime uses an iterative approach that first infers
+ ancestral sequences given the branch length of the tree, then optimizes
+ the positions of unconstraine d nodes on the time axis, and then repeats
+ this cycle. The only topology optimization are (optional) resolution of
+ polytomies in a way that is most (approximately) consistent with the
+ sampling time constraints on the tree. The package is designed to be
+ used as a stand-alone tool or as a library used in larger phylogenetic
+ analysis workflows.
+ .
+ Features
+ * ancestral sequence reconstruction (marginal and joint maximum
+ likelihood)
+ * molecular clock tree inference (marginal and joint maximum
+ likelihood)
+ * inference of GTR models
+ * rerooting to obtain best root-to-tip regression
+ * auto-correlated relaxed molecular clock (with normal prior)
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..8fb7339
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,30 @@
+Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Upstream-Contact: Pavel Sagulenko <pavel.sagulenko at tuebingen.mpg.de>
+Source: https://github.com/neherlab/treetime
+
+Files: *
+Copyright: 2016-17 Pavel Sagulenko and Richard Neher
+License: MIT
+
+Files: debian/*
+Copyright: 2017 Andreas Tille <tille at debian.org>
+License: MIT
+
+License: MIT
+ Permission is hereby granted, free of charge, to any person obtaining a copy
+ of this software and associated documentation files (the "Software"), to deal
+ in the Software without restriction, including without limitation the rights
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ copies of the Software, and to permit persons to whom the Software is
+ furnished to do so, subject to the following conditions:
+ .
+ The above copyright notice and this permission notice shall be included in all
+ copies or substantial portions of the Software.
+ .
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ SOFTWARE.
diff --git a/debian/createmanpages b/debian/createmanpages
new file mode 100755
index 0000000..20c4ba3
--- /dev/null
+++ b/debian/createmanpages
@@ -0,0 +1,34 @@
+#!/bin/sh
+MANDIR=debian/mans
+mkdir -p $MANDIR
+
+VERSION=`dpkg-parsechangelog | awk '/^Version:/ {print $2}' | sed -e 's/^[0-9]*://' -e 's/-.*//' -e 's/[+~]dfsg$//'`
+
+AUTHOR=".SH AUTHOR\nThis manpage was written by $DEBFULLNAME for the Debian distribution and
+can be used for any other usage of the program.
+"
+
+progname=ancestral_reconstruction
+help2man --no-info --no-discard-stderr \
+ --name='Reconstructs ancestral sequences and maps mutations to the tree' \
+ --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
+echo $AUTHOR >> $MANDIR/${progname}.1
+
+progname=temporal_signal
+help2man --no-info --no-discard-stderr \
+ --name="Calculates the root-to-tip regression and quantifies the 'clock-i-ness' of a tree" \
+ --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
+echo $AUTHOR >> $MANDIR/${progname}.1
+
+progname=timetree_inference
+help2man --no-info --no-discard-stderr \
+ --name='Reconstructs ancestral sequences and infers a molecular clock tree' \
+ --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
+echo $AUTHOR >> $MANDIR/${progname}.1
+
+cat <<EOT
+Please enhance the help2man output.
+The following web page might be helpful in doing so:
+ http://liw.fi/manpages/
+EOT
+
diff --git a/debian/examples b/debian/examples
new file mode 100644
index 0000000..e39721e
--- /dev/null
+++ b/debian/examples
@@ -0,0 +1 @@
+examples/*
diff --git a/debian/get-orig-source b/debian/get-orig-source
new file mode 100755
index 0000000..40acd16
--- /dev/null
+++ b/debian/get-orig-source
@@ -0,0 +1,24 @@
+#!/bin/sh -e
+
+COMPRESS=xz
+
+NAME=`dpkg-parsechangelog | awk '/^Source/ { print $2 }'`
+MVERSION=`dpkg-parsechangelog | awk '/^Version:/ { print $2 }' | sed 's/^\([0-9\.]\+\)[+~][-0-9]\+$/\1/'`
+
+mkdir -p ../tarballs
+cd ../tarballs
+# need to clean up the tarballs dir first because upstream tarball might
+# contain a directory with unpredictable name
+rm -rf *
+git clone --quiet https://github.com/neherlab/treetime $NAME
+cd $NAME
+VERSION=${MVERSION}+`date -d @$(git show --format="%at" | head -n1) +%Y%m%d`
+# for esthetical reasons set file timestamps (if git-restore-mtime is installed)
+git restore-mtime || true
+cd ..
+TARDIR=${NAME}-${VERSION}
+mv ${NAME} ${TARDIR}
+rm -rf ${TARDIR}/.git
+
+GZIP="--best --no-name" tar --owner=root --group=root --mode=a+rX -caf "$NAME"_"$VERSION".orig.tar.${COMPRESS} "${TARDIR}"
+rm -rf ${TARDIR}
diff --git a/debian/install b/debian/install
new file mode 100644
index 0000000..089dbca
--- /dev/null
+++ b/debian/install
@@ -0,0 +1,2 @@
+*.py usr/share/treetime
+
diff --git a/debian/links b/debian/links
new file mode 100644
index 0000000..aeeda9f
--- /dev/null
+++ b/debian/links
@@ -0,0 +1,3 @@
+usr/share/treetime/ancestral_reconstruction.py usr/bin/ancestral_reconstruction
+usr/share/treetime/temporal_signal.py usr/bin/temporal_signal
+usr/share/treetime/timetree_inference.py usr/bin/timetree_inference
diff --git a/debian/patches/fix_test.patch b/debian/patches/fix_test.patch
new file mode 100644
index 0000000..926d1b3
--- /dev/null
+++ b/debian/patches/fix_test.patch
@@ -0,0 +1,24 @@
+Author: Andreas Tille <tille at debian.org>
+Last-Update: Wed, 14 Jun 2017 17:20:26 +0200
+Description: No idea how this test is run - but at least fix syntax issues
+
+--- a/test/test_gtr.py
++++ b/test/test_gtr.py
+@@ -31,7 +31,7 @@ class TestGTR(unittest.TestCase):
+ self.gtr.W = W
+ self.gtr.Pi = Pi
+
+- self.gtr.
++# self.gtr.
+ def test_reversibility(self):
+ pass
+
+@@ -61,7 +61,7 @@ class TestGTR(unittest.TestCase):
+
+
+ if __name__ == '__main__':
+-
++ pass
+
+
+
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..566b050
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+fix_test.patch
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..144dfde
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,15 @@
+#!/usr/bin/make -f
+
+# DH_VERBOSE := 1
+
+%:
+ dh $@ --with python2
+
+override_dh_install:
+ dh_install
+ find debian/*/usr/share/treetime -name __init__.py -delete
+ find debian/*/usr/share/treetime -name setup.py -delete
+ find debian/*/usr/lib/*/dist-packages/treetime -name "*.py" -exec sed -i 's:/usr/local/bin/python:/usr/bin/python:' \{\} \;
+
+get-orig-source:
+ . debian/get-orig-source
diff --git a/debian/source/format b/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)
diff --git a/debian/upstream/metadata b/debian/upstream/metadata
new file mode 100644
index 0000000..d8b5812
--- /dev/null
+++ b/debian/upstream/metadata
@@ -0,0 +1,12 @@
+Reference:
+ Author:
+ Title:
+ Journal:
+ Year:
+ Volume:
+ Number:
+ Pages:
+ DOI:
+ PMID:
+ URL:
+ eprint:
diff --git a/debian/watch b/debian/watch
new file mode 100644
index 0000000..fe3eb0b
--- /dev/null
+++ b/debian/watch
@@ -0,0 +1,4 @@
+version=4
+
+opts=dversionmangle=s/.*/0.No-Release/ \
+ https://people.debian.org/~eriberto/ FakeWatchNoUpstreamReleaseForThisPackage-(\d\S+)\.gz
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/python-treetime.git
More information about the debian-med-commit
mailing list